Find something... ⌘K

SDK / Getting started

SDK hosts

The one host the SDK, the loans package and the command line call, what goes through it, and the Content-Security-Policy a page needs. It is for security reviewers and for teams that run the SDK in a browser.

One host

Every API call goes to https://openapi.maxy.co; the one exception is a key signer's own transactions (below). A page that runs the SDK needs one entry:

text Copy
Content-Security-Policy: connect-src 'self' https://openapi.maxy.co
Path on openapi.maxy.coWhat it carries
/v1/…The Maxy HTTP API: prices, quotes, orders, status
/x/orders, /x/auth, /x/views, /x/loans/…Maxy's own services: the solver's order calls, the wallet sign-in, read views of a signed-in wallet's own orders and loans, and the loans package's calls
/x/btc/…, /x/rpc/evm, /x/rpc/solanaBitcoin reads and broadcasts, and chain reads for every chain Maxy swaps on
Other /x/… pathsThe services a swap's legs use: the Solana settlement gateway, LI.FI, Tron's and Sui's APIs, and the Solana swap

The host passes each call on, adds the access the service needs (no SDK carries a key of its own), keeps your IP as the caller for per-caller limits, and strips the upstream's own headers. A path not on the list is answered 404. Your API key goes only to /v1.

What is not a call

  • Explorer links. The SDK writes links to Basescan, Etherscan, mempool.space, Solscan, Tronscan, Suiscan and other explorers into answers and the command line. It never fetches them.
  • A wallet's own sends. A browser wallet sends transactions through its own RPC. A key signer from the SDK (evmSignerFromPrivateKey, which the command line uses) sends through the RPC you pass in rpcUrls; with none for a chain, through that chain's default public RPC in viem (https://mainnet.base.org for Base, https://arb1.arbitrum.io/rpc, https://56.rpc.thirdweb.com, https://api.avax.network/ext/bc/C/rpc, https://rpc.mainnet.chain.robinhood.com). Maxy's read proxy relays no signed transactions.

Your own hosts

apiUrl, rpcUrls, lifiApiUrl, tronApiUrl, suiGraphqlUrl and jupiterApiUrl in createMaxyClient replace a default with your own. The defaults are all on openapi.maxy.co.

The old address

https://api.maxy.co/v1 is the HTTP API's old address. It answers as https://openapi.maxy.co/v1 does until 23 February 2027, and stops answering then. It was deprecated on 23 November 2026. Every answer from it says so in standard headers:

HeaderValueMeans
Deprecation (RFC 9745)@1795392000Deprecated since 23 November 2026, 00:00 UTC
Sunset (RFC 8594)Tue, 23 Feb 2027 00:00:00 GMTIt stops answering then
Link<https://openapi.maxy.co/v1>; rel="successor-version", and this page as rel="deprecation"Where to go instead, and this page

Move your base URL to https://openapi.maxy.co/v1 before the sunset: the paths, keys and answers are the same. Answers from openapi.maxy.co carry none of these headers.

How this is kept true

HOSTS.md in the package lists the same host. Before a release, every packed file, source maps included, is scanned for any host outside this page's list (Maxy's sites, the explorers, and the public RPCs a chain's own metadata names); one finding stops the release. Security checks shows how to check the package you installed.