---
updatedAt: 2026-06-02T20:06:00.000Z
agentTools:
  projectIndex: https://docs.zerohash.com/llms.txt
---

# Request payment quote

Retrieves a quote for a payout. Exactly one of `quantity` or `total` must be supplied. The returned `quote_id` can be passed to `POST /payments/execute` before `expire_ts`.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "zerohash API",
    "description": "\n### Authentication\n\nzerohash Uses HMAC SHA-256 verification to ensure the authenticity of API requests, follow instructions by link [https://docs.zerohash.com/reference/api-authentication](https://docs.zerohash.com/reference/api-authentication)\n\n<a href=\"/zh-swagger.json\">Download zerohash OpenAPI Schema as JSON</a>\n",
    "version": "1.7.0"
  },
  "servers": [
    {
      "url": "https://api.cert.zerohash.com",
      "description": "Certification API server"
    }
  ],
  "x-readme": {
    "proxy-enabled": false
  },
  "tags": [
    {
      "name": "Payments",
      "description": "Payment Services"
    }
  ],
  "paths": {
    "/payments/rfq": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Request payment quote",
        "description": "Retrieves a quote for a payout. Exactly one of `quantity` or `total` must be supplied. The returned `quote_id` can be passed to `POST /payments/execute` before `expire_ts`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/Signature"
          },
          {
            "$ref": "#/components/parameters/Timestamp"
          }
        ],
        "requestBody": {
          "description": "Quote parameters.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostPaymentsRequestForQuoteRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Quote generated. Execute the quote via `POST /payments/execute` before `expire_ts` elapses.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostPaymentsRequestForQuoteResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Code400"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Code403"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Code404"
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Code500"
                }
              }
            }
          },
          "503": {
            "description": "Service Unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Code503"
                }
              }
            }
          }
        }
      }
    }
  },
  "security": [
    {
      "apiKey": [],
      "apiPassphrase": []
    }
  ],
  "components": {
    "securitySchemes": {
      "apiKey": {
        "type": "apiKey",
        "description": "Your API public key. See the [Authentication guide](https://docs.zerohash.com/reference/api-authentication) for how to obtain keys.",
        "in": "header",
        "name": "X-SCX-API-KEY"
      },
      "apiPassphrase": {
        "type": "apiKey",
        "description": "The passphrase associated with your API key, set when the key was created.",
        "in": "header",
        "name": "X-SCX-PASSPHRASE"
      }
    },
    "parameters": {
      "Signature": {
        "name": "X-SCX-SIGNED",
        "in": "header",
        "description": "HMAC-SHA256 signature of the request, base64-encoded. See the [Authentication guide](https://docs.zerohash.com/reference/api-authentication) for the exact signing formula.",
        "required": true,
        "schema": {
          "type": "string"
        }
      },
      "Timestamp": {
        "name": "X-SCX-TIMESTAMP",
        "in": "header",
        "description": "Current Unix timestamp in seconds. Must be within 60 seconds of server time or the request is rejected.",
        "required": true,
        "schema": {
          "type": "string",
          "example": "1678901234"
        }
      }
    },
    "schemas": {
      "Code400": {
        "type": "object",
        "description": "Request was rejected by validation or a downstream service. `errors` is an array of human-readable messages; each entry describes a single validation failure or business-rule violation.",
        "required": [
          "errors"
        ],
        "properties": {
          "errors": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "example": [
              "body/amount must be >= 0",
              "body/asset is required"
            ]
          }
        }
      },
      "Code403": {
        "type": "object",
        "description": "Authentication or authorization failed. `error` is always `true`; `message` explains which check failed (missing API key, bad signature, insufficient permission, etc.).",
        "required": [
          "error",
          "message"
        ],
        "properties": {
          "error": {
            "type": "boolean",
            "example": true
          },
          "message": {
            "type": "string",
            "example": "This api key does not have write permission to this endpoint"
          }
        }
      },
      "Code404": {
        "type": "object",
        "description": "The requested resource does not exist or is not visible to the caller.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "example": "Not Found"
          }
        }
      },
      "Code500": {
        "type": "object",
        "description": "An unexpected error occurred on the server. The request can be retried after a short delay, but the same inputs may reproduce the error.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "example": "Internal Server Error"
          }
        }
      },
      "Code503": {
        "type": "object",
        "description": "A downstream dependency was unavailable, timed out, or returned a retryable error. Safe to retry; the response carries an `x-zh-allowretry: true` header. Every error response also carries an `x-zh-errorcode` header with a machine-readable error code (`unknown` when the failing service does not supply one).",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "example": "Service Unavailable"
          }
        }
      },
      "OBOParticipantEntity": {
        "type": "object",
        "properties": {
          "participant_code": {
            "type": "string",
            "description": "The identifier of the participant making the request",
            "example": "CUST01"
          },
          "account_group": {
            "type": "string",
            "description": "The identifier of the the account group",
            "example": "WRD1K0"
          },
          "account_label": {
            "type": "string",
            "description": "The account label associated with the account",
            "example": "general"
          }
        }
      },
      "UnderlyingCurrency": {
        "type": "string",
        "description": "the underlying asset",
        "example": "BTC",
        "enum": [
          "AAVE.ETH",
          "ADA",
          "ALGO",
          "AVAX",
          "BAT.ETH",
          "BCH",
          "BTC",
          "BUSD.ETH",
          "COMP.ETH",
          "DAI.ETH",
          "DOGE",
          "DOT",
          "EGLD",
          "EOS",
          "ETC",
          "ETH",
          "ETH.ARBITRUM",
          "GRT.ETH",
          "GYEN.ETH",
          "HBAR",
          "LINK.ETH",
          "LTC",
          "LUNA",
          "MATIC.ETH",
          "MATIC.POLYGON",
          "MKR.ETH",
          "MOB",
          "SAND.ETH",
          "SOL",
          "UNI.ETH",
          "USDC.ETH",
          "USDC.ALGO",
          "USDC.POLYGON",
          "USDC.SOL",
          "USDC.HBAR",
          "USDC.XLM",
          "USDC.AVAX",
          "USDT.ETH",
          "UST",
          "WBTC.ETH",
          "XEM",
          "XLM",
          "XRP",
          "XTZ",
          "ZUSD.ETH"
        ]
      },
      "QuotedCurrency": {
        "type": "string",
        "description": "the quoted asset",
        "example": "USD",
        "enum": [
          "CAD",
          "EUR",
          "GBP",
          "JPY",
          "MXN",
          "USD"
        ]
      },
      "PostPaymentsRequestForQuoteRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "participant_code",
          "side",
          "underlying_currency",
          "quoted_currency"
        ],
        "properties": {
          "participant_code": {
            "type": "string",
            "description": "The participant that the quote is being generated for. Typically the end customer.",
            "example": "CUST01"
          },
          "quoted_currency": {
            "$ref": "#/components/schemas/QuotedCurrency"
          },
          "underlying_currency": {
            "$ref": "#/components/schemas/UnderlyingCurrency"
          },
          "side": {
            "type": "string",
            "description": "The participant side of the quote - `buy` or `sell`.",
            "example": "buy",
            "enum": [
              "buy",
              "sell"
            ]
          },
          "total": {
            "type": "string",
            "description": "The desired amount expressed in the `quoted_currency`. Exactly one of `quantity` or `total` must be provided.",
            "example": "125.08"
          },
          "quantity": {
            "type": "string",
            "description": "The desired amount expressed in the `underlying_currency`. Exactly one of `quantity` or `total` must be provided.",
            "example": "6.761693"
          },
          "quote_expiry": {
            "type": "string",
            "description": "Requested time-to-live for the quote. Defaults to `5s` when omitted.",
            "example": "5m",
            "enum": [
              "5s",
              "30s",
              "1m",
              "5m",
              "10m",
              "15m"
            ]
          }
        }
      },
      "PostPaymentsRequestForQuoteResponse": {
        "type": "object",
        "properties": {
          "message": {
            "type": "object",
            "properties": {
              "request_id": {
                "type": "string",
                "format": "uuid",
                "description": "Request identifier echoed back from the request.",
                "example": "6fc13022-717b-45ff-bb05-011a7d4f3116"
              },
              "participant_code": {
                "type": "string",
                "description": "Platform participant code that owns the quote.",
                "example": "ABCDEF"
              },
              "underlying_currency": {
                "type": "string",
                "description": "The asset that is being bought or sold.",
                "example": "XRP"
              },
              "quoted_currency": {
                "type": "string",
                "description": "The currency that the `underlying_currency` is priced in.",
                "example": "USD"
              },
              "side": {
                "type": "string",
                "enum": [
                  "buy",
                  "sell"
                ],
                "description": "Participant side of the quote.",
                "example": "sell"
              },
              "quantity": {
                "type": "string",
                "description": "Amount expressed in the `underlying_currency`.",
                "example": "6.761693"
              },
              "price": {
                "type": "string",
                "description": "Unit price of the `underlying_currency` expressed in the `quoted_currency`.",
                "example": "1.317844179922575"
              },
              "quote_id": {
                "type": "string",
                "format": "uuid",
                "description": "Identifier of the quote. Pass to `POST /payments/execute` to execute.",
                "example": "a3790e55-d0cb-4c82-b525-4965966ce24d"
              },
              "expire_ts": {
                "type": "number",
                "format": "int64",
                "description": "Quote expiration as a Unix timestamp in milliseconds.",
                "example": 1777896067992
              },
              "account_group": {
                "type": "string",
                "description": "Account group that will be the counterparty to the trade (typically the zerohash account group).",
                "example": "00SCXM"
              },
              "account_label": {
                "type": "string",
                "description": "Account label on the counterparty side.",
                "example": "general"
              },
              "obo_participant": {
                "$ref": "#/components/schemas/OBOParticipantEntity"
              },
              "quote_notional": {
                "type": "string",
                "description": "Notional value of the quote in the `quoted_currency` (price × quantity), pre-spread.",
                "example": "8.91"
              },
              "disclosed_spread": {
                "type": "string",
                "description": "Absolute spread applied to the quote, in `quoted_currency` units.",
                "example": "0.468992514024906101025"
              },
              "disclosed_spread_rate": {
                "type": "string",
                "description": "Spread rate applied to the quote, in basis points (1 bps = 0.01%).",
                "example": "500"
              }
            }
          }
        }
      }
    }
  }
}
```