> 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/merchant-tokenization/ja/bakkuendo/apis/server-api/click-to-pay.md).

# Click To Pay

## Create SRCi Transaction

> Provide all required data to the Merchant/PSP to build a click to pay transaction authorization request.

```json
{"openapi":"3.1.1","info":{"title":"Thales ETP Server API","version":"1.78"},"tags":[{"name":"Click to Pay"}],"servers":[{"url":"https://thales.api.com/tsh-cof"}],"paths":{"/srci/transactions":{"post":{"description":"Provide all required data to the Merchant/PSP to build a click to pay transaction authorization request.","operationId":"createSrciTransaction","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/xCorrelationId"}],"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","required":["encryptedData"],"properties":{"encryptedData":{"$ref":"#/components/schemas/encryptedPaymentCredentials"}}}}}},"400":{"description":"Bad request - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|INVALID_ARGUMENT|Cannot process the request because it is malformed or has incorrect/missing fields or values.|\n|INVALID_STATE|Request cannot be executed due to the incorrect field value.|\n|INVALID_AUTH_HEADER|Invalid Authentication header.|\n|INVALID_VALUE|Invalid parameter value.|\n|UNKNOWN_MERCHANT|The merchantId is probably wrong.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"},"schemeCorrelationId":{"$ref":"#/components/schemas/schemeCorrelationId"}}}}}},"401":{"description":"Unauthorized - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|UNAUTHENTICATED|Required authentication information is either missing or not valid for the resource.|\n|DECLINED|Operation declined.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"}}}}}},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"}},"tags":["Click to Pay"],"summary":"Create SRCi Transaction","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["merchantId","transactionId"],"properties":{"merchantId":{"$ref":"#/components/schemas/merchantId"},"transactionId":{"$ref":"#/components/schemas/transactionId"},"transactionData":{"$ref":"#/components/schemas/transactionDataSrci"}}}}}}}}},"components":{"parameters":{"authorization":{"schema":{"type":"string","maxLength":512,"minLength":1},"in":"header","description":"Technical identifier pre-defined at on-boarding that identifies the API\nconsumer.\nFormat shall be the string 'APIKEY' followed by a space and the\napi key value.\n</br> Example: APIKEY c03f88fe-01ba-11e8-ba89-0ed5f89f718b\n","name":"authorization","required":true},"xCorrelationId":{"schema":{"type":"string","maxLength":36,"minLength":1},"in":"header","description":"Technical identifier used for troubleshooting. \n</br>It helps on customer support when needed. \n</br>Each API request must be identified with a unique correlation Id.\n</br>It correlates the response and the request and eventually a notification if any. ","name":"x-correlation-id","required":true}},"schemas":{"encryptedPaymentCredentials":{"type":"string","maxLength":8196,"description":"The payment credentials data encrypted in a JWE structure (see security section in the documentation).\n\nOnce decrypted, the JWE plaintext contains the following JSON object:\n\n|JSON field parameter name|description|MOC|Length|\n|-------|-------|-------|-------|\n|dpan|The token PAN value provided for network token.|C|Up to 19|\n|exp|The token expiry date in the format MMYY provided for network token.|C|4|\n|cryptogram|The payment cryptogram to use with the token for a payment. Presence of the cryptogram depends on the transaction type and the scheme.|C|Up to 256|\n|fpan|The funding card PAN value. Only provided for PCI token.|C|Up to 19|\n|fpanExp|The funding card expiry date in the format MMYY. Only provided for PCI token.</li>|C|4|\n\nExample: {\"dpan:\"9580981500100002\", \"exp\":\"1222\", \"cryptogram\": \"45f8grzty7f4f5gs5s2c\"}"},"errorDetails":{"type":"string","maxLength":256,"description":"Additional information about the error. This optional parameter has no specific format as it depends on the different TSP API. It is sent for logging and troubleshooting purpose."},"schemeCorrelationId":{"type":"string","maxLength":128,"description":"Identifier used by the schemes for additional support."},"merchantId":{"type":"string","description":"Identifier of the merchant provided by Thales at on-boarding.","minLength":1,"maxLength":128},"transactionId":{"type":"string","description":"The unique transaction identifier.","minLength":1,"maxLength":128},"transactionDataSrci":{"type":"object","description":"Transaction data for Click to pay.","required":["amount","currencyCode"],"properties":{"amount":{"$ref":"#/components/schemas/amount"},"currencyCode":{"$ref":"#/components/schemas/currencyCode"}}},"amount":{"type":"string","description":"Transaction amount or maximum amount authorized. Shall be positive value.  Digits after the '.' are required in accordance with the scheme and currency code.","minLength":1,"maxLength":13,"pattern":"^(([1-9]{1}(\\d+)?)(\\.\\d+)?)|^([0]\\.(\\d+)?([1-9]{1})(\\d+)?)$"},"currencyCode":{"type":"string","minLength":3,"maxLength":3,"description":"ISO 4217 alphabetic currency code on 3 characters."}},"responses":{"404":{"description":"Not Found - Not Retryable"},"429":{"description":"Too Many Requests - Retryable"},"500":{"description":"Internal Server Error - Not Retryable"},"503":{"description":"Service Unavailable - Retryable"}}}}
```

