Appearance
Textile FX API v2 · RFQ
You name a pair, an exact size, and the wallet that will settle. Textile asks the market makers online on that corridor to price that size, then returns one firm quote you can execute. By default that is every maker on the corridor; preferred or restricted wallets narrow who is asked. If nobody covers the full amount, you get a clear no-quote.
The public Swap page uses the same request. Any partner API key reaches it.
POST /v2/rfq/preview → indicative price while the user types. Free, unlocked.
POST /v2/rfq/request → keyless callers sign a short challenge proving they
control the taker; with an API key, just send the key.
We solicit makers and block for up to ~750ms
← a firm quote (signed orders + calldata), or no_quote
you sign + broadcast transactions.swap with your own wallet
POST /v2/rfq/{id}/submit → tell us the tx hash
GET /v2/rfq/{id} → status, and the settled amounts once it fills
POST /v2/rfq/{id}/cancel → give a quote back you decided not to takeIMPORTANT
An API key replaces the wallet signature. Send Authorization: Bearer <key> and you never sign TakerControl and never send takerProof. The challenge exists for callers with no credential, like the connect-only swap page. See Proof of control.
Non-custodial throughout. We never sign, never hold funds, never touch your keys.
What makes it different
- All-or-nothing. A quote covers your whole amount. There is no partial fill: if makers together can't do the full size, you get
no_quoterather than a smaller trade. When no single maker can cover you, Textile bundles several into one quote (oneexecuteBatch). - The price is held, briefly. A firm quote is a real signed order with a hard expiry, 60 seconds by default. Execute inside that window or ask for a new one. Nothing auto-refreshes.
- Exact-output is native. Ask for a
buyAmountand makers price the sell side. - The quote is bound to one wallet. Only the
takeryou name can fill it. Nobody can front-run or steal it, and you can't hand it to another wallet. - No credential required. A wallet is enough to quote and settle, including maker steering — no key, no login. The firm request does take one wallet signature (proof of control) proving you hold the
takeryou name, because it locks real maker inventory for that wallet — one signature covers about 12 hours of requests. An API key replaces that signature and adds webhooks and a rate-limit budget of your own.
Base URL
https://api.textilecredit.com/v2Timing
Per-corridor settings, not constants. Current defaults:
| Default | Meaning | |
|---|---|---|
| Reply budget | 750 ms default, up to 10 s | How long we wait for makers before answering you |
| Quote TTL | 60 s | Cap on how long a firm quote may live |
| Preferred wait | 250 ms | Head start for your preferred wallets before the rest are asked |
POST /v2/rfq/request normally answers inside the reply budget: 750 ms on most corridors, and up to 10 s on one quoted by a custodied signer, where a round trip to an MPC custodian is seconds rather than milliseconds.
The budget is not the whole deadline. Before the reply clock starts, the venue reads token decimals on chain, which is uncached on the first request for a corridor and budgeted 60 s. Add the reply budget and the admission grace and the worst case the server will hold a request is about 70 s.
That case is rare — the reads are cached after the first request — but it is reachable, so set your client timeout above it. 75 s is safe everywhere. A shorter timeout does not cancel anything: the venue still solicits, the makers still sign, and you discard a firm quote that was on its way.
Concurrency
You may hold 4 outstanding RFQs at a time. A firm quote occupies a slot for as long as it is executable. A solicitation is a free option on a maker's inventory, so the cap covers the option's whole life, not just the request. The slot frees when the swap fills or the signed order's deadline passes. Over the cap you get 429 rate_limited.
Conventions
- Amounts are strings in atomic units, base-10, no decimals.
"1000000"is 1 USDT. JSON numbers can't hold a uint256 losslessly. - Rates are RAY-scaled (1e27) strings.
- Addresses are standard EVM addresses. Lowercase is fine; we normalize.
- Timestamps are ISO-8601 UTC.
- Every response carries an
X-Request-Idheader. Quote it when you report a problem.
Machine-readable spec
openapi-v2.json describes every endpoint and schema. It's also served live at GET /v2/openapi.json, no credential needed.
Next
- Authentication: the claim token, proof-of-control signing, and what an API key adds.
- RFQ endpoints: preview, request, execute, submit, status — includes a full TypeScript walkthrough.
- Webhooks: terminal events.
- Errors & limits: codes, the outstanding-RFQ cap, rate limits.