Trading API

Account

The key, its client, limits and trading accounts.

GET/api/open/v1/account

#The key, its client, limits and switches

Auth X-API-Key Trading API

Responses

200

OK

400

Bad request (invalid_json)

401

No / invalid / revoked / expired API key

403

Refused (IP, scope, brand switch, kill switch, account, inactive client)

404

Not found (also every path while the Open API is off on this server)

422

Invalid request or refused by the order checks (margin, levels, size, market closed ...)

429

Rate limited (Retry-After)

500

Internal error; unknown_outcome = look the order up before sending it again

503

Temporarily unavailable (prices, balance, quotes, rate-limit store)

curl "https://api.your-brand.com/api/open/v1/account" \
  -H "X-API-Key: $OCTOLIT_API_KEY"
Response 200
{
  "client_id": 1042,
  "key": {
    "id": 1042,
    "name": "Main",
    "prefix": "pk_live_3f",
    "scopes": [
      "read"
    ],
    "trading_account_ids": [
      55
    ],
    "ip_allowlist": [
      "string"
    ],
    "expires_at": "2026-11-11T09:31:00Z",
    "created_at": "2026-11-11T09:30:00.000000Z"
  },
  "trading_account_ids": [
    55
  ],
  "limits": {
    "requests_per_min": 1200,
    "client_requests_per_min": 1,
    "orders_per_sec": 10,
    "account_orders_per_sec": 1,
    "max_keys": 5
  },
  "websocket": true,
  "trading_stopped": true,
  "server_time": "2026-11-11T09:30:00.000000Z"
}
GET/api/open/v1/accounts

#Trading accounts this key may use, with balance figures

Auth X-API-Key Trading API

Responses

200

OK

400

Bad request (invalid_json)

401

No / invalid / revoked / expired API key

403

Refused (IP, scope, brand switch, kill switch, account, inactive client)

404

Not found (also every path while the Open API is off on this server)

422

Invalid request or refused by the order checks (margin, levels, size, market closed ...)

429

Rate limited (Retry-After)

500

Internal error; unknown_outcome = look the order up before sending it again

503

Temporarily unavailable (prices, balance, quotes, rate-limit store)

curl "https://api.your-brand.com/api/open/v1/accounts" \
  -H "X-API-Key: $OCTOLIT_API_KEY"
Response 200
{
  "accounts": [
    {
      "id": 1042,
      "name": "Main",
      "currency": "USD",
      "account_type": {
        "id": 1042,
        "name": "Main"
      },
      "demo": false,
      "active": true,
      "hidden": true,
      "platform": "internal",
      "tradable": true,
      "balance_available": true,
      "balance": 1.5,
      "equity": 1.5,
      "profit": 1.5,
      "margin": 1.5,
      "free_margin": 1.5,
      "margin_level": 1.5,
      "closed_profit": 1.5
    }
  ]
}
GET/api/open/v1/accounts/{id}

#One trading account

Auth X-API-Key Trading API

Path parameters

id integer required

Responses

200

OK

400

Bad request (invalid_json)

401

No / invalid / revoked / expired API key

403

Refused (IP, scope, brand switch, kill switch, account, inactive client)

404

Not found (also every path while the Open API is off on this server)

422

Invalid request or refused by the order checks (margin, levels, size, market closed ...)

429

Rate limited (Retry-After)

500

Internal error; unknown_outcome = look the order up before sending it again

503

Temporarily unavailable (prices, balance, quotes, rate-limit store)

curl "https://api.your-brand.com/api/open/v1/accounts/1042" \
  -H "X-API-Key: $OCTOLIT_API_KEY"
Response 200
{
  "account": {
    "id": 1042,
    "name": "Main",
    "currency": "USD",
    "account_type": {
      "id": 1042,
      "name": "Main"
    },
    "demo": false,
    "active": true,
    "hidden": true,
    "platform": "internal",
    "tradable": true,
    "balance_available": true,
    "balance": 1.5,
    "equity": 1.5,
    "profit": 1.5,
    "margin": 1.5,
    "free_margin": 1.5,
    "margin_level": 1.5,
    "closed_profit": 1.5
  }
}