Hypermid never custodies the funds. The quote returns a transaction for the
user’s own wallet to sign and submit. We price and route; we do not hold an
intermediary balance — which is also why there is no session to create and
nothing to reconcile afterwards.
The shape of it
1
Quote
POST /quote with the pair and an amount. You get back an executable
transactionRequest and the numbers to show the user.2
Submit
Your frontend hands
transactionRequest to the connected wallet, approving
the token first if the route needs an allowance.3
Track
Poll
GET /v1/status with the transaction hash until it reaches a terminal
state.Quote
dstChain, or set it equal to srcChain, for a same-chain swap.
A publishable key is enough — quoting moves no money, so this call is safe
from a browser. Only payment-session creation needs the secret key.
Submit it
transactionRequest as returned. Rebuilding the calldata yourself
detaches it from the quote that priced it, and the two are bound: the route
encodes a minimum-output amount the contract enforces, so a hand-built
transaction is the fastest route to a revert.
Approvals
ERC-20 routes need an allowance before the router can pull funds. The quote tells you the spender:value instead and need no approval.
Track it
receiving stays absent until the destination
side lands — that is normal progress, not a stall. Use
estimate.executionDuration to set your user’s expectations.
There are two status endpoints and they are not interchangeable:
Deposit-based routes
Some routes settle by deposit address rather than a contract call — the user sends funds to an address instead of signing a router transaction. This is how intent routes and most non-EVM destinations work. The quote signals it withisIntent and a populated deposit:
execute is a discriminated union, so the compiler forces the
branch rather than trusting you to remember:
deposit (or execute.kind) first. On a deposit route the
transactionRequest is an inert placeholder — submitting it does nothing
useful.
Refunds on intent routes
Intent routes ask forrefundRecipient at quote time, before the user commits
anything. An intent is a solver’s promise to deliver, and a promise that fails
has to unwind somewhere — collect the address up front, while the user is still
present, rather than at failure time when they may be long gone.
Aggregator routes need no such field: funds never leave the user’s custody
until the swap executes.
Fees
Your integrator fee comes out of the route and is itemised inestimate.feeCosts. Read GET /v1/fee-config with your key
to display your own negotiated rate rather than hard-coding a number that can
change without an API version bump.
This direct Swap contract is distinct from Payments. Checkout, Deposit, and
Withdrawal use a Hypermid fee plus an optional developer fee on one base amount;
the developer fee defaults to 0 and is limited to 0–100 basis points. A partner
Hypermid override replaces the global rate outright. Read
GET /v1/payments/fee-config for that contract.
Payments’ same-token EVM transfer is its zero fee exception. On EVM Payments
routes, developer earnings are held by Hypermid and settled periodically by
manual transfer. On the Near deposit-address rail, the provider keeps half of
each declared app fee and pays the developer leg directly. These Payments rules
do not change direct Swap’s caller-selected fee.