Skip to main content

Record Order Payment

Immutable Catalog Entry

This descriptor comes from the active versioned Portal catalog.

WRITEghl.record_order_payment
  • Contract tier: agent_ready
  • Risk: write
  • Catalog version: 2026-07-12.2
  • Descriptor hash: 5734175b72af1aad29c40ce8746d2b8bf96e9fc1f92ba811a88aaa2c04ac8388

Record a manual payment for a GHL order and update the order payment status. GHL category: Payments / Orders. This changes payment state and must only be used for a real payment the user explicitly confirms; validation should use disposable order fixtures only.

Request Body

{
"jsonrpc": "2.0",
"id": "ghl-record-order-payment-example",
"method": "tools/call",
"params": {
"name": "ghl.record_order_payment",
"arguments": {
"orderId": "orderId_123",
"altId": "altId_123",
"altType": "location",
"confirmApply": "confirmApply_example",
"body": {},
"card": {},
"meta": {},
"mode": "cash",
"notes": "notes_example",
"amount": 1
}
}
}

Arguments Schema

{
"type": "object",
"required": [
"orderId",
"altId",
"altType",
"confirmApply"
],
"properties": {
"body": {
"type": "object",
"description": "Optional raw GHL-supported record-payment body fields when the public docs do not render a field-specific schema.",
"additionalProperties": true
},
"card": {
"type": "object",
"description": "Optional card metadata accepted by GHL for manual card payments. Do not include raw card numbers, CVV, or secrets.",
"additionalProperties": true
},
"meta": {
"type": "object",
"description": "Optional provider metadata accepted by GHL.",
"additionalProperties": true
},
"mode": {
"enum": [
"cash",
"card",
"cheque",
"bank_transfer",
"other"
],
"type": "string",
"description": "Manual payment mode when supported by the GHL order record-payment payload."
},
"altId": {
"type": "string",
"description": "Location ID or alternate owner ID required by GHL Payments order APIs."
},
"notes": {
"type": "string",
"description": "Optional internal payment note. Avoid sensitive card or bank details."
},
"amount": {
"type": "number",
"description": "Optional payment amount to record when supported by GHL. Confirm whether the account expects major or minor currency units before use."
},
"cheque": {
"type": "object",
"description": "Optional cheque metadata accepted by GHL for cheque payments.",
"additionalProperties": true
},
"altType": {
"enum": [
"location"
],
"type": "string",
"description": "Alternate owner type for the order. Use location for sub-account orders."
},
"orderId": {
"type": "string",
"description": "GHL order ID for the payment to record."
},
"tenantId": {
"type": "string",
"description": "Tenant ID from list_tenants."
},
"confirmApply": {
"type": "string",
"description": "Required. Set exactly to \"CONFIRM APPLY\" only after the user explicitly confirms the payment should be recorded."
}
},
"additionalProperties": false
}

Output Schema

{
"type": "object",
"required": [
"ok",
"data",
"error",
"meta"
],
"properties": {
"ok": {
"type": "boolean",
"description": "Whether the GHL MCP operation completed successfully."
},
"data": {
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "array",
"items": {}
},
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
}
],
"description": "Tool-specific GHL or local navigation result when ok is true."
},
"meta": {
"type": "object",
"description": "Safe execution, routing, and timing metadata.",
"additionalProperties": true
},
"error": {
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "null"
}
],
"description": "Safe error details when ok is false; credential values are never returned."
}
},
"description": "Normalized GHL MCP response envelope.",
"additionalProperties": false
}

Code Examples

curl -X POST 'https://portal.madpanda3d.com/api/mcp' \
-H 'Authorization: Bearer mad_live_***' \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"id": "ghl-record-order-payment-example",
"method": "tools/call",
"params": {
"name": "ghl.record_order_payment",
"arguments": {
"orderId": "orderId_123",
"altId": "altId_123",
"altType": "location",
"confirmApply": "confirmApply_example",
"body": {},
"card": {},
"meta": {},
"mode": "cash",
"notes": "notes_example",
"amount": 1
}
}
}'

Example Responses

{
"ok": true,
"message": "Tool ghl.record_order_payment executed successfully.",
"note": "Response shape varies by MCP tool. Inspect live responses for exact fields."
}