## Notify SRCi

> Notify the Click to Pay system about the outcome of a transaction authorization.

```json
{"openapi":"3.1.1","info":{"title":"Thales ETP Server API","version":"1.78"},"tags":[{"name":"Click to Pay"}],"servers":[{"url":"https://thales.api.com/tsh-cof"}],"paths":{"/srci/transactions/confirmations":{"post":{"description":"Notify the Click to Pay system about the outcome of a transaction authorization.","operationId":"notifySrci","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/xCorrelationId"}],"responses":{"202":{"$ref":"#/components/responses/202"},"400":{"description":"Bad request - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|INVALID_ARGUMENT|Cannot process the request because it is malformed or has incorrect/missing fields or values.|\n|INVALID_STATE|Request cannot be executed due to the incorrect field value.|\n|INVALID_AUTH_HEADER|Invalid Authentication header.|\n|INVALID_VALUE|Invalid parameter value.|\n|UNKNOWN_MERCHANT|The merchantId is probably wrong.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"},"schemeCorrelationId":{"$ref":"#/components/schemas/schemeCorrelationId"}}}}}},"401":{"description":"Unauthorized - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|UNAUTHENTICATED|Required authentication information is either missing or not valid for the resource.|\n|DECLINED|Operation declined.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"}}}}}},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"}},"tags":["Click to Pay"],"summary":"Notify SRCi","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["merchantId","transactionId","confirmationData","transactionData"],"properties":{"merchantId":{"$ref":"#/components/schemas/merchantId"},"transactionId":{"$ref":"#/components/schemas/transactionId"},"confirmationData":{"$ref":"#/components/schemas/confirmationData"},"transactionData":{"$ref":"#/components/schemas/transactionDataSrci"}}}}}}}}},"components":{"parameters":{"authorization":{"schema":{"type":"string","maxLength":512,"minLength":1},"in":"header","description":"Technical identifier pre-defined at on-boarding that identifies the API\nconsumer.\nFormat shall be the string 'APIKEY' followed by a space and the\napi key value.\n</br> Example: APIKEY c03f88fe-01ba-11e8-ba89-0ed5f89f718b\n","name":"authorization","required":true},"xCorrelationId":{"schema":{"type":"string","maxLength":36,"minLength":1},"in":"header","description":"Technical identifier used for troubleshooting. \n</br>It helps on customer support when needed. \n</br>Each API request must be identified with a unique correlation Id.\n</br>It correlates the response and the request and eventually a notification if any. ","name":"x-correlation-id","required":true}},"responses":{"202":{"description":"Accepted"},"404":{"description":"Not Found - Not Retryable"},"429":{"description":"Too Many Requests - Retryable"},"500":{"description":"Internal Server Error - Not Retryable"},"503":{"description":"Service Unavailable - Retryable"}},"schemas":{"errorDetails":{"type":"string","maxLength":256,"description":"Additional information about the error. This optional parameter has no specific format as it depends on the different TSP API. It is sent for logging and troubleshooting purpose."},"schemeCorrelationId":{"type":"string","maxLength":128,"description":"Identifier used by the schemes for additional support."},"merchantId":{"type":"string","description":"Identifier of the merchant provided by Thales at on-boarding.","minLength":1,"maxLength":128},"transactionId":{"type":"string","description":"The unique transaction identifier.","minLength":1,"maxLength":128},"confirmationData":{"type":"object","description":"Confirmation data for transaction","required":["eventType","eventStatus","status","timestamp","networkTransactionIdentifier"],"properties":{"eventType":{"type":"string","description":"Event type associated with the update.","maxLength":12,"enum":["AUTHORISE","CAPTURE","REFUND","CANCEL","FRAUD","CHARGEBACK","OTHER"]},"eventStatus":{"type":"string","description":"Event type associated with the order.","maxLength":20,"enum":["CREATED","CONFIRMED","CANCELLED","FRAUD_CANCELLED","OTHERS"]},"status":{"type":"string","description":"Status of the event as provided by the SRC Initiator in the Confirmation message.","maxLength":10,"enum":["SUCCESS","FAILURE","OTHER"]},"reason":{"type":"string","description":"Description of the reason for the event associated with the order.","maxLength":64},"timestamp":{"$ref":"#/components/schemas/confirmationTimestamp"},"networkAuthorizationCode":{"type":"string","description":"Authorisation code associated with an approved transaction.","maxLength":25},"networkTransactionIdentifier":{"type":"string","description":"Unique authorisation related tracing value assigned by a Payment Network and provided in an authorisation response.","minLength":1,"maxLength":25}}},"confirmationTimestamp":{"type":"string","minLength":1,"maxLength":64,"description":"Merchant confirmation timestamp when the transaction was completed, compliant with ISO 8601."},"transactionDataSrci":{"type":"object","description":"Transaction data for Click to pay.","required":["amount","currencyCode"],"properties":{"amount":{"$ref":"#/components/schemas/amount"},"currencyCode":{"$ref":"#/components/schemas/currencyCode"}}},"amount":{"type":"string","description":"Transaction amount or maximum amount authorized. Shall be positive value.  Digits after the '.' are required in accordance with the scheme and currency code.","minLength":1,"maxLength":13,"pattern":"^(([1-9]{1}(\\d+)?)(\\.\\d+)?)|^([0]\\.(\\d+)?([1-9]{1})(\\d+)?)$"},"currencyCode":{"type":"string","minLength":3,"maxLength":3,"description":"ISO 4217 alphabetic currency code on 3 characters."}}}}
```

