GeminiGemini
SandboxGet API key
  • Crypto Trading
  • Prediction Markets
Changelog
Gemini Crypto Exchange LogoGemini Crypto Exchange Logo

© 2026 Gemini Space Station, Inc.

Getting Started
Market Makers
    Maker Rebate ProgramLiquidity Rewards Program
WebSocket
    IntroductionAuthenticationMessage Format
    Streams
      Book TickerL2 Partial DepthL2 Differential DepthTrade StreamOrder EventsBalance UpdatesPosition UpdatesContract Status
    Playground
      OverviewconninfopingtimeSUBSCRIBEUNSUBSCRIBELIST_SUBSCRIPTIONSdepthorder.placeorder.cancelorder.cancel_allorder.cancel_session
REST APIs
    Combos
    Events
    Terms
    Order Management
    Positions
    Rewards
Combo Contracts
    Overview
Tickers
    OverviewCryptoSportsCommoditiesWeather
SchemasAuthenticationMessage Format
Streams
    OverviewBook TickerL2 Partial DepthL2 Differential DepthTrade StreamOrder EventsBalance UpdatesPosition UpdatesContract Status
Utility
    conninfopingtime
Subscriptions
    SUBSCRIBEUNSUBSCRIBELIST_SUBSCRIPTIONS
L2 Data
    depth
Trading
    order.placeorder.cancelorder.cancel_allorder.cancel_session
WebSocket

Message Format

Our WebSocket API uses JSON-formatted messages for all communication.

Request Format

All requests follow a consistent structure:

Code
{ "id": "1", "method": "METHOD_NAME", "params": {...} }
FieldTypeRequiredDescription
idstring | numberYesUnique identifier for matching request/response
methodstringYesThe method to invoke
paramsobject | arrayNoMethod parameters (varies by method)

Response Format

Successful responses include the request ID and result:

Code
{ "id": "1", "status": 200, "result": {...} }
FieldTypeDescription
idstring | numberMatches the request ID
statusnumberHTTP status code
resultanyMethod-specific response data

Error Response

Error responses include error details:

Code
{ "id": "1", "status": 401, "error": { "code": -1002, "msg": "Authentication required" } }
FieldTypeDescription
idstring | numberMatches the request ID
statusnumberHTTP status code
error.codenumberInternal error code
error.msgstringHuman-readable error message

Error Codes

CodeHTTP StatusDescription
-1000500Internal server error
-1002401Authentication required
-1003429Rate limit exceeded
-1013400Invalid parameters
-1020400Unsupported operation
-2010400Order rejected
Last modified on June 2, 2026
AuthenticationStreams
JSON
JSON
JSON