Card Statuses

Card status is independent of account status. It is possible for one account to have multiple cards in different statuses. Both the account and the card must be in status: N (normal, active) to perform card transactions.

You can see the list of actions you can perform on a card, an account, or both.

If you want to modify the status of a card in the src/baas/galileo/galileo.service.ts file in the modifyStatus function:

public async modifyStatus(
  integration: Integration,
  status: number,
  prmRef?: string,
): Promise<void> {
  const data = this.createRequestParameters<GalileoModifyStatusRequest>({
    accountNo: prmRef ?? integration.externalId,
    type: status.toString(),
  });

  await this.sendRequest<GalileoModifyStatusResponse>('/modifyStatus', data);
}

Integration refers to your primary account. If you want to modify the status of the account or card, in status you only have to pass the option you need, but if you need to modify a secondary account or a card from another account, you must send the account number in prmRef.

If you wish to modify a card, you must send the account number to which
this card is associated.

In the src/baas/galileo/enums/modify-status.enum.ts file, you can find all the options that you can send in the status parameter of this function.

Example of how to activate an account and a card:

await this.modifyStatus(
  userIntegration,
  ModifyStatus.UPDATE_ACCOUNT_STATUS_TO_ACTIVE,
);

await this.modifyStatus(
  userIntegration,
  ModifyStatus.UPDATE_CARD_STATUS_TO_ACTIVE,
);

Last updated

Was this helpful?