API Summary
Summary of APIs available
API Overview
Section titled “API Overview”Zodia Markets provides REST API for viewing balance, transactions and limits and WebSocket for real-time price streaming and order execution. Clients may also register a Webhook to retrieve real time transaction notifications.
API use cases
Section titled “API use cases”| Use Case | API |
|---|---|
| Real-time price updates | WebSocket |
| Trade execution on live prices | WebSocket |
| Specify beneficiary for crypto delivery on trade execution | WebSocket |
| Query account balances | REST |
| Historical transaction data requests | REST |
| Query Credit Limits | REST |
| Retrieve beneficiary and wallet information | REST |
| Transfer funds between trading and withdrawal accounts | REST |
| Retrieve list of available pairs | REST |
| Realtime trade, deposit, withdrawal and settlement status | Webhook |
REST API
Section titled “REST API”Technical Details
Section titled “Technical Details”| Detail | Value |
|---|---|
| Protocol | HTTPS |
| Authentication | API Key + HMAC signature |
| Request Format | JSON |
| Response Format | JSON |
| Rate Limit | 30 requests per second for each IP |
| Versioning | URI path (/3/) |
Key Endpoints
Section titled “Key Endpoints”POST /api/3/account # Get account balancesPOST /api/3/transfer/list # List of internal balance transfersPOST /api/3/transaction/list # List transaction historyPOST /api/3/beneficiaries # List beneficiariesPOST /api/3/user/limit # Get credit limitsView full REST API reference →
WebSocket API
Section titled “WebSocket API”Technical Details
Section titled “Technical Details”| Detail | Value |
|---|---|
| Protocol | WSS (WebSocket Secure) |
| Authentication | API Key + token exchange |
| Message Format | JSON |
| Rate limit | 30 messages per second for each account |
| Max updates | 4 updates per second for each active connection |
Authentication
Section titled “Authentication”WebSocket connections require:
- Initial HTTPS authentication to obtain session token (REST)
- Token sent in connection handshake
- Periodic token refresh for long-lived connections
View WebSocket authentication guide →
Webhook
Section titled “Webhook”Webhooks can be registered via the Customer Portal when creating the API key. Zodia Markets provides realtime transaction information on the webhook which will include:
- Transaction legs
- Crypto and fiat deposits
- Crypto and fiat withdrawals
API Feature Comparison
Section titled “API Feature Comparison”| Feature | REST API | WebSocket API | Webhook |
|---|---|---|---|
| Brokerage - RFS (Request for Stream) | ❌ Not available | ✅ Real-time streaming | ❌ Not available |
| Order execution | ❌ Not available | ✅ On streamed prices | ❌ Not available |
| Beneficiary delivery instructions | ❌ Not available | ✅ On streamed prices | ❌ Not available |
| Account balances | ✅ Query via POST | ❌ Use REST | ❌ Not available |
| Transaction history | ✅ With pagination | ❌ Use REST or Websocket | ✅ Real time changes |
| Initiate internal balance transfers | ✅ POST requests | ❌ Use REST | ❌ Not available |
| Manage and view beneficiaries | ✅ POST operations | ❌ Use REST | ❌ Not available |
| View credit limits | ✅ POST requests | ❌ Use REST | ❌ Not available |
Additional Requirements
Section titled “Additional Requirements”Forward Compatibility
Section titled “Forward Compatibility”A REST response or a WebSocket message may carry properties this documentation does not list, and your client must ignore any property it does not recognise rather than reject the payload — otherwise a release that adds a field will break your integration. This applies to both APIs, and to every response and message in them.
IP Whitelisting
Section titled “IP Whitelisting”IP whitelisting is generally not required although there may be exception. Contact your sales representative for restriction details.
Best Practices
Section titled “Best Practices”REST API
Section titled “REST API”- Implement exponential backoff for retries
- Cache balance queries when appropriate (don’t poll excessively)
- Use pagination for large transaction lists
- Handle rate limits gracefully with 429 responses
WebSocket API
Section titled “WebSocket API”- Implement automatic reconnection logic with exponential backoff
- Handle heartbeat timeouts (reconnect if no pong received)
- Maintain subscription state across reconnections
- Validate price timestamps and quoteID before order submission
- Set reasonable price expiry tolerances
Rate Limits & Throttling
Section titled “Rate Limits & Throttling”| API Type | Limit | Window | Per | Update Frequency |
|---|---|---|---|---|
| REST API | 30 | Second | IP connected | N/A |
| WebSocket | 30 | messages | Account | 4 updates per second |
| WebSocket (order) | 1 order | 250 ms | Account | N/A |
| Webhook | N/A | N/A | N/A | 1 update per second |