| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
This API lets you generate external IDs manually, which you can tag to a customer during registration. Each API call generates a unique external ID. The maximum allowed length is 50 characters.
When you register a customer without an external ID, the system calls this API in the background and automatically tags the generated external ID to the customer. The API does not override an existing external ID.
Important: When you import external IDs, the system validates each value against the organisation-level CONF_CARD_NUMBER_LENGTH configuration. If an imported external ID does not match the configured length, the system rejects the record during import. Rejected records are not processed for event handling or eligibility updates. Ensure that all imported external IDs meet the required length to avoid data loss and processing issues.
For detailed information about our APIs and for hands-on testing, refer documentation in API overview and step-by-step guide on making your first API call in Make your first API call .
Example request
curl --location --request PUT 'https://eu.api.capillarytech.com/v2/card?format=json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic bWFkaU2YQ==' \
--header 'Cookie: _cfuvid=YyYQB5XUwCZmLtgRlu60lc4n5_3PDiTtwCCXj6_8V3g-1762771226384-0.0.1.1-604800000' \
--data '{
"cardNumber": "Test09000000000105end",
"cardExternalId": "CardExternal1"
}'Prerequisites
Navigate to InTouch > Settings > Miscellaneous > Registration Configuration page to:
- Enable
CONF_CARD_NUMBER_GENERATION_ENABLED. - Enable
CONF_CLIENT_V2_API_ENABLED. - Use only for account IDs configured on
SOURCE_ACCOUNTS_EXTERNALID_ENABLED. - Set
CONF_CARD_CHECKSUM_DIGIT_ALGOwith one of the following values:LUHN_ALGO,MOD7_ALGO,AUTO_INC,RANDOM,RANDOM_LUHN,RANDOM_MOD7. - Set
CONF_CARD_NUMBER_LENGTH.
Note: When importing external IDs, the system checks that each external ID matches the length set in CONF_CARD_NUMBER_LENGTH. If the length does not match, the system rejects the record. Rejected records are not processed for event handling or eligibility updates. Always verify that imported external IDs meet the configured length requirement.
For more information and other optional configurations, refer to External ID configuration.
In response,
entityis the generated external ID.
Body parameters
| Field | Type | Required | Description |
|---|---|---|---|
| cardNumber | string | Yes | Card number to update. The specified card must exist. |
| cardExternalId | string | Yes | External system reference/id to associate with the card. |
Example response
{
"cardId": 920897,
"customerId": 566135941,
"cardExternalId": "CardExternal1",
"cardNumber": "Test09000000000105end",
"orgId": 100737,
"entityId": 75197372,
"transactionNotAllowed": false,
"activeAndDigital": false,
"warnings": []
}{
"warnings": [],
"errors": [
{
"status": false,
"code": 500,
"message": "All requests have failed due to errors"
}
]
}Response parameters
| Field | Type | Description |
|---|---|---|
| cardId | integer | Internal unique identifier of the card. |
| customerId | integer | Identifier of the customer linked to the card. |
| cardExternalId | string | External system's/reference id for the card. |
| cardNumber | string | Human/merchant-facing card number. |
| orgId | integer | Organisation/tenant identifier that owns the card. |
| entityId | integer | Entity/store/account context associated with the card. |
| transactionNotAllowed | boolean | Indicates if transactions on the card are currently blocked. |
| activeAndDigital | boolean | True if the card is active and provisioned digitally. |
| warnings | Array of strings | Non-fatal warnings related to the card or lookup. |
Error codes
| Code | Description |
|---|---|
| 500 | Internal server error. |
