Accept a payment via ChatGPT
Last updated: September 9, 2026
Checkout.com's integration with OpenAI's Agentic Commerce Protocol (ACP) enables your customers to complete purchases for products they've discovered through ChatGPT's AI-powered chat interface.
Payment requests are handled entirely by Checkout.com. The card details pass directly between your customer and Checkout.com via ChatGPT, and do not reach your servers.
Information
You can only request card payments with the agentic commerce integration. Alternative payment methods (APMs) are not supported.
You need:
- A test account with Checkout.com.
- The
agentic-commerce:delegated-paymentscope enabled on your account. Contact your account manager to enable it, then create a secret key with this scope. - Your client ID registered in the Agentic Commerce Protocol. Contact your account manager to complete this step.
- Your processing channel ID.
- Your client ID.
- A ChatGPT account with a Plus plan or higher.
- The customer starts a conversation in your ChatGPT plugin and browses or selects a product.
- ChatGPT calls your MCP server's product tool to retrieve available items from your catalog.
- The customer selects a product and taps Buy, confirming their shipping address.
- ChatGPT calls your
create_checkout_sessiontool. Your MCP server creates the checkout session in your backend and returns delivery options to ChatGPT. The response includes your Checkout.com client ID (cli_xxx) in thepayment_providerobject. - ChatGPT renders the delivery options to the customer, who selects one.
- ChatGPT sends the selection to your MCP server to calculate sales tax and the final price.
- Your MCP server returns the total to ChatGPT, which renders the final amount to the customer.
- The customer reviews the total and confirms with "Pay". ChatGPT collects their card details and calls Checkout.com's delegated token endpoint to generate a payment token (
tok_xxx). - ChatGPT gathers the payment token, order details, and integrity signals, and sends them to your
complete_checkout_sessiontool. - Your MCP server calls the Checkout.com Payments API with
source.type: "token"to process the payment. Checkout.com accepts or declines the order. - Checkout.com processes the payment and returns the result. Your server confirms the order to the customer through ChatGPT, and all parties receive confirmation.
Build a ChatGPT plugin using the OpenAI Apps SDK. A ChatGPT plugin consists of an MCP server that exposes tools to ChatGPT, and an optional UI component rendered in an iframe.
OpenAI's official MCP SDK is the quickest way to get started:
1npm install @modelcontextprotocol/sdk @modelcontextprotocol/ext-apps zod
Your MCP server must:
- Advertise tools with JSON schema input and output contracts.
- Include tool annotations for each tool:
- Set
readOnlyHinttotruefor read-only tools such aslist_productsandget_checkout_session. - Set
destructiveHinttotruefor tools with irreversible side effects. - Set
openWorldHinttofalsefor tools that affect only a bounded target.
- Set
- Use Streamable HTTP or Server-Sent Events (SSE) transport.
Ensure your MCP server is reachable over HTTPS. For local development, use a tunneling tool such as ngrok or Cloudflare Tunnel.
- In ChatGPT, go to Settings > Advanced settings, and enable developer mode.
- Go to Connectors > Create, and provide your connector name, description, and the public
/mcpendpoint URL. - Select Create. If the connection is successful, ChatGPT lists the tools your server advertises.
Note
For production plugins, you must submit your plugin to OpenAI for approval before accepting live payments. This is not required for your test plugin.
Information
OpenAI requires ChatGPT plugins to use external checkout, directing customers to complete purchases on your own domain. Instant Checkout within ChatGPT is currently only available to select marketplace partners.
Extend your ChatGPT plugin by implementing the ACP checkout session request types in your MCP server. Checkout.com recommends you implement all request types to handle the full range of customer interactions.
| Request Type | Endpoint | Description |
|---|---|---|
Create a checkout session |
| Initialize a new checkout with items and customer information |
Retrieve a checkout session |
| Get the current state of an existing checkout |
Update a checkout session |
| Modify items, delivery options, or customer details |
Complete a checkout session |
| Finalize the checkout and process payment |
Cancel a checkout session |
| Cancel an active checkout session |
For the full ACP specification, see OpenAI's Agentic Commerce Protocol documentation.
When the customer selects a product, ChatGPT calls your create_checkout_session tool with the selected items:
1{2"items": [3{4"id": "prod_001",5"quantity": 16}7]8}
Create the checkout session in your backend and return the session details to ChatGPT. Include the checkoutRequest object in the structuredContent of your tool response, with your Checkout.com client ID in the payment_provider.merchant_id field:
1{2"content": [3{4"type": "text",5"text": "Checkout session created!\nSession ID: cs_1776170582038\nStatus: ready_for_confirmation\nTotal: $29.99 USD"6}7],8"structuredContent": {9"type": "checkout_session",10"session": {11"id": "cs_1776170582038",12"object": "checkout_session",13"status": "ready_for_confirmation",14"amount_total": 2999,15"currency": "usd",16"line_items": [17{18"id": "prod_001",19"name": "Signal Cap",20"quantity": 1,21"unit_price": 2999,22"total": 299923}24],25"payment_methods": ["card"],26"created_at": "2026-04-14T12:43:02.038Z"27},28"checkoutRequest": {29"id": "cs_1776170582038",30"payment_provider": {31"provider": "checkout",32"merchant_id": "cli_fx6zuwfrky3e7gy63ia2y3vdse",33"supported_payment_methods": ["card"]34},35"status": "ready_for_payment",36"currency": "USD",37"line_items": [38{39"id": "prod_001",40"item": { "id": "prod_001", "quantity": 1 },41"base_amount": 2999,42"discount": 0,43"subtotal": 2999,44"tax": 0,45"total": 299946}47],48"totals": [49{ "type": "subtotal", "display_text": "Subtotal", "amount": 2999 },50{ "type": "total", "display_text": "Total", "amount": 2999 }51],52"links": [53{ "type": "terms_of_use", "url": "https://www.checkout.com/legal/terms-and-conditions" },54{ "type": "privacy_policy", "url": "https://www.checkout.com/legal/privacy-policy" }55],56"payment_mode": "test"57}58}59}
ChatGPT uses the merchant_id value to call the Checkout.com delegated token endpoint and render the appropriate payment UI.
With the payment token, ChatGPT calls your get_checkout_session tool using the session ID:
1{2"session_id": "cs_1776170582038"3}
Return the current session state from your backend, including item details, status, and totals.
To modify an active checkout, ChatGPT calls your update tool with a POST /checkout_sessions/{id} request. For example, if you need to change the item quantity or the fulfillment address.
Apply the changes in your backend and return the updated session.
When the customer confirms the purchase, ChatGPT collects their card details, calls the Checkout.com delegated token endpoint, and sends the resulting token to your complete_checkout_session tool:
1{2"checkout_session_id": "cs_1776170582038",3"buyer": {4"name": "Jia Tsang",5"email": "jia.tsang@example.com"6},7"payment_data": {8"token": "tok_5pg3c3zuexlu3dehjhmkkbwpta",9"provider": "checkout",10"managed_by": "agentic_platform_psp",11"billing_address": {12"name": "Jia Tsang",13"line_one": "654 Main St.",14"city": "Anytown",15"state": "WY",16"country": "US",17"postal_code": "332211"18}19}20}
Use the payment_data.token value to call the Checkout.com Payments API with source.type set to "token":
Information
Your base URL's {prefix} value is unique to your account and environment. To learn how to retrieve your base URLs for the sandbox and production environments, see API endpoints.
post
https://{prefix}.api.checkout.com/payments
1{2"source": {3"type": "token",4"token": "tok_5pg3c3zuexlu3dehjhmkkbwpta",5"billing_address": {6"address_line1": "654 Main St.",7"city": "Anytown",8"state": "WY",9"zip": "332211",10"country": "US"11}12},13"amount": 2999,14"currency": "USD",15"payment_type": "Regular",16"merchant_initiated": false,17"authorization_type": "Final",18"capture": true,19"reference": "cs_1776170582038",20"customer": {21"email": "jia.tsang@example.com",22"name": "Jia Tsang"23},24"processing_channel_id": "pc_abcd1234efgh5678",25"risk": {26"enabled": true27}28}
Return the Checkout.com payment result to ChatGPT through your tool response to confirm the order to the customer.
When the customer cancels a purchase, ChatGPT calls your cancel_checkout_session tool with the session ID and a cancellation reason:
1{2"session_id": "cs_1776170582038",3"reason": "Customer requested cancellation"4}
Cancel the session in your backend and return an HTTP 200 response to confirm the cancellation to ChatGPT.
Use the following example prompts to test each ACP request in ChatGPT developer mode. Replace the product name with an item from your catalog.
| Use case | Prompt | Expected behavior |
|---|---|---|
List products | "List all products in the store." | ChatGPT calls your product tool and displays the catalog |
Create a checkout session | "Create a checkout session for 1 | ChatGPT calls your |
Retrieve a checkout session | "Get the details of the checkout session you just created." | ChatGPT calls your |
Complete a checkout | "Complete the checkout session you just created." | ChatGPT collects card details, generates a token, and calls your |
Cancel a checkout | "Please cancel my order." | ChatGPT calls your |
Use test cards to simulate different payment outcomes.