Liquidity

Retrieves a quote for the purchase or sale of a given asset. Exactly one of quantity or total must be supplied in the request body.

EU platforms: EUR is supported as the quoted_currency.

post/liquidity/rfq

Request

  • Base URL
    https://api.cert.zerohash.com
  • URL
    https://api.cert.zerohash.com/liquidity/rfq
  • Auth
    API key in header X-SCX-API-KEY and API key in header X-SCX-PASSPHRASE

Headers

X-SCX-SIGNEDstring required

HMAC-SHA256 signature of the request, base64-encoded. See the Authentication guide for the exact signing formula.

X-SCX-TIMESTAMPstring required
Example:1678901234

Current Unix timestamp in seconds. Must be within 60 seconds of server time or the request is rejected.

Request body

OR
OR
OR
OR
OR
OR
OR
OR
OR
OR

Example request

{
  "participant_code": "CUST01",
  "account_label": "general",
  "side": "buy",
  "underlying": "BTC",
  "quoted_currency": "USD",
  "quantity": "1.00"
}

Response

Successfully generated quote. Returns the quote envelope ({ message: {...} }) with pricing and an ephemeral quote_id.

Example response

{
  "message": {
    "request_id": "ce819fe8-b1d7-43bb-961c-e09ede0988d3",
    "participant_code": "CUST01",
    "quoted_currency": "USD",
    "side": "buy",
    "quantity": "1",
    "price": "11430.90",
    "quote_id": "32ad471b-824e-4f04-94ff-45c4439b4fe9",
    "expire_ts": 1568311649602,
    "account_group": "GRP001",
    "account_label": "sub_account_test",
    "obo_participant": {
      "participant_code": "CUST01",
      "account_group": "PLAT01",
      "account_label": "general"
    },
    "total_notional": "2.00",
    "underlying": "BTC",
    "asset_cost_notional": "2.00",
    "spread_notional": "2.12",
    "spread_bps": "50",
    "commission_notional": "5.00",
    "commission_bps": "25"
  }
}

Changes

    • breaking

      removed subschema #1: RFQ Base - Quantity subschema #2: RFQ Base - Total subschema #3: RFQ Custom Spread - Quantity subschema #4: RFQ Custom Spread - Total subschema #5: RFQ Custom Commission - Quantity subschema #6: RFQ Custom Commission - Total subschema #7: RFQ Fees - Quantity subschema #8: RFQ Fees - Total subschema #9: RFQ Payment Processor Fees - Quantity subschema #10: RFQ Payment Processor Fees - Total subschema #11: RFQ Full response from the request body oneOf list

    • warning

      added the new USDC.ETH enum value to the // response property for the response status

    • warning

      added the new USDC.ETH enum value to the // response property for the response status

    • warning

      added the new USDC.ETH enum value to the // response property for the response status

    • warning

      added the new USDC.ETH enum value to the // response property for the response status

    • warning

      added the new USDC.ETH enum value to the // response property for the response status

    • info

      added subschema #1: RFQ Base - Quantity subschema #2: RFQ Base - Total subschema #3: RFQ Custom Spread - Quantity subschema #4: RFQ Custom Spread - Total subschema #5: RFQ Custom Commission - Quantity subschema #6: RFQ Custom Commission - Total subschema #7: RFQ Fees - Quantity subschema #8: RFQ Fees - Total subschema #9: RFQ Payment Processor Fees - Quantity subschema #10: RFQ Payment Processor Fees - Total subschema #11: RFQ Full response to the request body anyOf list