List of tokenized cards

Call details#

  • Resource: /v1/cards/list
  • HTTP Method: GET
  • Request format: JSON
  • Response format: JSON
  • Header Parameters:
ParameterDescriptionFormatMandatory
merchant_idStore code on Carat. Production and certification codes will be different.< 15 ANYES
merchant_keyStore authentication key in Carat. The production and certification keys will be different.< 80 ANYES
tokenToken obtained from the token creation service Learn more.. If Authorization is not sent, this field becomes mandatory= 66 ANCOND.
AuthorizationThe store authentication signature must be sent in the format Bearer {signature}. Example: Bearer JHVGytfdgauygdauiw78264284527852897hagdg. If token is not sent, this field will be mandatory< 2000 ANCOND.
Content-TypeIt must be sent with the value application/json.= 15 ANYES

Flow#

Examples#

Below are some examples of calling the tokenized card listing service using the cURL tool.

List of tokenized cards using token#

Request:

To use this example, don't forget to define the variable {{url}} with the value
esitef-homologacao.softwareexpress.com.br

curl --location --request GET 'https://{{url}}/e-sitef/api/v1/cards/list?authorizer_id=1&status=ATV&page=0&limit=1' \
--header 'merchant_id: xxxxxxxxxxx' \
--header 'merchant_key: xxxxxxxxxxx' \
--header 'token: ca6ff575d51b013dc01ab4059c63aebb055af2963b8a31043daa33e16b20750e01'
--verbose

Listing of tokenized cards using signature#

Request:

To use this example, don't forget to define the variable {{url}} with the value
esitef-homologacao.softwareexpress.com.br

curl --location --request GET 'https://{{url}}/e-sitef/api/v1/cards/list?authorizer_id=1&status=ATV&page=0&limit=1' \
--header 'merchant_id: LOJATESTE' \
--header 'merchant_key: F19DE00177C301DF24A865F11AA9B2567F604891F0F44DDAEFD69E3399E0B7E1' \
--header 'Authorization: Bearer XXXXX'

Response:

{
"response_code": "0",
"response_message": "OK. Transaction successful.",
"cards": [
{
"status": "ATV",
"authorizer_id": 1,
"token": "S1uloKsLc+CLVhbOtf1SBg0WwTCbYLBsxh29jgKwhm-jNAfkQ1g-u6vcWfiV5gH1CfyAhu8Hl5fXR2ho+Cmrjw==",
"bin": "455182",
"suffix": "2345",
"expiration_date": "1129",
"customer_id": "1",
"creation_date": "14/11/2023T00:21",
"modification_date": "14/11/2023T02:56"
},
{
"status": "ATV",
"authorizer_id": 1,
"token": "wAVdAIFCTkCTRZSL+BOH93hJYlBlD7Z4QhRDnyp6pbLQpfYE+rcUh740Tpf9Svvc5nLKZqKFuc4aZpTo41jc8Q==",
"bin": "401200",
"suffix": "1112",
"expiration_date": "1212",
"customer_id": "kakaroto",
"creation_date": "07/04/2024T23:22",
"modification_date": "09/05/2012T15:54"
}
],
"current_page": "0",
"total_pages": "1",
"count": "2"
}

Request parameters#

The table below describes the request parameters for the tokenized card listing service:

ParameterDescriptionFormatMandatory
authorizer_idAuthorizer code in Carat. Learn more. 3 NNO
statusCard status storing in Carat ATV (Active) or INA (Inactive).= 3 ANNO
pageListing page. The first page has a value of 0. If it is not sent, we will assume the value 0. 3 NNO
limitMaximum number of records per page. If it is not sent, we will assume the maximum value 100 3 NNO

Response parameters#

If successful, the HTTP response code will be 200. Any other code must be interpreted as an error. In the table below is the description of the response parameters of the tokenized card listing service:

ParameterDescriptionFormat
codeCarat response code. Any code other than 0 (zero) means failure. Learn more.< 4 N
messageCarat response message.< 500 AN
current_pageCurrent records page.< 4 AN
total_pagesTotal number of pages.< 4 AN
countTotal record count.< 4 AN
card
statusCard status.= 3 AN
customer_idBuyer identification for card storage.= 20 AN
authorizer_idAuthorizer code used in storage.< 3 N
tokenIdentification of the stored card. This token must be used instead of the buyer's card to carry out transactions with Carat.= 88 AN
suffixLast 4 digits of the buyer's card.= 4 AN
binFirst 6 digits of the buyer's card.= 6 AN
expiration_dateCard expiration date in MMYA format.= 4 N
creation_dateCreation date in card storage in the format: DD/MM/YYYY'T'HH:mm. Example: 07/13/2017T16:03= 16 D
modification_dateDate that was changed in the card storage in the format: DD/MM/YYYY'T'HH:mm. Example: 07/13/2017T16:03= 16 D