Ondo GM Backend API (Ondo Stocks / Global Markets)

REST + gRPC API for tokenized-stock (Ondo Stocks) prices, market data, dividends, contract addresses, trading limits, market status and mint/redeem attestations.

OpenAPI Specification

ondo-finance-gm-openapi-original.json Raw ↑
{
  "openapi": "3.0.4",
  "info": {
    "title": "GM Backend API",
    "description": "An API spec for the Ondo GM Backend API.",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://api.gm.ondo.finance",
      "description": "GM Backend API"
    }
  ],
  "tags": [
    {
      "name": "Attestations",
      "description": "Get Mint and Redeem Attestations"
    },
    {
      "name": "Assets",
      "description": "Get Asset Price Information"
    },
    {
      "name": "Tickers",
      "description": "Get Ticker Information"
    },
    {
      "name": "Chains",
      "description": "Get On Chain Data"
    },
    {
      "name": "Limits",
      "description": "Get Trading Limits"
    },
    {
      "name": "Status",
      "description": "Get Market and Trading Statuses"
    }
  ],
  "paths": {
    "/v1/attestations": {
      "post": {
        "tags": [
          "Attestations"
        ],
        "summary": "Request a Mint or Redeem Attestation",
        "description": "An attestation is a signed payload that authorizes a user to mint or redeem tokens. Each attestation is only valid for a limited time and is determined by the duration in the request. A user can specify a duration of `short` for a tighter price spread or `long` for an extended validity period.\n\nNote: There are specific user and session limits which can prevent the creation of an attestation. For more information on limits, see the [Get Trading Limits](https://docs.ondo.finance/api-reference/limits/get-trading-limits) endpoint.\n\nSee also: [Error Codes](https://docs.ondo.finance/api-reference/error-codes)\n",
        "operationId": "createAttestation",
        "requestBody": {
          "description": "Request a mint or redeem attestation.",
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/AttestationByTokenAmountRequest"
                  },
                  {
                    "$ref": "#/components/schemas/AttestationByNotionalValueRequest"
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Attestation"
                }
              }
            }
          },
          "400": {
            "description": "One of the request parameters is invalid. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "invalid_symbol": {
                    "summary": "Invalid Symbol",
                    "value": {
                      "code": "INVALID_SYMBOL",
                      "message": "One of the request parameters is invalid.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_symbol"
                    }
                  },
                  "missing_user_address": {
                    "summary": "Missing User Address (Solana)",
                    "value": {
                      "code": "MISSING_USER_ADDRESS",
                      "message": "missing user address",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_user_address"
                    }
                  },
                  "invalid_user_address": {
                    "summary": "Invalid User Address (Solana)",
                    "value": {
                      "code": "INVALID_USER_ADDRESS",
                      "message": "invalid user address",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_user_address"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "MISSING_API_KEY",
                      "message": "missing API key",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_api_key"
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "The request was denied due to market state, asset state, or insufficient permissions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "market_closed": {
                    "summary": "Market Closed",
                    "value": {
                      "code": "MARKET_CLOSED",
                      "message": "market is closed",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#market_closed"
                    }
                  },
                  "asset_paused": {
                    "summary": "Asset Paused",
                    "value": {
                      "code": "ASSET_PAUSED",
                      "message": "asset trading is paused",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#asset_paused"
                    }
                  },
                  "read_only": {
                    "summary": "Read-Only API Key",
                    "value": {
                      "code": "READ_ONLY_API_KEY",
                      "message": "read-only API key cannot perform write operations",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#read_only_api_key"
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "The provided asset symbol does not exist and cannot be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "ASSET_NOT_FOUND",
                      "message": "asset not found",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#asset_not_found"
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "The account has exceeded its rate limits. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "RATE_LIMITED",
                      "message": "rate limit exceeded",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#rate_limited"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "An internal server error occurred. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INTERNAL_ERROR",
                      "message": "An internal server error occurred. Please see the returned message and documentation for details.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#internal_error"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "apiKey": []
          }
        ]
      }
    },
    "/v1/attestations/soft": {
      "post": {
        "tags": [
          "Attestations"
        ],
        "summary": "Request a Soft Attestation Quote",
        "description": "A soft quote provides pricing information for mint or redeem operations without creating an actual attestation. Unlike the [Request a Mint or Redeem Attestation endpoint](https://docs.ondo.finance/api-reference/attestations/request-a-mint-or-redeem-attestation), soft quotes:\n\n- Are not eligible for on-chain submission\n- Do not count against user limits (Active Notional Value, Session Notional Value, or Active Attestations)\n- Serve as pricing references for quote validation and user interface display\n- Do not include authentication fields such as `attestationId`, `userId`, `expiration`, or `signature`\n\nThis endpoint can be used to acquire estimated pricing without impacting trading limits or creating binding commitments.\n\nSee also: [Error Codes](https://docs.ondo.finance/api-reference/error-codes)\n",
        "operationId": "createSoftAttestationQuote",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/SoftQuoteByTokenAmountRequest"
                  },
                  {
                    "$ref": "#/components/schemas/SoftQuoteByNotionalValueRequest"
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SoftQuote"
                }
              }
            }
          },
          "400": {
            "description": "One of the request parameters is invalid. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INVALID_SYMBOL",
                      "message": "One of the request parameters is invalid.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_symbol"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "MISSING_API_KEY",
                      "message": "missing API key",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_api_key"
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "The request was denied due to market state, asset state, or insufficient permissions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "market_closed": {
                    "summary": "Market Closed",
                    "value": {
                      "code": "MARKET_CLOSED",
                      "message": "market is closed",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#market_closed"
                    }
                  },
                  "asset_paused": {
                    "summary": "Asset Paused",
                    "value": {
                      "code": "ASSET_PAUSED",
                      "message": "asset trading is paused",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#asset_paused"
                    }
                  },
                  "read_only": {
                    "summary": "Read-Only API Key",
                    "value": {
                      "code": "READ_ONLY_API_KEY",
                      "message": "read-only API key cannot perform write operations",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#read_only_api_key"
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "The provided asset symbol does not exist and cannot be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "ASSET_NOT_FOUND",
                      "message": "asset not found",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#asset_not_found"
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "The account has exceeded its rate limits. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "RATE_LIMITED",
                      "message": "rate limit exceeded",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#rate_limited"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "An internal server error occurred. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INTERNAL_ERROR",
                      "message": "An internal server error occurred. Please see the returned message and documentation for details.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#internal_error"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "apiKey": []
          }
        ]
      }
    },
    "/v1/assets/all/prices/latest": {
      "get": {
        "tags": [
          "Assets"
        ],
        "summary": "Get Current Prices for All Supported Assets",
        "description": "This endpoint retrieves the latest prices for all supported assets. Note that the `primaryMarket` represents the on-chain token while the `underlyingMarket`\nrepresents the off-chain collateralized stock. Assets can be sorted by price in either ascending or descending order.\n\nFor real-time price updates as they occur, rather than repeatedly polling this endpoint, use the [Price Streaming](https://docs.ondo.finance/api-reference/price-streaming) endpoint.\n\nPrices are intended for display only. For real-time trading prices, use the [Soft Attestation Quote](https://docs.ondo.finance/api-reference/attestations/request-a-soft-attestation-quote) API. We do not recommend using the price feeds as an oracle for these assets. An official oracle is in development and will be documented when available. For questions, contact [support@ondo.finance](mailto:support@ondo.finance).\n\nFor caching details on this endpoint, please see: [Endpoint Caching](https://docs.ondo.finance/api-reference/endpoint-caching).\n",
        "operationId": "getAllPrices",
        "parameters": [
          {
            "name": "sort",
            "in": "query",
            "description": "The sort direction for prices.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "desc",
                "asc"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AssetPrice"
                  }
                },
                "example": [
                  {
                    "primaryMarket": {
                      "symbol": "TSLAon",
                      "price": "48.516937826065743784"
                    },
                    "underlyingMarket": {
                      "ticker": "TSLA",
                      "price": "338.88"
                    },
                    "timestamp": 1755888858907
                  },
                  {
                    "primaryMarket": {
                      "symbol": "AAPLon",
                      "price": "171.383708297189751178"
                    },
                    "underlyingMarket": {
                      "ticker": "AAPL",
                      "price": "228.330909"
                    },
                    "timestamp": 1755888858893
                  },
                  "..."
                ]
              }
            }
          },
          "400": {
            "description": "One of the request parameters is invalid. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INVALID_SYMBOL",
                      "message": "invalid symbol; must be at least 3 characters long and end with 'on'",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_symbol"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "MISSING_API_KEY",
                      "message": "missing API key",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_api_key"
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "The account has exceeded its rate limits. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "RATE_LIMITED",
                      "message": "rate limit exceeded",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#rate_limited"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "An internal server error occurred. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INTERNAL_ERROR",
                      "message": "An internal server error occurred. Please see the returned message and documentation for details.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#internal_error"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "apiKey": []
          }
        ]
      }
    },
    "/v1/assets/{symbol}/prices/latest": {
      "get": {
        "tags": [
          "Assets"
        ],
        "summary": "Get Current Price for an Asset",
        "description": "This endpoint retrieves the latest price for a specific asset. Note that the `primaryMarket` represents the on-chain token while the `underlyingMarket`\nrepresents the off-chain collateralized stock.\n\nFor real-time price updates as they occur, rather than repeatedly polling this endpoint, use the [Price Streaming](https://docs.ondo.finance/api-reference/price-streaming) endpoint.\n\nPrices are intended for display only. For real-time trading prices, use the [Soft Attestation Quote](https://docs.ondo.finance/api-reference/attestations/request-a-soft-attestation-quote) API. We do not recommend using the price feeds as an oracle for these assets. An official oracle is in development and will be documented when available. For questions, contact [support@ondo.finance](mailto:support@ondo.finance).\n\nFor caching details on this endpoint, please see: [Endpoint Caching](https://docs.ondo.finance/api-reference/endpoint-caching).\n",
        "operationId": "getPrice",
        "parameters": [
          {
            "name": "symbol",
            "in": "path",
            "description": "The GM token symbol",
            "example": "AAPLon",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Price fetched successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AssetPrice"
                }
              }
            }
          },
          "400": {
            "description": "One of the request parameters is invalid. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INVALID_SYMBOL",
                      "message": "invalid symbol; must be at least 3 characters long and end with 'on'",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_symbol"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "MISSING_API_KEY",
                      "message": "missing API key",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_api_key"
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "The provided asset symbol does not exist and cannot be found. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "ASSET_NOT_FOUND",
                      "message": "The provided asset symbol does not exist and cannot be found.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#asset_not_found"
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "The account has exceeded its rate limits. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "RATE_LIMITED",
                      "message": "rate limit exceeded",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#rate_limited"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "An internal server error occurred. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INTERNAL_ERROR",
                      "message": "An internal server error occurred. Please see the returned message and documentation for details.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#internal_error"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "apiKey": []
          }
        ]
      }
    },
    "/v1/assets/all/prices/latest/enhanced": {
      "get": {
        "tags": [
          "Assets"
        ],
        "summary": "Get Enhanced Prices for All Supported Assets",
        "description": "This endpoint retrieves the latest prices along with the price change and percentage change in the last 24 hours of open market for all supported assets. Assets can be sorted by price in either ascending or descending order.\n\nFor real-time price updates as they occur, rather than repeatedly polling this endpoint, use the [Price Streaming](https://docs.ondo.finance/api-reference/price-streaming) endpoint.\n\nPrices are intended for display only. For real-time trading prices, use the [Soft Attestation Quote](https://docs.ondo.finance/api-reference/attestations/request-a-soft-attestation-quote) API. We do not recommend using the price feeds as an oracle for these assets. An official oracle is in development and will be documented when available. For questions, contact [support@ondo.finance](mailto:support@ondo.finance).\n\nFor caching details on this endpoint, please see: [Endpoint Caching](https://docs.ondo.finance/api-reference/endpoint-caching).\n",
        "operationId": "getAllAssetEnhancedPrices",
        "parameters": [
          {
            "name": "sort",
            "in": "query",
            "description": "The sort direction for prices.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "desc",
                "asc"
              ],
              "default": "desc"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AssetEnhancedPrice"
                  }
                },
                "example": [
                  {
                    "symbol": "NFLXon",
                    "price": "860.66471",
                    "priceChange24h": "26.80883",
                    "priceChangePct24h": "3.215043587628116264",
                    "timestamp": 1769190970623
                  },
                  {
                    "symbol": "QQQon",
                    "price": "533.707886795396811068",
                    "priceChange24h": "0.175407218134272389",
                    "priceChangePct24h": "0.032876577312266724",
                    "timestamp": 1769190970623
                  },
                  "..."
                ]
              }
            }
          },
          "400": {
            "description": "One of the request parameters is invalid. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INVALID_SYMBOL",
                      "message": "invalid symbol; must be at least 3 characters long and end with 'on'",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#invalid_symbol"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "MISSING_API_KEY",
                      "message": "missing API key",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#missing_api_key"
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "The account has exceeded its rate limits. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "RATE_LIMITED",
                      "message": "rate limit exceeded",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#rate_limited"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "An internal server error occurred. Please see the returned message and documentation for details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                },
                "examples": {
                  "error": {
                    "value": {
                      "code": "INTERNAL_ERROR",
                      "message": "An internal server error occurred. Please see the returned message and documentation for details.",
                      "documentation": "https://docs.ondo.finance/api-reference/error-codes#internal_error"
                    }
  

# --- truncated at 32 KB (171 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/ondo-finance/refs/heads/main/openapi/ondo-finance-gm-openapi-original.json