REST
POST
/api/v1/rfq/custom-expirationCreate Custom RFQ
Create a Custom Request for Quote (RFQ) to get a price quote for a trading pair. Has to be accepted within the time limit through Accept RFQ endpoint.
Auth:Bearer <api_key>
Tags:RFQ
Request
cURL
curl -X POST https://publicapi.sandbox.hercle.financial/api/v1/rfq/custom-expiration \
-H "Authorization: Bearer eyJhb..." \
-H "Content-Type: application/json" \
-d '{"key": "value"}'Headers
| Name | Type | Required | Description |
|---|---|---|---|
| Authorization | string | Yes | Bearer token for authentication |
| Content-Type | string | Yes | Content type of the request body |
Request Body
Schema
object
pair*:string
// Trading pair (e.g., BTCUSDT)side*:string(buy | sell)
// Order side - buy or sellsize*:number
// Size (base currency) - 0 to skipamount*:number
// Amount (quote currency) - 0 to skipexpirationInSeconds*:number
// Custom expiration time in seconds (default 15 - max 240)Example
{
"pair": "BTCUSDT",
"side": "buy",
"size": 0.5,
"amount": 25000
}Response
Success Response Schema
RFQ created successfully
| Field | Type | Description |
|---|---|---|
requestForQuoteId | string | Unique identifier for the RFQ |
userId | string | User identifier who created the RFQ |
instrument | string | Trading instrument (e.g., BTCUSDT) |
baseCurrency | string | Base currency of the pair |
quoteCurrency | string | Quote currency of the pair |
price | number | Quoted price for the trade |
size | number | Trade size in base currency |
side | string | Order side Allowed values: buysell |
amount | number | Trade amount in quote currency |
status | number | Current status of the RFQ 0→ Created1→ Executed2→ Cancelled3→ Pending |
expireDateTime | string | ISO 8601 timestamp when the RFQ expires |
requestDateTime | string | ISO 8601 timestamp when the RFQ was created |
Responses
RFQ created successfully
201 application/json
{
"requestForQuoteId": "123e4567-e89b-12d3-a456-426614174000",
"userId": "987e6543-e21b-12d3-a456-426614174000",
"instrument": "BTCUSDT",
"baseCurrency": "BTC",
"quoteCurrency": "USDT",
"price": 50000,
"size": 0.5,
"side": "buy",
"amount": 25000,
"status": 0,
"expireDateTime": "2024-06-01T12:30:00Z",
"requestDateTime": "2024-06-01T12:00:00Z"
}API Tester
Test this endpoint directly against the sandbox environment
Get your API key from Hercle Sandbox
https://publicapi.sandbox.hercle.financial/api/v1/rfq/custom-expiration