> For the complete documentation index, see [llms.txt](https://docs.payments.thalescloud.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.payments.thalescloud.io/click-to-pay/integrate-the-d1-api/d1-api-reference/outbound-api-from-d1/card-api.md).

# Card API

## Notify Card Operations

> This request is used by D1 to notify the system of the bank about any card status update.\<br>\
> There is a retry mechanism in case the notification has not been sent.\
> Thus the bank system can use this notification to synchronize card status with their card repository.\<br>\
> The number max of card status update in the notification is defined at onboarding time according to bank's system capability.\<br>\
> Each update is linked to a given card id, and can contain a message dedicated for the final end-user.

````json
{"openapi":"3.0.0","info":{"title":"Outbound Card API","version":"2.0"},"servers":[{"url":"https://YOUR_DOMAIN_NAME"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","description":"A JWT generated by the [Get Authorization Token API](oauth2-api).<br/>The server checks the validity of the provided token to control access to this protected resource. Please refer to [Get OAuth 2.0 access token](../../../integrate-the-d1-api/get-oauth-2.0-access-token) for more details on the flow and on how to get this JWT.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"CardStatus-operation-notification":{"type":"object","required":["operationId","operation","status","startTime","cardId"],"properties":{"operationId":{"type":"string","minLength":1,"maxLength":64,"pattern":"[A-Za-z0-9_-]{1,64}","description":"Unique identifier of the operation."},"operation":{"type":"string","enum":["CREATE","REGISTER","ACTIVATE","SUSPEND","RESUME","DELETE","DIGITIZE","RENEW","REPLACE","PRODUCE","STANDALONE_TRACKING","CLICK_TO_PAY_ENROLMENT","CLICK_TO_PAY_UPDATE","CLICK_TO_PAY_OPTOUT","UPDATE_ORDER"],"description":"card status operation"},"status":{"type":"string","enum":["PENDING","SUCCESSFUL","FAILED"],"description":"The operation status"},"startTime":{"type":"string","description":"Time of the operation.","minLength":1,"maxLength":64},"endTime":{"type":"string","description":"End time of the operation","minLength":1,"maxLength":64},"cardId":{"$ref":"#/components/schemas/cardId"},"details":{"oneOf":[{"$ref":"#/components/schemas/CardStatusDetails"},{"$ref":"#/components/schemas/ProduceDetails"},{"$ref":"#/components/schemas/DigitizeDetails"},{"$ref":"#/components/schemas/pullOperation"},{"$ref":"#/components/schemas/trackingOperation"}]},"message":{"type":"object","properties":{"format":{"type":"string","description":"Format of the message","enum":["TEXT","HTML"]},"title":{"type":"string","description":"Title of the notification"},"content":{"type":"string","description":"Message to be displayed"}}},"errorCode":{"type":"string","description":"The type of the error"},"error":{"type":"string","description":"Provide more error details if possible.<br/>For example name of the field with invalid format."}}},"cardId":{"type":"string","description":"Unique identifier of the card.","minLength":1,"maxLength":48,"pattern":"^[A-Za-z0-9_-]{1,48}$"},"CardStatusDetails":{"type":"object","title":"CREATE, REGISTER, ACTIVATE, SUSPEND, RESUME, DELETE, RENEW, REPLACE operations","description":"Card Status Details","properties":{"cardProductId":{"type":"string","description":"Card Product identifier of the card"},"cardState":{"$ref":"#/components/schemas/cardState"},"reasonState":{"type":"string","description":"Optional reason associated to the state of the card","enum":["CLOSED_ACCOUNT","CLOSED_CARD","CARD_LOST","CARD_FOUND","CARD_STOLEN","CARD_BROKEN","CARD_NOT_RECEIVED","FRAUD","USER_DECISION","ISSUER_DECISION","CVV2_LOCKED","EXPIRY_DATE_LOCKED","PIN_LOCKED"]},"newCardId":{"type":"string","description":"In case of card replacement, this field correspond to the cardId of the new card"},"encryptedData":{"type":"string","maxLength":8192,"pattern":"^(?:[\\x20-\\x2D\\x2F-\\x7F]*\\.){4}(?:[\\x20-\\x2D\\x2F-\\x7F]*)$","description":"Encrypted card information that can be provided in case of operation 'CREATE', 'REGISTER', 'RENEW' and 'REPLACE' (Receiver shall be configured accordingly during the onboarding)<br>\nIn case of 'REPLACE', this is the encrypted information of 'newCardId'<br>\nThe encryptedData is the encrypted json (cf http://www.json.org/) representation of the Card information.\nThis value is encrypted using the JWE encryption (please refer to the **[Encrypt sensitive data](../../../integrate-the-d1-api/encrypt-sensitive-data)** for more details)\n<br/><br/>Once deciphered, the plaintext contains a json structure with:\n|JSON field parameter name|description|MOC|Format|\n|-------|-------|-------|-------|\n|pan|The funding pan value.|M|string - up to 19 digits|\n|exp|The expiry date of the card.|M|string - 4 digits, following the format MMYY|"}}},"cardState":{"type":"string","description":"the state of the card","enum":["INACTIVE","ACTIVE","SUSPENDED","DELETED","REPLACED"]},"ProduceDetails":{"type":"object","title":"PRODUCE operation","description":"The card production status notifcation details","required":["status"],"properties":{"status":{"$ref":"#/components/schemas/productionStatusInNotification"},"reason":{"type":"string","description":"Additional details in case of exception during data processing or card production"},"consumerId":{"type":"string","description":"The consumer ID (card holder)."},"dueDate":{"type":"string","format":"date","description":"The estimated card production date. It uses the format ```YYYY-MM-DD```."},"productionSite":{"maxLength":50,"minLength":0,"type":"string","description":"The factory where the card is produced."},"shipment":{"$ref":"#/components/schemas/shipment"},"name":{"maxLength":50,"minLength":0,"description":"The card holder name printed on the card.\n","type":"string"},"maskedPan":{"maxLength":19,"minLength":12,"description":"The masked PAN value (Primary Account Number).\n","type":"string","pattern":"^[0-9xX\\*]{12,19}$"},"orderId":{"description":"The unique identifier of order used for card production.\n","type":"string","pattern":"^[A-Za-z0-9_-]{1,64}$"},"packageId":{"description":"The unique identifier of the package used for card production.\n","type":"string","pattern":"^[A-Za-z0-9_-]{1,64}$"},"services":{"$ref":"#/components/schemas/services"},"inputFileName":{"type":"string","minLength":1,"maxLength":256,"description":"Name of the input file in case of hybrid mode."},"cardPackageDetails":{"$ref":"#/components/schemas/cardPackageDetails"},"deliveryAddress":{"description":"The recipient's address.\n","$ref":"#/components/schemas/addressInProduceNotification"}}},"productionStatusInNotification":{"type":"string","enum":["CARD_PROD_REQUESTED","DATA_PREPARED","CARD_PROD_READY","CARD_PROD_ONGOING","CARD_PROD_DONE","CARD_SHIPPED","CARD_PROD_CANCELED","CARD_PROD_ONHOLD","DATA_EXCEPTION","CARD_PROD_EXCEPTION"],"description":"The current status of card production.\n\n|status code                | description                                                                                                       |\n|---------------------------|-------------------------------------------------------------------------------------------------------------------|\n|CARD_PROD_REQUESTED <br/>*(full api only)* | Card production has been requested via the D1 APIs.                                                           |\n|DATA_PREPARED <br/>*(full api only)* | The data required for production has been successfully prepared.                                                                          |  \n|DATA_EXCEPTION <br/>*(full api only)* | Data preparation has failed for some reason.                                                                                      |\n|CARD_PROD_READY            | The data has arrived at the Personalization Center; the card is ready to be produced.                                                 |\n|CARD_PROD_ONGOING          | Card production has started.                                                                                  |\n|CARD_PROD_DONE <br/>*(instant issuance only)* | The card has been successfully produced.                                                                          |\n|CARD_SHIPPED               | The card has been shipped.|\n|CARD_PROD_CANCELED         | Card production has been canceled by the issuer.                                                   |\n|CARD_PROD_ONHOLD           | Card production has been put on hold.                                                              |\n|CARD_PROD_EXCEPTION <br/>*(instant issuance only)* | Card production failed for some reason.                                                                           |\n"},"shipment":{"type":"object","properties":{"pickupDate":{"type":"string","description":"The date and time the shipment was picked up by the carrier. It is in the format ```YYYY-MM-DDThh:mm:ssZ``` for the timezone where the pickup occured.","format":"date-time"},"carrier":{"type":"string","description":"Unique carrier code.\n\n|Carrier Code|Carrier Name|\n|----|----|\n|chronopost-france|Chronopost France|\n|dhl|DHL Express|\n|fedex|FedEx®|\n|la-poste-colissimo|La Poste|AvailableForPickup|\n|spain-correos-es|Correos de España|\n|ups|UPS|\n|usps|USPS| |\n"},"trackingNumber":{"type":"string","pattern":"^[A-Za-z0-9 _\\-\\.\\/]{1,64}$","description":"The tracking number."},"status":{"maxLength":50,"minLength":0,"type":"string","enum":["INFO_RECEIVED","IN_TRANSIT","OUT_FOR_DELIVERY","FAILED_ATTEMPT","DELIVERED","AVAILABLE_FOR_PICKUP","EXCEPTION","EXPIRED","PENDING"],"description":"Current status of tracking.\n\n|status code                | description                                                                                                       |\n|---------------------------|-------------------------------------------------------------------------------------------------------------------|\n|INFO_RECEIVED              | Carrier has received request from shipper and is about to pick up the shipment.                                   |\n|IN_TRANSIT                 | Carrier has accepted or picked up shipment from shipper. The shipment is on the way.                              |\n|OUT_FOR_DELIVERY           | Carrier is about to deliver the shipment, or it is ready to pickup.                                               |\n|FAILED_ATTEMPT             | Carrier attempted to deliver but failed, and usually leaves a notice and will try to deliver again.               |\n|DELIVERED                  | The shipment was delivered successfully.                                                                          |\n|AVAILABLE_FOR_PICKUP       | The package arrived at a pickup point near you and is available for pickup.                                       |\n|EXCEPTION                  | Custom hold, undelivered, returned shipment to sender or any shipping exceptions.                                 |\n|EXPIRED                    | Shipment has no tracking information for 30 days since added.                                                     |\n|PENDING                    | Tracking information not available yet.                                                                           |                                                                    |\n"},"message":{"minLength":1,"type":"string","description":"Normalized tracking message.\n\n|Message|Description|Shipment Status|\n|----|----|----|\n|DELIVERED|Shipment delivered successfully|DELIVERED|\n|Picked up by the customer|Package picked up by the customer|DELIVERED|\n|Sign by customer|Package delivered to and signed by the customer|DELIVERED|\n|Delivered and received cash on delivery|Package delivered to the customer and cash collected on delivery|DELIVERED|\n|Available for pickup|The package arrived at a pickup point near you and is available for pickup|AVAILABLE_FOR_PICKUP|\n|EXCEPTION|Delivery of the package failed due to some shipping exception|EXCEPTION|\n|Customer moved|Delivery of the package failed as the customer relocated|EXCEPTION|\n|Customer refused delivery|Delivery of the package failed as the recipient refused to take the package due to some reason|EXCEPTION|\n|Delayed (Customs clearance)|Package delayed due to some issues during the customs clearance|EXCEPTION|\n|Delayed (External factors)|Package delayed due to some unforeseen reasons|EXCEPTION|\n|Held for payment|The package being held due to pending payment from the customer's end|EXCEPTION|\n|Incorrect Address|Package not delivered due to incorrect recipient address|EXCEPTION|\n|Pick up missed|Package available for the pickup but not collected by the customer|EXCEPTION|\n|Rejected by carrier|Package rejected by the carrier due to noncompliance with its guidelines|EXCEPTION|\n|Returning to sender|The package is on its way back to the sender|EXCEPTION|\n|Returned to sender|The return package has been successfully received by the sender|EXCEPTION|\n|Shipment damage|Shipment damaged|EXCEPTION|\n|Shipment lost|Delivery of the package failed as it got lost|EXCEPTION|\n|Failed Attempt|The delivery of the package failed due to some reason. Courier usually leaves a notice and will try to deliver again|FAILED_ATTEMPT|\n|Addressee not available|Recipient not available at the given address|FAILED_ATTEMPT|\n|Business Closed|Business is closed at the time of delivery|FAILED_ATTEMPT|\n|In Transit|Shipment on the way|IN_TRANSIT|\n|Acceptance scan|Shipment accepted by the carrier|IN_TRANSIT|\n|Arrival scan|Shipment arrived at a hub or sorting center|IN_TRANSIT|\n|Arrived at the destination country/region|International shipment arrived at the destination country/region|IN_TRANSIT|\n|Customs clearance completed|Customs clearance completed|IN_TRANSIT|\n|Customs clearance started|Package handed over to customs for clearance|IN_TRANSIT|\n|Departure Scan|Package departed from the facility|IN_TRANSIT|\n|Problem resolved|Problem resolved and shipment in transit|IN_TRANSIT|\n|Forwarded to a different delivery address|Shipment forwarded to a different delivery address|IN_TRANSIT|\n|Info Received|The carrier received a request from the shipper and is about to pick up the shipment|INFO_RECEIVED|\n|Out for Delivery|The package is out for delivery|OUT_FOR_DELIVERY|\n|Customer contacted|The customer is contacted before the final delivery|OUT_FOR_DELIVERY|\n|Delivery appointment scheduled|A delivery appointment is scheduled|OUT_FOR_DELIVERY|\n|PENDING|No information available on the carrier website or the tracking number is yet to be tracked|PENDING|\n|Carrier account not connected|It represents the shipments are pending due to no connection with carrier accounts|PENDING|\n|Label created, no updates yet|The order has been processed/packaged, but not scanned at a shipping location yet|PENDING|\n|Wrong carrier|There is no tracking info available because the carrier is wrong|PENDING|\n|No recent updates|There have been no new tracking updates in the last 120 days|PENDING|\n|Unrecognized carrier|AfterShip can’t track this type of shipment as the carrier is unrecognized.|PENDING|\n|Expired|No tracking information of the shipment, from the last 30 days|EXPIRED|\n"},"trackingUrl":{"type":"string","description":"Official tracking URL of the carrier (if any)."},"redirectUrl":{"type":"string","description":"Delivery instructions (delivery date or address) can be modified by visiting the link if supported by the carrier."},"estimatedDeliveryDate":{"type":"string","description":"'The estimated delivery date provided by the carrier. It is in the format ```YYYY-MM-DDThh:mm:ssZ``` for the recipent's timezone.'","format":"date-time"},"lastUpdatedAt":{"type":"string","description":"The date and time the shipment was updated. It is in the format ```YYYY-MM-DDThh:mm:ssZ``` for the timezone GMT+0.","format":"date-time"},"deliveryDate":{"type":"string","description":"'The date and time the shipment was delivered. It is in the format ```YYYY-MM-DDThh:mm:ssZ``` for the recipent's timezone.'","format":"date-time"},"signedBy":{"type":"string","description":"Signed by information for delivered shipment."},"failedDeliveryAttempts":{"type":"string","description":"Number of failed attempts courier tried to deliver the card."},"lastCheckpoint":{"$ref":"#/components/schemas/lastCheckpoint"}}},"lastCheckpoint":{"type":"object","description":"The tracking information of the last checkpoint","properties":{"checkpointTime":{"type":"string","description":"The date and time of the checkpoint event, provided by the carrier. It is in the format ```YYYY-MM-DDThh:mm:ssZ``` for the timezone of the checkpoint.","format":"date-time"},"city":{"minLength":1,"type":"string","description":"The city info provided by carrier."},"countryName":{"type":"string","description":"The country/Region name of the checkpoint, may also contain other location information."},"message":{"type":"string","description":"The checkpoint message."}}},"services":{"required":["issuance","delivery"],"properties":{"cardProductId":{"$ref":"#/components/schemas/cardProductId"},"issuance":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[a-zA-Z0-9_-\\s]{1,64}$","description":"The type of issuance.\n<br/>  \n|Attribute|Description|\n|-------|-------|\n|CREATION|Issuance of a brand-new card to a user|\n|RENEWAL|An existing card reaches its expiration date and needs to be replaced with a new one for continued use|\n|REPLACEMENT|An existing card needs to be reissued due to loss, theft, or damage.|\n"},"priority":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[a-zA-Z0-9_-\\s]{1,64}$","description":"The level of priority agreed for the card production (defined during the onboarding of D1).\n"},"delivery":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[a-zA-Z0-9_-\\s]{1,64}$","description":"The shipment method (defined during the onboarding of D1).\n"},"packaging":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[a-zA-Z0-9_-\\s]{1,64}$","default":"NO_PACK","description":"Unique identifier of the packaging (defined during the onboarding of D1).\n"},"cardCarrier":{"type":"string","minLength":1,"maxLength":64,"default":"NO_CARRIER","pattern":"^[a-zA-Z0-9_-\\s]{1,64}$","description":"Unique identifier of the card carrier (defined during the onboarding of D1).\n"}}},"cardProductId":{"type":"string","description":"Unique identifier of the type of card ( defined during the onboarding of D1)","minLength":1,"maxLength":48,"pattern":"^[A-Za-z0-9_-]{1,48}$"},"cardPackageDetails":{"type":"object","properties":{"plastic":{"type":"string","description":"Reference of the plastic used for the card\n","minLength":2,"maxLength":40},"artworkId":{"type":"string","description":"Reference of the artwork printed on the card\n","minLength":2,"maxLength":40},"cardCarrier":{"type":"string","description":"Reference of the card carrier used for the card\n","minLength":2,"maxLength":100},"envelope":{"type":"string","description":"Reference of the envelope used for the card\n","minLength":2,"maxLength":100},"package":{"type":"string","minLength":2,"maxLength":100,"description":"Reference of the package used for the card\n"},"cardActivationLabel":{"type":"string","minLength":2,"maxLength":100,"description":"Reference of the activation label used for the card\n"},"inserts":{"type":"array","minItems":0,"maxItems":10,"items":{"type":"string"},"description":"List of inserts\n"}}},"addressInProduceNotification":{"type":"object","required":["line1","zipCode","city","countryCode"],"properties":{"companyName":{"type":"string","description":"The name of the company.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line1":{"type":"string","description":"The first line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line2":{"type":"string","description":"The second line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line3":{"type":"string","description":"The third line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"city":{"type":"string","description":"The city name.","minLength":1,"maxLength":32,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,32}$"},"state":{"type":"string","description":"The state.","minLength":1,"maxLength":30,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,30}$"},"zipCode":{"type":"string","description":"The zip Code.","minLength":1,"maxLength":10,"pattern":"^[0-9A-Z- ]{1,10}$"},"countryCode":{"type":"string","description":"The country code, based on ISO 639-1 alpha-2 format","minLength":2,"maxLength":2,"pattern":"^[A-Z]{2}$"}}},"DigitizeDetails":{"title":"DIGITIZE operation","type":"object","description":"The card digitization details","required":["tbd"],"properties":{"deviceInformation":{"$ref":"#/components/schemas/deviceInformation"},"digitalCardsDetails":{"type":"array","minItems":1,"maxItems":2,"items":{"type":"object","required":["generalInformation","credentials"],"properties":{"isPrimary":{"description":"Flag indicating whether the digital card was create by the primary TSP or not.","type":"boolean","default":true},"generalInformation":{"type":"object","allOf":[{"$ref":"#/components/schemas/digitalCardInformation"},{"type":"object","properties":{"digitalCardRequestorInformation":{"$ref":"#/components/schemas/digitalCardRequestorInformation"}}}]},"credentials":{"type":"string","description":"The field is the json (cf http://www.json.org/ ) representation of the DIGITAL card.\nJWE encryption is used to secure the field (please refer to the [Encrypt sensitive data](../../../integrate-the-d1-api/encrypt-sensitive-data) for more details)\nDetails:\n\n{\n\n  \"pan\":\"...\",\n  \n  \"exp\":\"...\"\n  \n}\n\n\nThe PAN is Mandatory,  up to 19 digits.\n\nThe expiry date in the format MMYY. It is not provided for UPI scheme.","minLength":1,"maxLength":8196}}}},"eligibilityInformation":{"$ref":"#/components/schemas/eligibilityInformation"},"digitizationInformation":{"$ref":"#/components/schemas/digitizationInformation"}}},"deviceInformation":{"title":"deviceInformation","additionalProperties":false,"type":"object","description":"Provides details about the device that has been used for the card digitization.\nNote that this data is available only if the check eligbility has passed with success.\nData availability dependes on the requestor.","properties":{"deviceId":{"type":"string","minLength":1,"maxLength":128,"description":"Identifier of the token storage."},"digitalCardStorageType":{"type":"string","maxLength":32,"description":"Type of the token sorage location. Following values are possible:\n- HCE\n- SPAY_PHONE\n- SPAY_TABLET\n- SPAY_WATCH\n- SPAY_TV\n- IPHONE\n- IWATCH\n- IPAD\n- MAC_BOOK\n- ANDROID_PHONE\n- ANDROID_TABLET\n- ANDROID_WATCH\n- MOBILE_PHONE\n- TABLET\n- WATCH\n- MOBILE_PHONE_OR_TABLET\n- BRACELET\n- UNKNOWN"},"manufacturer":{"type":"string","minLength":1,"maxLength":32,"description":"Device manufacturer name"},"brand":{"type":"string","minLength":1,"maxLength":32,"description":"Device brand"},"model":{"type":"string","minLength":1,"maxLength":32,"description":"Device model"},"osVersion":{"type":"string","minLength":1,"maxLength":16,"description":"Device OS version"},"firmwareVersion":{"type":"string","description":"Device firmware version","minLength":1,"maxLength":32},"phoneNumber":{"type":"string","description":"Device phone number","minLength":1,"maxLength":20},"fourLastDigitPhoneNumber":{"type":"string","description":"","minLength":1,"maxLength":4},"deviceName":{"type":"string","maxLength":128,"description":"Device name set by the consumer"},"deviceParentId":{"type":"string","description":"ID of parent device. Applies to wearable","minLength":1,"maxLength":64},"language":{"type":"string","description":"Language set on the device in ISO 639-3","minLength":1,"maxLength":3},"serialNumber":{"type":"string","minLength":1,"maxLength":64,"description":"Device serial number"},"timeZone":{"type":"string","description":"Device time zone abbreviation. Example: PST, GMT, etc...","minLength":1,"maxLength":32},"timeZoneSetting":{"type":"string","maxLength":32,"description":"Who has set the timezone.\nPossible values:\n- NETWORK_SET\n- CONSUMER_SET"},"simSerialNumber":{"type":"string","description":"Secure Element serial number","minLength":1,"maxLength":24},"IMEI":{"type":"string","minLength":1,"maxLength":32},"networkOperator":{"type":"string","description":"Network operator name.","maxLength":32},"networkType":{"type":"string","description":"Network type. Can be:\n- CELLULAR\n- WIFI","maxLength":16}},"required":["deviceId"]},"digitalCardInformation":{"title":"digitalCardInformation","type":"object","description":"Provides information about the token. Note that this data is available only if the tokenization is successful or pending.","properties":{"digitalCardId":{"type":"string","minLength":1,"maxLength":64,"description":"Unique identifier of the token specified by the TSP"},"panSuffix":{"type":"string","minLength":4,"maxLength":4,"description":"Last four digits of the token"},"state":{"$ref":"#/components/schemas/digitalCardState"},"type":{"$ref":"#/components/schemas/tokenType"},"provisioningTime":{"type":"string","maxLength":32,"description":"The provisioning time of the token. Format ISO 8601 YYYY-MM-DDThh:mm:ssTZD"}},"required":["digitalCardId","panSuffix","state"]},"digitalCardState":{"type":"string","description":"the state of the digital card (token)","enum":["ACTIVE","INACTIVE","DELETED","DEPLOYMENT_ONGOING","PENDING_ACTIVATION"],"title":"digitalCardState"},"tokenType":{"type":"string","maxLength":16,"description":"The type of the token. Following values are supported:\n- SE\n- HCE\n- COF\n- ECOM\n- QRC"},"digitalCardRequestorInformation":{"title":"digitalCardRequestorInformation","additionalProperties":false,"type":"object","description":"Provides details about the digital card requestor.","properties":{"id":{"type":"string","description":"Digital Card requestor identifier. This is provided by the TSP itself.","minLength":11,"maxLength":11},"walletId":{"type":"string","description":"MasterCard ONLY. Wallet Application identifier","maxLength":32},"name":{"type":"string","maxLength":256,"description":"Wallet or Merchant human readable name"},"tspId":{"type":"string","maxLength":11,"minLength":11,"description":"VISA only. Identifiers of the couple Token Requestor - Token Service Provider"},"originalDigitalCardRequestorId":{"type":"string","description":"Applies only to VISA in case of token for token provisioning","minLength":11,"maxLength":11}}},"eligibilityInformation":{"type":"object","description":"Provides details about the eligibility check operation","properties":{"cardBIN":{"type":"string","minLength":6,"maxLength":6},"eligible":{"type":"boolean"},"cardProduct":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"name":{"type":"string","minLength":1,"maxLength":256}}}},"required":["cardBIN","eligible"]},"digitizationInformation":{"type":"object","description":"Provides details about the tokenization (digitization) operation whatever the result is (that is, successful, pending or cancelled)","title":"digitizationInformation","properties":{"digitizationChecks":{"type":"object","required":["issuerVerifications","decisionEngineVerifications","digitalCardRequestorAssessment"],"properties":{"issuerVerifications":{"$ref":"#/components/schemas/issuerVerifications"},"decisionEngineVerifications":{"$ref":"#/components/schemas/decisionEngineVerifications"},"digitalCardRequestorAssessment":{"$ref":"#/components/schemas/digitalCardRequestorAssessment"},"verificationCodes":{"type":"array","maxItems":100,"description":"D1 Verification codes generated by the decision engine during rule evaluation. Following values are possible:\n\t \n|value |description| \n|-----------|----------------------------------| \n|TR_RECOMMENDATION_NOT_AVAILABLE|wallet recommendation is missing|\n|TR_DEVICE_SCORE_NOT_AVAILABLE|device scoring is missing|\n|TR_ACCOUNT_SCORE_NOT_AVAILABLE|account scoring is missing|","items":{"type":"string"}},"matchedRule":{"type":"object","description":"Decision Engine rule triggerig the final decision.\r\n\r\nApplicable only to Decision Engine Version V2","required":["id"],"properties":{"id":{"type":"string","description":"Unique identifier of the matching rule."},"name":{"type":"string","description":"Name of the matching rule."},"scenario":{"type":"object","description":"The actual matching scenario ","required":["id"],"properties":{"id":{"type":"string","description":"Unique identifier of the matched scenario."},"name":{"type":"string","description":"Name of the matched scenario."}}}}}}},"digitizationResult":{"type":"object","required":["flow"],"properties":{"flow":{"type":"string","description":"Tokenization Decision Engine assessment result.\nFollowing values are possible:\n- RED (DECLINE)\n- GREEN (APPROVE)\n- YELLOW (STEP-UP)","minLength":1,"maxLength":64,"enum":["RED","YELLOW","GREEN"]},"score":{"type":"string","minLength":1,"maxLength":1,"pattern":"[1-5]{1,1}$","description":"This is the final score the decision engine has computed considering all the verifications and the scoring from the requestor and/or TSP.\nScore goes from 1 (low trust) to 5 (high trust)."},"idAndVMethods":{"$ref":"#/components/schemas/idAndVMethods"},"digitizationDecisionTimestamp":{"type":"string","minLength":1,"maxLength":64,"description":"The time when the digitization decision has been sent to the TSP.\nThis parameter can be used by the Issuer to manage the notifications to cardholder in case of PENDING status of digitize operation.\nFormat ISO 8601 YYYY-MM-DDThh:mm:ssTZD\n"}}}},"required":["digitizationChecks","digitizationResult"]},"issuerVerifications":{"title":"issuerVerifications","type":"object","properties":{"cardIsExpired":{"$ref":"#/components/schemas/result"},"cardIsLostOrStolen":{"$ref":"#/components/schemas/result"},"wrongCVV":{"$ref":"#/components/schemas/result"},"fraudSuspect":{"$ref":"#/components/schemas/result"},"cardIsInvalid":{"$ref":"#/components/schemas/result"}},"required":["cardIsExpired","cardIsLostOrStolen","wrongCVV","fraudSuspect","cardIsInvalid"]},"result":{"title":"result","type":"object","properties":{"result":{"type":"string","enum":["YES","NO","NOT_APPLICABLE"]}}},"decisionEngineVerifications":{"title":"decisionEngineVerifications","type":"object","properties":{"tooManyDigitizationRequests":{"$ref":"#/components/schemas/result"},"tooManyCVVVerificationFailed":{"$ref":"#/components/schemas/result"},"walletPhoneNumberNotMatchingConsumerPhoneNumber":{"$ref":"#/components/schemas/result"},"digitizationCountExceededOnSameFPAN":{"$ref":"#/components/schemas/result"},"digitizationCountExceededOnSameDevice":{"$ref":"#/components/schemas/result"},"cardIsExpired":{"$ref":"#/components/schemas/result"},"cardIsInvalid":{"$ref":"#/components/schemas/result"},"wrongCVV":{"$ref":"#/components/schemas/result"},"CVVNotProvided":{"$ref":"#/components/schemas/CVVNotProvided"}},"required":["tooManyDigitizationRequests","tooManyCVVVerificationFailed","walletPhoneNumberNotMatchingConsumerPhoneNumber","digitizationCountExceededOnSameFPAN","digitizationCountExceededOnSameDevice","cardIsExpired","cardIsInvalid","wrongCVV","CVVNotProvided"]},"CVVNotProvided":{"title":"CVVNotProvided","type":"object","description":"If CVV has not been provided by the digital card requestor, then D1 verifies if this is incompatible with either the card capture method used or the digital card type requested.","properties":{"incompatibleWithCaptureMethod":{"$ref":"#/components/schemas/captureMethodIncompatible"},"incompatibleWithDigitalCardType":{"$ref":"#/components/schemas/digitalCardTypeIncompatible"}},"required":["incompatibleWithCaptureMethod","incompatibleWithDigitalCardType"]},"captureMethodIncompatible":{"title":"captureMethodIncompatible","type":"object","properties":{"result":{"type":"string","enum":["YES","NO","NOT_APPLICABLE"]}},"description":"If the capture method of the card details is NOT one of the following:\n- BANK_APP (card details from the Banking App)\n- TOKEN (card details derived by the TSP from an existing digital card)\n- ON-FILE (card details from a card stored on file)\n\nthen the absence of CVV is unexpected, the result will be YES"},"digitalCardTypeIncompatible":{"title":"digitalCardTypeIncompatible","type":"object","properties":{"result":{"type":"string","enum":["YES","NO","NOT_APPLICABLE"]}},"description":"If the digital card type required is NOT one of the following:\n- COF (card on file)\n- ECOM (e-Commerce)\n\nthen the absence of CVV is unexpected, the result will be YES"},"digitalCardRequestorAssessment":{"title":"digitalCardRequestorAssessment","type":"object","required":["averageScore","deviceScore","accountScore","recommendation"],"properties":{"averageScore":{"type":"string","description":"Average scoring from the digital card requestor. Following values are possible:\n\nNOT_APPLICABLE (score is based on data from digital card requestor. If the data is not available, average can't be computed).\n1\n2\n3\n4\n5"},"deviceScore":{"type":"string","description":"Following values are possible:\n\nNOT_APPLICABLE (score is based on data from digital card requestor. If the data is not available, score can't be provided).\n1\n2\n3\n4\n5"},"accountScore":{"type":"string","description":"Wallet Provider account scoring, low values means high risk.\nFollowing values are possible:\n\nNOT_APPLICABLE (score is based on data from digital card requestor. If the data is not available, score can't be provided).\n\n1 2 3 4 5"},"recommendation":{"$ref":"#/components/schemas/walletRecommendation"},"reasonCodesRecommendationDescription":{"type":"array","description":"This field shall allow to list the received Wallet Reason Code Recommendation(s).Values are mapped to more user friendly descriptions. The full list of mapped codes is available here: https://docs.payments.thalescloud.io/implement-tokenization/card-tokenization-request/processing-the-decision/decision-engine/data-validation-codes/wallet-reason-codes","uniqueItems":true,"items":{"type":"object"}}}},"walletRecommendation":{"type":"string","description":"Wallet/Digital Card Requestor colour recommended during the card tokenization request\n\nPlease note that in certain situations a recommendation might be not provided by the wallet.","enum":["NOT_APPLICABLE","GREEN","YELLOW","ORANGE","RED"]},"idAndVMethods":{"additionalProperties":false,"type":"object","properties":{"supported":{"type":"array","items":{"type":"string"}},"selected":{"type":"string","minLength":1,"maxLength":64,"description":"The following values are possible:\n- OTP_BY_SMS\n- OTP_BY_EMAIL\n- BANK_APP\n- CUSTOMER_SERVICE"}}},"pullOperation":{"title":"UPDATE_ORDER operation","type":"object","description":"The update order status notification details","required":["pullType","status"],"properties":{"pullType":{"type":"string","description":"The type of change to apply on the card order","enum":["ACCELERATE","ACCELERATE_AND_REDIRECT","CANCEL","REDIRECT"]},"status":{"$ref":"#/components/schemas/updateOrderStatus"},"newDeliveryAddress":{"description":"The new delivery address","$ref":"#/components/schemas/addressInPullNotification"}}},"updateOrderStatus":{"type":"string","enum":["PULL_SUCCESSFUL","PULL_FAILED"],"description":"The status of pull request.\n\n|status code                | description                                                                                                       |\n|---------------------------|-------------------------------------------------------------------------------------------------------------------|\n|PULL_SUCCESSFUL        | The pull request was successfully processed.                                                                          |\n|PULL_FAILED            | The pull request processing failed.                                                                                   |\n| \n"},"addressInPullNotification":{"allOf":[{"$ref":"#/components/schemas/addressCommonFields"}]},"addressCommonFields":{"type":"object","required":["lastName","line1","zipCode","city","countryCode"],"properties":{"title":{"type":"string","description":"The title.","minLength":1,"maxLength":40,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,40}$"},"firstName":{"type":"string","description":"The first name.","minLength":1,"maxLength":40,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,40}$"},"lastName":{"type":"string","description":"The last name.","minLength":1,"maxLength":40,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,40}$"},"companyName":{"type":"string","description":"The name of the company.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line1":{"type":"string","description":"The first line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line2":{"type":"string","description":"The second line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"line3":{"type":"string","description":"The third line of the address.","minLength":1,"maxLength":64,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,64}$"},"city":{"type":"string","description":"The city name.","minLength":1,"maxLength":32,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,32}$"},"state":{"type":"string","description":"The state.","minLength":1,"maxLength":30,"pattern":"^[\\p{L}\\p{N}\\p{M} ,.'_#;:\\/-]{1,30}$"},"zipCode":{"type":"string","description":"The zip Code.","minLength":1,"maxLength":10,"pattern":"^[0-9A-Z- ]{1,10}$"},"countryCode":{"type":"string","description":"The country code, based on ISO 639-1 alpha-2 format","minLength":2,"maxLength":2,"pattern":"^[A-Z]{2}$"},"email":{"type":"string","description":"The email, used for card shipment contact purpose.","minLength":1,"maxLength":255,"pattern":"^[a-zA-Z0-9_+&*-]+(?:\\.[a-zA-Z0-9_+&*-]+)*@(?:[a-zA-Z0-9-]+\\.)+[a-zA-Z]{2,15}$"}}},"trackingOperation":{"type":"object","title":"STANDALONE_TRACKING","description":"The card tracking details","required":["status"],"properties":{"status":{"type":"string","enum":["CARD_SHIPPED","CARD_RETURNED"],"description":"The current status of card.\n\n- CARD_SHIPPED: The card has been picked up by the carrier.\n- CARD_RETURNED: The card has been returned back to sender and destroyed.\n"},"trackingType":{"type":"string","enum":["PRODUCTION","SHIPMENT","RETURN"],"description":"The current status of card.\n\n- PRODUCTION: Track Card Production.\n- SHIPMENT: Track Card Production and Shipment.\n- RETURN: Track Card return.\n"},"productionSite":{"maxLength":50,"minLength":0,"type":"string","description":"The factory where the card is produced."},"shipment":{"$ref":"#/components/schemas/shipment"}}},"errorGenericWithErrorCodeOutbound":{"additionalProperties":false,"type":"object","description":"Generic error returned by the APIs.","properties":{"errorCode":{"type":"string","description":"The type of the error"},"error":{"type":"string","description":"Provide more error details if possible.<br/>For example name of the field with invalid format."}}}},"responses":{"ServiceUnavailableError-outbound":{"description":"The service is temporarily unavailable. D1 will retry the request later."}}},"paths":{"/notifications/d1/v2/issuers/{issuerId}/cards":{"post":{"parameters":[{"schema":{"type":"string"},"in":"header","name":"Authorization","description":"Oauth Access token (optional)"}],"summary":"Notify Card Operations","operationId":"notifyCardOperations","description":"This request is used by D1 to notify the system of the bank about any card status update.<br>\nThere is a retry mechanism in case the notification has not been sent.\nThus the bank system can use this notification to synchronize card status with their card repository.<br>\nThe number max of card status update in the notification is defined at onboarding time according to bank's system capability.<br>\nEach update is linked to a given card id, and can contain a message dedicated for the final end-user.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"operations":{"type":"array","items":{"$ref":"#/components/schemas/CardStatus-operation-notification"}}}}}}},"responses":{"204":{"description":"Successful"},"400":{"description":"Bad Request, Invalid request URI, header, paramters.<br> \nD1 will not retry the request until the issue is considered as resolved.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorGenericWithErrorCodeOutbound"}}}},"401":{"description":"Unauthorized request.<br>\nD1 will not retry the request until the issue is considered as resolved.            ","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorGenericWithErrorCodeOutbound"}}}},"403":{"description":"Forbidden action<br>\nD1 will not retry the request until the issue is considered as resolved.\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorGenericWithErrorCodeOutbound"}}}},"404":{"description":"Ressource not found, Unknown issuerId<br>\nD1 will not retry the request until the issue is considered as resolved.\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorGenericWithErrorCodeOutbound"}}}},"500":{"description":"Internal Server Error. D1 will retry the request later.\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/errorGenericWithErrorCodeOutbound"}}}},"503":{"$ref":"#/components/responses/ServiceUnavailableError-outbound"}}}}}}
````


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.payments.thalescloud.io/click-to-pay/integrate-the-d1-api/d1-api-reference/outbound-api-from-d1/card-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
