- Payment card. The current wallet response’s
agent_pay_supportindicates whether the card supports Agent Pay. The merchant or issuer may still decline this payment. - Merchant checkout page. The Agent can read the final total, fill the card form including embedded payment fields, submit payment, and view the merchant’s payment or order result.
- User verification. The user can complete any verification the bank requires, such as 3-D Secure or a one-time code.
- Main payment flow
- When user action is required
When a valid purchase authorization covers this payment,
get_credential can return the credential directly. Use credential.card as provided; decrypt only when the response contains key and payload.NOT_SUBMITTED; if it was submitted but the result cannot be confirmed, report UNKNOWN.
1. Read the final checkout amount
Use the final total shown on the merchant checkout page, including shipping and tax. Do not use the product list price, and do not treat the user’s maximum budget as the payment amount. Obtain contact and delivery details from the user or their merchant account. Select the website’s card payment option and disable any option to save payment details. If the user named a specific wallet card, obtain itspaymentInstrumentId from a fresh get_account_state response and check agent_pay_support: true. Otherwise, omit the card selector to use the default card.
2. Get the payment credential
The following is atools/call request. For a checkout total of USD 12.50, send amount: 1250:
wallet:read, payment:execute, instruction:read, and instruction:write.
Clink checks the payment card and matches an active purchase authorization. If an existing authorization covers this payment, the call can return the credential immediately. Otherwise, it can start a one-time authorization for the current checkout. You do not need to list or create purchase authorizations before every Browser Pay call.
Handle the actual response:
Read the action details from the structured response instead of inferring them from the label:
next_action.typeis the action category (REDIRECT_USERorSETUP_REQUIRED).next_action.params.redirect_kindexplains the reason for a redirect, such asPASSKEYorPAYMENT_METHOD_SETUP.next_action.params.setup_kindexplains the reason for setup, such asDEFAULT_CARDorPURCHASE_INSTRUCTION.next_action.params.resumabletells you whether the original checkout request can be retried after setup. Preserve the original checkout facts either way.next_action.params.actoridentifies who opens the link. TreatUSER_DEVICE_ONLYas a user-device action.
actor: "USER_DEVICE_ONLY", the user opens the link on their own device. The Agent must not open or preview it in its own browser. After presenting a Passkey or card setup link, wait for the same setup Operation:
events:read events:consume; also request offline_access when the platform needs a Refresh Token. Clink configures each platform’s scopes according to its enabled capabilities. See How to integrate MCP.
Once setup is complete, call get_credential again with the checkout facts. Do not pass the setup operationId. If the user selected a card for this checkout, keep the same paymentInstrumentId on every call. If the user chose to change the default card, call set_default_card first, then retry without the card selector.
Opening a link does not mean authorization is complete. If the response still requires action, follow the current next_action.
3. Read or decrypt the credential
Handle the actual returned shape rather than assuming every client receives the same result:
Cloud platforms configure their public key by contacting Clink offline. See Register an RSA public key.
How payment credentials are protected

key and payload, the credential is additionally encrypted with the platform’s public key. Decrypt it with the matching private key to read the card fields. This layer protects credential delivery; the purchase authorization confirmed with a Passkey determines the purchase scope. A response that returns credential.card directly is also subject to the authorization scope and credential expiry.
Keep payment identifiers
Keep these identifiers for reporting the result:orderId identifies Clink’s payment order; it is not the merchant’s order number. If the merchant returns an order number, keep that merchant order number separately.
A
get_credential Operation with status: "SUCCEEDED" means the credential was issued. It does not mean the merchant has been paid. get_operation never returns the credential and cannot independently verify the merchant’s payment result.get_credential.amount and confirm_result.paidAmount use minor currency units; the credential payload’s amount uses major currency units. For example, USD 12.50 is 1250 and 12.50 respectively. Convert according to the currency’s precision; do not multiply every currency by 100.
4. Fill and submit the merchant payment
Fill the returned card number, expiry, and security code into the card fields on the current checkout page, including payment provider fields embedded in the page. Use the expiry format the form requires. Use the returnedcardholderName and billingAddress when present; if billing information is missing, ask the user for it instead of inventing it.
Use the credential within its validity period. The decrypted expiry information and ttlMinutes, when present, take precedence over the estimate in the outer credential.expires_at.
Recheck the total before submitting:
- Total unchanged: submit and check the merchant’s result. If 3-D Secure or a one-time code is required, the user completes it.
- Total changed: do not submit the old credential. Report
NOT_SUBMITTEDwithfailureReason: "AMOUNT_CHANGED", then get a credential for the new total within the user’s authorization.
credential.display to describe the card to the user.
5. Report the observed result
Callconfirm_result to report this Browser Pay payment using the identifiers kept in step 3. The following example reports an observed successful payment:
When the success page shows the actual paid amount, supply both
paidAmount and currency. failureReason applies only to FAILED and NOT_SUBMITTED. See the full parameter reference.
For UNKNOWN, keep the payment identifiers and check the merchant’s existing order or payment result. Do not pay again. Report the final result before the returned report_deadline. Repeating the same outcome is safe; a conflicting final outcome is refused.
Clink records the Agent’s report and returns an agent_reported_result message. This record is not independent confirmation from the merchant. Refunds for this flow are handled by the merchant.
Give the user a brief result based on what the merchant page actually shows. For example, when the page confirms the following details:
Example Store confirmed payment of USD 12.50. Merchant order number: EX-1042.If the page does not show a merchant order number, omit it. Do not invent one or substitute Clink’s
orderId.
Recovery without a duplicate purchase
confirm_result is used only for Browser Pay. UCP Checkout and direct payments obtain their results through their own tools and must not be reported through this endpoint.
Code examples
The following examples show only how to request a credential and report the merchant result. Your browser executor still opens the merchant page, reads the final amount, fills the card fields, and submits payment. Do not write the card number, expiry, or security code to logs, model context, or persistent storage.- MCP
- RESTful API
Call After reading the final result on the merchant page, call If the response contains
get_credential through your MCP Client. amount uses minor currency units; for USD 12.50, send 1250.confirm_result with the identifiers returned by the same get_credential call:credential.key and credential.payload, decrypt them in a trusted platform component first, then pass the card fields to a controlled browser-filling component. Do not pass the decrypted result back to the model.