MCP Endpoint
See MCP Transport for the full guide. This page is a quick reference.
POST /api/ucp/{slug}/mcp
Content-Type: application/jsonAvailable tools
| Tool | Description |
|---|---|
create_checkout_session | Create a checkout session |
get_checkout_session | Get session status and details |
complete_checkout_session | Mark session as completed |
cancel_checkout_session | Cancel an active session |
Example: tools/list
Request:
{ "jsonrpc": "2.0", "id": 1, "method": "tools/list", "params": {} }Response:
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"tools": [
{
"name": "create_checkout_session",
"description": "Create a UCP checkout session...",
"inputSchema": { "type": "object", "required": ["line_items"] }
}
]
}
}Example: tools/call
Request:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "create_checkout_session",
"arguments": {
"line_items": [{ "item": { "id": "gid://shopify/Product/123" }, "quantity": 1 }]
}
}
}Response:
{
"jsonrpc": "2.0",
"id": 2,
"result": {
"content": [{ "type": "text", "text": "{\"id\":\"...\",\"status\":\"requires_escalation\",...}" }]
}
}Last updated on