Orkid

OpenAPI Specification

Machine-readable API spec and how to use it.

Orkid provides an OpenAPI 3.1 specification for all public API endpoints.

Download

The OpenAPI spec is included in the @orkid-labs/sdk package:

npm install @orkid-labs/sdk

The file is at node_modules/@orkid-labs/sdk/openapi.yaml.

You can also download it directly: openapi.yaml.

Endpoints covered

EndpointMethodDescription
/api/v1/routePOSTGet an executable quote
/api/v1/solvePOSTExecute a gasless swap
/api/v1/accountGETPartner account info
/api/v1/usageGETUsage events
/api/v1/rebatesGETRebate ledger
/api/v1/confirmPOSTConfirm user-pays-gas tx
/api/v1/bridge/chainsGETBridge-supported chains
/api/v1/bridge/tokensGETCurated bridgeable tokens per chain
/api/v1/bridge/quotePOSTExecutable cross-chain bridge quote
/api/v1/bridge/statusGETDeposit lifecycle status
/api/v1/bridge/trackPOSTRegister a deposit for tracking

Using the spec

Generate a client

Use openapi-generator to generate a client in your language:

npx @openapitools/openapi-generator-cli generate \
  -i openapi.yaml \
  -g typescript-fetch \
  -o ./orkid-client

Supported languages include TypeScript, Python, Go, Rust, Java, Ruby, and more.

Import into Postman / Insomnia

Import the openapi.yaml file into Postman or Insomnia to get a pre-configured collection with all endpoints, schemas, and example payloads.

Validate against the spec

Use a validator to check your requests match the expected schema:

npx @redocly/cli lint openapi.yaml

Versioning

The OpenAPI spec follows the API version. The current version is 1.0.0. Breaking changes will increment the major version and be announced in the changelog.

Source

The SDK source (including openapi.yaml) is available at github.com/orkid-labs/orkid-sdk.

On this page