For the complete documentation index, see llms.txt. This page is also available as Markdown.

GetCardAccountByCustomerId

The "GetCardAccountByCustomerId" endpoint allows customers to retrieve all card records tied to a particular customer, regardless of the account they're linked to.

GET /api/Card/v{{version}}/Interswitch/GetCardAccountByCustomerId

To retrieve a customer's card records, you need to provide the customerId as a query parameter. A successful request returns a list of matching card-account records under data, each showing the account-side details (accountNumber, nameOnCard, customerId) alongside the full linked card profile in a nested card object, plus a recordCount showing the total number of matching records.

This endpoint streamlines the process of finding every card belonging to a customer in a single call, useful for a full customer-level card view rather than looking up cards one account at a time.

Headers

Name
Value

Content-Type*

application/json

Request-Reference

unique_string

Query Params

Name
Description

customerId

The ID of the customer to retrieve card records for.

Here is an example request and response with a sample payload sent to the endpoint in Curl format.

Sample Request
curl --location -g '{{baseUrl}}/api/Card/v{{version}}/Interswitch/GetCardAccountByCustomerId?customerId=00005187' \
--header 'Content-Type: application/json'
Response: 200
{
  "status": true,
  "message": "string",
  "data": {
    "data": [
      {
        "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
        "dateCreated": "2025-03-31T17:15:36.415Z",
        "dateLastModified": "2025-03-31T17:15:36.415Z",
        "accountNumber": "string",
        "nameOnCard": "string",
        "customerId": "string",
        "cardId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
        "card": {
          "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
          "dateCreated": "2025-03-31T17:15:36.415Z",
          "dateLastModified": "2025-03-31T17:15:36.415Z",
          "batchNo": "string",
          "maskedPan": "string",
          "encrptedPan": "string",
          "hashedPan": "string",
          "accountNumber": "string",
          "nameOnCard": "string",
          "serialNumber": "string",
          "expiryDate": "2025-03-31T17:15:36.415Z",
          "requestDate": "2025-03-31T17:15:36.415Z",
          "issuedDate": "2025-03-31T17:15:36.415Z",
          "issuanceStatus": "string",
          "cardProfileId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
          "cardType": "string",
          "cardScheme": "string",
          "status": "string",
          "isATMEnabled": true,
          "isPOSEnabled": true,
          "isWebEnabled": true
        },
        "bankCode": "string",
        "encrptedPan": "string",
        "hashedPan": "string",
        "overrideProductApplicableFee": true,
        "overrideProductApplicableInterest": true,
        "productCode": "string",
        "productName": "string",
        "signatureFileUrl": "string",
        "passportFileUrl": "string",
        "status": "string"
      }
    ],
    "recordCount": 0
  }
}

Last updated