All integrations

Saxo Bank

Research stocks and manage your Saxo Bank portfolio from AI clients — balances, positions, and Market/Limit buy/sell orders via MCP.

OAuth 13 tools

Overview

Connect Saxo Bank to give AI clients access to your brokerage account: research stocks, review balances and positions, and place or cancel Market/Limit buy and sell orders through the hosted Saxo Bank MCP integration.

Common use cases

  • Portfolio overview — balances, net positions, and working orders
  • Stock research — instrument search, details, info prices, and charts
  • Trading — precheck then place Market/Limit Buy or Sell stock orders; cancel working orders

Prerequisites

  • A Saxo Bank account with OpenAPI access
  • A stackgate.ai account
  • Your hub administrator has configured the Saxo OpenAPI app (AppKey/AppSecret) for simulation or live

Getting credentials

  1. Sign in to stackgate.ai.
  2. Go to My Integrations and open Saxo Bank.
  3. Click Connect Saxo Bank and approve the Saxo login prompt.
  4. stackgate.ai stores your OAuth tokens and default account securely — no manual API keys required.

After connect, use Edit tool access if you want to limit Write tools. Buy/sell tools are available when Write is enabled (default).

Using with AI clients

  • Dedicated endpoint: POST /mcp/saxobank with a Sanctum bearer token
  • Private gateway: one config for all integrations — use saxobank__* namespaced tools

See Documentation for HTTP authentication and private gateway setup.

Trading safety

  • Prefer Limit orders and confirm UIC, quantity, Buy/Sell, and account before placing.
  • Use precheck_order to review estimated costs and margin impact.
  • Simulation (sim) and live environments are controlled by hub configuration — confirm which environment your connection uses before trading real money.
  • Live bid/ask may be unavailable without Saxo market-data entitlements (common on sim). get_info_price then returns quote_access=unavailable plus fallback_last_close from daily charts — approximate research only, not a tradable quote.
  • Prefer default daily UpTo charts (get_chart). Short horizons that return no samples are retried as daily UpTo automatically.
  • After placing an order, cancel with the returned OrderId. Call list_orders only after place returns and before cancel — never race list with cancel.

Troubleshooting

  • 422 integration not configured — complete the OAuth connect flow in My Integrations.
  • 401 / token expired — use Reconnect Saxo Bank on the integration page.
  • 429 rate limit — Saxo limits sessions (including 1 order per second). Wait briefly and retry.
  • 409 conflict on place-order — identical order bodies within 15 seconds are rejected; pass a unique request_id.
  • Wrong account — pass account_key on tools, or reconnect so the default account is refreshed from Saxo.
  • quote_access=unavailable / NoAccess — missing market-data entitlement; use fallback_last_close or charts, not live bid/ask.
  • Empty chart samples — use daily horizon=1440 / mode=UpTo (defaults); the tool retries that window when a shorter request is empty.
  • list-orders empty right after place — wait for place to finish, then list; cancel using OrderId from the place response rather than racing list+cancel.

Available tools

  • get_client

    Get the connected Saxo Bank client profile, including ClientKey and default account.

  • list_accounts

    List Saxo Bank accounts for the connected client.

  • get_balances

    Get cash and margin balances. Defaults to the connected default account when account_key is omitted.

  • list_net_positions

    List aggregated net positions (recommended portfolio overview) for the connected client.

  • list_positions

    List individual open positions for the connected client.

  • list_orders

    List open orders for the connected client. Use status=Working for market-active orders. Call after place-order returns and before cancel — never in parallel with cancel_order. Prefer canceling by OrderId from the place response.

  • search_instruments

    Search tradable instruments by keywords. Defaults to AssetTypes=Stock (stocks-first).

  • get_instrument_details

    Get instrument details including supported order types for a UIC and AssetType.

  • get_info_price

    Get an info price quote for an instrument. When live bid/ask is unavailable (common on sim or without market-data entitlements), returns quote_access=unavailable plus fallback_last_close from daily charts for approximate research — not a tradable quote.

  • get_chart

    Get OHLC chart samples for an instrument. Defaults to daily bars (horizon=1440, mode=UpTo, time=now). If a shorter window returns no samples, automatically retries daily UpTo.

  • precheck_order

    Precheck a stock order for costs and margin impact without placing it. Use before place_order.

  • place_order

    Place a Market or Limit stock order (buy or sell). Always confirm details with the user first. Prefer Limit over Market. Response includes OrderId — use it for cancel_order; list orders only after place returns and before cancel.

  • cancel_order

    Cancel one or more working orders by OrderId on an account. Prefer OrderId from place_order; do not race with list_orders.

MCP endpoint: https://stackgate.ai/mcp/saxobank (HTTP) or via the private gateway.