Skip to content

Block card

This method blocks a specified card. Blocking a card is permitted only for cards in an "ACTIVE" or "DIGITALLY ACTIVE" state, and these cards must be associated with "ACTIVE" accounts.

Additionally, the process of blocking a card is determined by user roles, which have the authority to assign a specific reason code based on the Location of the user role.

If the record is requested by "BANK” these reason codes can be assigned:

  • "LOST"
  • "STOLEN"
  • "DETAINED"
  • "BANK"
  • "FRAUD"
  • "BLOCKED_BY_ACCOUNT"
  • "HOLDER_REQUEST"

If the record is requested by "ACCOUNT OWNER” these reason codes can be assigned:

  • "LOST"
  • "STOLEN"
  • "HOLDER_REQUEST"

If the record is requested by "HOLDER” these reason codes can be assigned:

  • "LOST"
  • "STOLEN"
  • "HOLDER_REQUEST"

One card can be blocked by “BANK” and "ACCOUNT OWNER”/ "HOLDER”, if only one block is lifted than the card is still blocked. In addition, card can be simultaneously block for different reason codes.

As the card number needs to be simultaneously blocked by the card processor, CMS sends a request to block the card number. Subsequently, the card number is restricted from authorizing transactions.

URL test:

https://dev.lightcms.io/cms/v1/cards/{id}/block

URL live:

https://fat.lightcms.io/cms/v1/cards/{id}/block

Method:

POST

Path items:

/cards (Card Service)

/{id} (ID code of blocked card)

/block (Method name)

Parameters:

Parameter Location Type Example Description Required
id Path integer 265 Internal Card ID Yes
x-cms-role Header string "BANK" Level of user role Yes
reason Body string "LOST" Reason of block Yes
requestedBy Body string "BANK" Level of user role Yes

Example:

curl -X 'POST' \
  'https://dev.lightcms.io/cms/v1/cards/18/block' \
  -H 'accept: */*' \
  -H 'x-cms-role: BANK' \
  -H 'Content-Type: application/json' \
  -d '{
  "reason": "LOST",
  "requestedBy": "BANK"
}'

Responses:

200 - OK

Status Code: 200 OK

{
 "blockId": 29
}

Parameter Location Type Example Description
blockId body integer 29 ID of created block
500 - Internal error

Status Code: 500 Internal error

409 - Blocking reason already exists

Status Code: 409 Conflict

{
"errorMessage": "Blocking reason already exists"
}

Parameter Location Type Example Description
errorMessage body string "Blocking reason already exists" Error message
400 - Level of user mismatch

Status Code: 400 Bad request

{
  "errorMessage": "Requested as BANK, but requested in header HOLDER."
}

Parameter Location Type Example Description
errorMessage body string "Requested as BANK, but requested in header HOLDER." Error message
404 - Not found

Status Code: 404 Not found

{
"errorMessage": "Entity with id 108564234 not found in DB."
}

Parameter Location Type Example Description
errorMessage body string "Entity with id 108564234 not found in DB." Error message