Skip to content

Get Card

Request URL

GET /transfer-to/card/get/:cardId

Description

This endpoint will return the details of the registered card specified. The cFiCardId for the requested card should be included as a path parameter, ":cardId".

Snippet Examples

javascript

const axios = require('axios');
const config = {
  method: 'GET',
  url: '${CONNECTFI_BASE_URL}/transfer-to/card/get/:cardId',
  headers: {
    'x-connectfi-token': "A long random string token received from /auth/get-token request"
  },
};

let result;
try {
  result = await axios.request(config);
  if (result.status === 200) {
    console.log(JSON.stringify(result.data));
  }
} catch (err) {
  console.log({
    errCode: err.code,
    responseStatus: err.response && err.response.status,
    data: err.response && JSON.stringify(err.response.data)
  });
}

cURL

curl --location "CONNECTFI_BASE_URL/transfer-to/card/get/:cardId"  --header "x-connectfi-token: A long random string token received from /auth/get-token request" 

Successful Response Examples

200 SUCCESSFUL RESPONSE

HEADERS

Header Value
x-connectfi-token A long random string token received from /auth/get-token request

PARAMETERS

Parameter Description Value
cardId [required] tcrd_1AXvpht43m432u6UHpu07w

REQUEST BODY

none

RESPONSE BODY

{
    "code": "0",
    "data": {
        "cFiCardId": "tcrd_1AXvpht43m432u6UHpu07w",
        "dtsRegistered": "2023-09-15T21:45:36.613Z",
        "reference": "externalCardId53",
        "isPullEnabled": true,
        "isPushEnabled": true,
        "cardExpirationDate": "202512",
        "cardLast4": "9990"
    },
    "requestId": "668d4890796f11eeb5658f28ab5fe311"
}