## Update Merchant Click to Pay

> Update the merchant setup for click to pay.

```json
{"openapi":"3.1.1","info":{"title":"Thales ETP Server API","version":"1.78"},"tags":[{"name":"Click to Pay"}],"servers":[{"url":"https://thales.api.com/tsh-cof"}],"paths":{"/merchants/{merchantId}/srci":{"put":{"description":"Update the merchant setup for click to pay.","operationId":"updateMerchantSrci","parameters":[{"$ref":"#/components/parameters/merchantId"},{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/xCorrelationId"}],"responses":{"202":{"$ref":"#/components/responses/202"},"400":{"description":"Bad request - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|INVALID_ARGUMENT|Cannot process the request because it is malformed or has incorrect/missing fields or values.|\n|INVALID_STATE|Request cannot be executed due to the incorrect field value.|\n|INVALID_AUTH_HEADER|Invalid Authentication header.|\n|INVALID VALUE|Invalid parameter value.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"},"schemeCorrelationId":{"$ref":"#/components/schemas/schemeCorrelationId"}}}}}},"401":{"description":"Unauthorized - Not Retryable","content":{"application/json":{"schema":{"type":"object","properties":{"errorCode":{"type":"string","maxLength":128,"description":"Optional information that details the error.\n\n-----------------\n|Error Code|Description|\n|-------|-------|\n|UNAUTHENTICATED|Required authentication information is either missing or not valid for the resource.|\n|DECLINED|Operation declined.|\n\n-----------------"},"errorDetails":{"$ref":"#/components/schemas/errorDetails"}}}}}},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"}},"tags":["Click to Pay"],"summary":"Update Merchant Click to Pay","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["supportedCardBrands","merchantLegalName","websiteUrl","merchantCountry"],"properties":{"supportedCardBrands":{"$ref":"#/components/schemas/supportedCardBrands"},"merchantLegalName":{"$ref":"#/components/schemas/merchantLegalName"},"websiteUrl":{"$ref":"#/components/schemas/websiteUrl"},"merchantCountry":{"$ref":"#/components/schemas/merchantCountry"}}}}}}}}},"components":{"parameters":{"merchantId":{"schema":{"type":"string","maxLength":128,"minLength":1},"in":"path","description":"The unique merchant identifier.","name":"merchantId","required":true},"authorization":{"schema":{"type":"string","maxLength":512,"minLength":1},"in":"header","description":"Technical identifier pre-defined at on-boarding that identifies the API\nconsumer.\nFormat shall be the string 'APIKEY' followed by a space and the\napi key value.\n</br> Example: APIKEY c03f88fe-01ba-11e8-ba89-0ed5f89f718b\n","name":"authorization","required":true},"xCorrelationId":{"schema":{"type":"string","maxLength":36,"minLength":1},"in":"header","description":"Technical identifier used for troubleshooting. \n</br>It helps on customer support when needed. \n</br>Each API request must be identified with a unique correlation Id.\n</br>It correlates the response and the request and eventually a notification if any. ","name":"x-correlation-id","required":true}},"responses":{"202":{"description":"Accepted"},"404":{"description":"Not Found - Not Retryable"},"429":{"description":"Too Many Requests - Retryable"},"500":{"description":"Internal Server Error - Not Retryable"},"503":{"description":"Service Unavailable - Retryable"}},"schemas":{"errorDetails":{"type":"string","maxLength":256,"description":"Additional information about the error. This optional parameter has no specific format as it depends on the different TSP API. It is sent for logging and troubleshooting purpose."},"schemeCorrelationId":{"type":"string","maxLength":128,"description":"Identifier used by the schemes for additional support."},"supportedCardBrands":{"type":"array","description":"Card networks that are supported for DPA registration.","maxItems":4,"minItems":1,"items":{"type":"string","maxLength":20,"enum":["MASTERCARD","VISA","DISCOVER","AMEX"]}},"merchantLegalName":{"type":"string","minLength":1,"maxLength":60,"description":"Legal name of the merchant.","pattern":"^[A-Za-z0-9-_. ]+$"},"websiteUrl":{"type":"string","minLength":1,"maxLength":100,"description":"Merchant website URL.","pattern":"^[A-Za-z0-9-_.:/]+$"},"merchantCountry":{"type":"string","minLength":2,"maxLength":2,"description":"Merchant country in ISO-3166-1 alpha-2 two-letter country code."}}}}
```


---

# 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/merchant-tokenization/ja/bakkuendo/apis/server-api/click-to-pay.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.
