Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
287f755
docs: add Solana gasless wallet module
ihsraham Jun 19, 2026
41ca5b4
docs: add Solana gasless source watch
ihsraham Jun 19, 2026
739b8c1
cleanup
ihsraham Jun 19, 2026
4c78dcb
Add Orchestra Swidge community module docs
ihsraham Jun 29, 2026
82bf0e1
docs: update July release documentation
ihsraham Jul 1, 2026
87175f7
feat: serve raw markdown docs pages
ihsraham Jul 1, 2026
61227e5
docs: update MCP SDK tools link
ihsraham Jul 1, 2026
b6b36d3
docs: refresh Solana gasless wallet docs
ihsraham Jul 7, 2026
ea64b0f
Merge develop into Solana gasless docs
ihsraham Jul 7, 2026
f460e32
Merge remote-tracking branch 'upstream/develop' into feat/add-orchest…
ihsraham Jul 7, 2026
677ea09
docs: scope Solana gasless docs to beta.1
ihsraham Jul 7, 2026
f840c23
Refine Orchestra and module docs
ihsraham Jul 7, 2026
140c859
Merge develop into release documentation update
ihsraham Jul 7, 2026
33710d4
Refine Orchestra docs navigation
ihsraham Jul 7, 2026
386e3e5
Merge remote-tracking branch 'upstream/develop' into feat/serve-page-…
ihsraham Jul 7, 2026
f8a1521
docs: update July release documentation
ihsraham Jul 7, 2026
424b5c7
Merge pull request #193 from ihsraham/feat/release-docs-2026-07-01
ihsraham Jul 7, 2026
4e332d1
Merge remote-tracking branch 'upstream/develop' into docs/solana-gasl…
ihsraham Jul 7, 2026
27df751
docs: add Solana gasless API reference
ihsraham Jul 7, 2026
b5b3283
docs: fix Solana gasless API reference accuracy
ihsraham Jul 7, 2026
a044152
Merge pull request #174 from ihsraham/docs/solana-gasless-wallet
ihsraham Jul 8, 2026
4cee101
Merge remote-tracking branch 'upstream/develop' into feat/serve-page-…
ihsraham Jul 8, 2026
8caa3d0
Address Orchestra review feedback
ihsraham Jul 8, 2026
b896eae
add rhinofi swidge release docs
ihsraham Jul 7, 2026
4ddf47d
Refine Swidge docs navigation
ihsraham Jul 7, 2026
a5f2d6d
Address Rhino.fi review feedback
ihsraham Jul 8, 2026
0165fee
Align Solana gasless wallet IA
ihsraham Jul 8, 2026
11b5a5f
Merge pull request #200 from ihsraham/feat/solana-gasless-sidebar-ia
ihsraham Jul 8, 2026
4fbff13
Merge remote-tracking branch 'upstream/develop' into feat/serve-page-…
ihsraham Jul 8, 2026
c1d8aec
Merge remote-tracking branch 'upstream/develop' into feat/rhinofi-swi…
ihsraham Jul 8, 2026
0c3e5fd
Merge pull request #198 from ihsraham/feat/rhinofi-swidge-release-docs
ihsraham Jul 8, 2026
84477da
Merge pull request #194 from ihsraham/feat/serve-page-markdown
ihsraham Jul 8, 2026
082d797
Merge remote-tracking branch 'upstream/develop' into feat/add-orchest…
ihsraham Jul 8, 2026
8b7ad75
Merge pull request #188 from ihsraham/feat/add-orchestra-swidge-docs
ihsraham Jul 8, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions _redirects
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
/sdk/wallet-btc/* /sdk/wallet-modules/wallet-btc/:splat 301
/sdk/wallet-solana /sdk/wallet-modules/wallet-solana 301
/sdk/wallet-solana/* /sdk/wallet-modules/wallet-solana/:splat 301
/sdk/wallet-solana-gasless /sdk/wallet-modules/wallet-solana-gasless 301
/sdk/wallet-solana-gasless/* /sdk/wallet-modules/wallet-solana-gasless/:splat 301
/sdk/wallet-ton /sdk/wallet-modules/wallet-ton 301
/sdk/wallet-ton/* /sdk/wallet-modules/wallet-ton/:splat 301
/sdk/wallet-ton-gasless /sdk/wallet-modules/wallet-ton-gasless 301
Expand Down
2 changes: 1 addition & 1 deletion content/docs/ai/agent-skills.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Once an agent loads the WDK skill, it can:
| --- | --- |
| **Wallets** | Create and recover wallets across EVM chains, Bitcoin, Solana, Spark, TON, and Tron |
| **Transactions** | Send native tokens and token transfers (ERC-20, SPL, Jetton, TRC-20) |
| **Swaps** | DEX swaps via Velora (EVM) and StonFi (TON) |
| **Swaps and routes** | DEX swaps via Velora and Swidge routes through providers such as Orchestra |
| **Bridges** | Cross-chain bridges with USDT0 via LayerZero |
| **Lending** | Supply, borrow, repay, and withdraw via Aave V3 |
| **Fiat** | Buy and sell crypto via MoonPay on/off-ramps |
Expand Down
2 changes: 1 addition & 1 deletion content/docs/ai/openclaw.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Once the skill is loaded, your agent can:

- **Create wallets** across 20+ blockchains (EVM, Bitcoin, Solana, TON, Tron, Spark)
- **Send transactions** and token transfers
- **Swap tokens** via DEX aggregators (Velora, StonFi)
- **Swap and route tokens** via Velora and Swidge providers such as Orchestra
- **Bridge assets** cross-chain with USDT0
- **Lend and borrow** through Aave V3
- **Buy and sell crypto** via MoonPay fiat on/off-ramps
Expand Down
2 changes: 1 addition & 1 deletion content/docs/overview/about.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ WDK natively supports a broad set of blockchains and standards out of the box:
| Protocol/Module | Support |
| -------------------------------------------------------------- | ------- |
| [velora (EVM)](/sdk/swap-modules/swap-velora-evm/) | ✅ |
| StonFi (TON) | In progress |
| [Orchestra Swidge](/sdk/swidge-modules/swidge-orchestra/) | Community |
| [USD₮0 Bridge (EVM)](/sdk/bridge-modules/bridge-usdt0-evm/) | ✅ |
| [Aave Lending (EVM)](/sdk/lending-modules/lending-aave-evm/) | ✅ |
</Tab>
Expand Down
49 changes: 49 additions & 0 deletions content/docs/overview/changelog.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,55 @@ Stay up to date with the latest improvements, new features, and bug fixes across

---

### July 07, 2026

**What's New**
- **swidge-rhinofi** ([v1.0.0-beta.2](https://www.npmjs.com/package/@rhino.fi/wdk-protocol-swidge-rhinofi/v/1.0.0-beta.2)): Introduce the Rhino.fi swidge provider for authenticated cross-chain quotes, EVM source-chain execution, live chain and token discovery, status polling, fee-cap checks, and typed Rhino.fi error handling.

**Changes**
- **pricing-bitfinex-http** ([v1.0.0-beta.4](https://github.com/tetherto/wdk-pricing-bitfinex-http/releases/tag/v1.0.0-beta.4)): Remove the USD-pivot fallback from Bitfinex price lookups. Current-price and price-data methods now return `null` for pairs Bitfinex cannot quote directly, while historical lookups return an empty series when Bitfinex has no matching history.

---

### July 04, 2026

**Changes**
- **wdk-utils** ([v1.0.0-beta.8](https://github.com/tetherto/wdk-utils/releases/tag/v1.0.0-beta.8)): Refresh Noble crypto dependencies and import paths used by address validation, Lightning invoice helpers, BIP-21 parsing, and seed-encryption internals. No new public helper API is introduced in this release.

---

### July 03, 2026

**What's New**
- **wallet-evm** ([v1.0.0-beta.15](https://github.com/tetherto/wdk-wallet-evm/releases/tag/v1.0.0-beta.15)): Add signer-backed EVM accounts with the new `@tetherto/wdk-wallet-evm/signers` entrypoint, `SeedSignerEvm`, `PrivateKeySignerEvm`, signer-based account retrieval, standalone private-key accounts via `WalletAccountEvm.fromPrivateKey()`, contract-creation transactions with omitted or `null` `to`, and ERC-7702 authorization/delegation helpers. The release also updates `ethers` to `6.17.0` and aligns with `@tetherto/wdk-wallet` v1.0.0-beta.13.
- **wallet-tron** ([v1.0.0-beta.8](https://github.com/tetherto/wdk-wallet-tron/releases/tag/v1.0.0-beta.8)): Add arbitrary transaction support. `quoteSendTransaction()`, `signTransaction()`, and `sendTransaction()` now accept native TRX transfers, smart-contract call descriptors, or pre-built TronWeb transactions. Fee quotes cover bandwidth, smart-contract energy, and activation fees where applicable.

**Fixes**
- **wdk-wallet** ([v1.0.0-beta.13](https://github.com/tetherto/wdk-wallet/releases/tag/v1.0.0-beta.13)): Default `IWalletAccount<TSignedTransaction>` to `unknown`, restoring bare `IWalletAccount` TypeScript compatibility for downstream packages without runtime behavior changes.
- **wallet-evm-erc-4337** ([v1.0.0-beta.11](https://github.com/tetherto/wdk-wallet-evm-erc-4337/releases/tag/v1.0.0-beta.11)): Fix UserOperation signing compatibility with the `@tetherto/wdk-wallet-evm` v1.0.0-beta.15 signer model and align dependencies with `@tetherto/wdk-wallet` v1.0.0-beta.13 and `ethers` 6.17.0.

**Changes**
- **worklet-bundler** ([v1.0.0-beta.4](https://github.com/tetherto/wdk-worklet-bundler/releases/tag/v1.0.0-beta.4)): Publish source changes for JSON-RPC transport, native addon linking, ESM-to-CJS conversion, generic `modules` config support, lazy wallet-module loading, and the generated `./.wdk` import path. The npm artifact for this tag is missing built CLI/API files, so the Worklet Bundler usage pages remain on the prior documented workflow until a fixed package is available.
- **wdk-core** ([v1.0.0-beta.13](https://github.com/tetherto/wdk/releases/tag/v1.0.0-beta.13)): Align the core package with `@tetherto/wdk-wallet` v1.0.0-beta.13. No new core runtime API changes were found in this tag diff.
- **bridge-usdt0-evm** ([v1.0.0-beta.6](https://github.com/tetherto/wdk-protocol-bridge-usdt0-evm/releases/tag/v1.0.0-beta.6)): Align dependencies with the latest base wallet, EVM wallet, and ERC-4337 wallet releases. No production bridge API changes were found in this tag diff.

---

### July 01, 2026

**What's New**
- **wallet-evm-erc-4337** ([v1.0.0-beta.10](https://github.com/tetherto/wdk-wallet-evm-erc-4337/releases/tag/v1.0.0-beta.10)): Add `transactionMaxFee` for non-sponsored `sendTransaction()` and `signTransaction()` UserOperation flows, separate from `transferMaxFee` for token transfers. The module also reserves local nonces for rapid or concurrent sends from the same account instance and releases them when a submission fails before bundler acceptance.
- **react-native-core** ([v1.0.0-beta.12](https://github.com/tetherto/wdk-react-native-core/releases/tag/v1.0.0-beta.12)): Add `useProtocol()` for calling bridge, swap, lending, and fiat protocol methods from React Native through the active WDK worklet account.

---

### June 30, 2026

**Changes**
- **swap-velora-evm** ([v1.0.0-beta.6](https://github.com/tetherto/wdk-protocol-swap-velora-evm/releases/tag/v1.0.0-beta.6)): Document the optional ERC-4337 per-call config argument for `swap()` and `quoteSwap()`, plus the `swap()` per-call `swapMaxFee` override. The package also refreshes dependency and repository metadata.

---

### June 29, 2026

**What's New**
Expand Down
10 changes: 9 additions & 1 deletion content/docs/sdk/all-modules.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,17 @@ Wallet modules provide blockchain-specific wallet functionality for managing add
| [`@tetherto/wdk-wallet-tron`](https://github.com/tetherto/wdk-wallet-tron) | TRON | TRON blockchain wallet | [Docs](/sdk/wallet-modules/wallet-tron/) |
| [`@tetherto/wdk-wallet-tron-gasfree`](https://github.com/tetherto/wdk-wallet-tron-gasfree) | TRON | Gas-free transactions on TRON | [Docs](/sdk/wallet-modules/wallet-tron-gasfree/) |
| [`@tetherto/wdk-wallet-solana`](https://github.com/tetherto/wdk-wallet-solana) | Solana | Solana blockchain wallet | [Docs](/sdk/wallet-modules/wallet-solana/) |
| [`@tetherto/wdk-wallet-solana-gasless`](https://github.com/tetherto/wdk-wallet-solana-gasless) | Solana | Gasless Solana transactions through a Kora-compatible paymaster | [Docs](/sdk/wallet-modules/wallet-solana-gasless/) |
| [`@tetherto/wdk-wallet-spark`](https://github.com/tetherto/wdk-wallet-spark) | Spark | Spark/Lightning Bitcoin L2 wallet | [Docs](/sdk/wallet-modules/wallet-spark/) |

## Swidge Interface

Swidge is the preferred interface for new protocol providers that can quote and execute asset routes. A route can be swap-only, bridge-only, or a combined swap and bridge route.

No released swidge provider module is listed yet. See the [swidge protocol interface](/sdk/swidge-modules/) for the shared API shape that new provider modules should implement.
| Module | Provider | Description | Documentation |
|--------|----------|-------------|---------------|
| [`wdk-protocol-swidge-orchestra`](https://www.npmjs.com/package/wdk-protocol-swidge-orchestra) | Flashnet Orchestra | Swidge provider for BTC and stablecoin routes returned by Orchestra. Treat the live [Orchestra route matrix](https://orchestration.flashnet.xyz/v1/orchestration/routes) as provider-level data and filter through package discovery before exposing routes. | [Docs](/sdk/swidge-modules/swidge-orchestra/) |
| [`@rhino.fi/wdk-protocol-swidge-rhinofi`](https://www.npmjs.com/package/@rhino.fi/wdk-protocol-swidge-rhinofi) | Rhino.fi | Swidge routes for Rhino.fi cross-chain swap and bridge operations | [Docs](/sdk/swidge-modules/swidge-rhinofi/) |

## Pricing Modules

Expand Down Expand Up @@ -87,4 +91,8 @@ Modules built by the WDK community. See the [Community Modules](/sdk/community-m
| Module | Blockchain | Description | Documentation |
|--------|------------|-------------|---------------|
| [`@utexo/wdk-wallet-rgb`](https://github.com/UTEXO-Protocol/wdk-wallet-rgb) | Bitcoin (RGB) | RGB protocol wallet integration | [Docs](/sdk/community-modules/wdk-wallet-rgb/) |
| [`@arkade-os/wdk`](https://github.com/arkade-os/arkade-wdk) | Arkade | Bitcoin wallet module built on the Arkade SDK | [README](https://github.com/arkade-os/arkade-wdk#readme) |
| [`@base58-io/wdk-wallet-cosmos`](https://github.com/base58-io/wdk-wallet-cosmos) | Cosmos | Cosmos-compatible wallet integration | [Docs](/sdk/community-modules/wdk-wallet-cosmos/) |
| [`@morpho-org/wdk-protocol-lending-morpho-evm`](https://www.npmjs.com/package/@morpho-org/wdk-protocol-lending-morpho-evm) | EVM | Morpho Vault V2 and Morpho Blue lending integration | [Docs](/sdk/lending-modules/lending-morpho-evm/) |
| [`wdk-protocol-swidge-orchestra`](https://github.com/flashnetxyz/wdk-protocol-swidge-orchestra) | Swidge | Flashnet Orchestra BTC and stablecoin route integration | [Docs](/sdk/swidge-modules/swidge-orchestra/) |
| [`@rhino.fi/wdk-protocol-swidge-rhinofi`](https://www.npmjs.com/package/@rhino.fi/wdk-protocol-swidge-rhinofi) | Rhino.fi | Swidge cross-chain route integration | [Docs](/sdk/swidge-modules/swidge-rhinofi/) |
6 changes: 4 additions & 2 deletions content/docs/sdk/bridge-modules/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ You can also:
- Learn about key concepts like [Account Abstraction](/resources/concepts#account-abstraction) and other important definitions
- Use one of our ready-to-use examples to be production ready

## Combined swap and bridge routes
## Swidge provider routes

When a route needs both cross-chain movement and a token swap, use the [Swidge protocol interface](/sdk/swidge-modules) instead of wiring separate bridge and swap flows manually. The shared interface covers route discovery, quoting, execution, and status tracking for combined asset routes.
For new swap or bridge provider integrations, prefer the [Swidge protocol interface](/sdk/swidge-modules). Swidge can represent bridge-only routes, swap-only routes, and combined bridge-and-swap routes. Existing standalone bridge module references remain available for released modules that have not moved to Swidge.

For a released community provider, see [Orchestra](/sdk/swidge-modules/swidge-orchestra), which implements Swidge for BTC and stablecoin routes returned by Flashnet Orchestra.
4 changes: 3 additions & 1 deletion content/docs/sdk/community-modules/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ Tether and the WDK Team do not endorse or assume responsibility for their code,
| [@arkade-os/wdk](https://www.npmjs.com/package/@arkade-os/wdk) ([GitHub](https://github.com/arkade-os/arkade-wdk)) | Wallet Module | Bitcoin wallet module built on the Arkade SDK with Arkade addresses, boarding addresses, BIP21/LNURL/Lightning send routing, and optional Boltz swaps | [README](https://github.com/arkade-os/arkade-wdk#readme) | [Arkade](https://github.com/arkade-os) |
| [@base58-io/wdk-wallet-cosmos](https://www.npmjs.com/package/@base58-io/wdk-wallet-cosmos) ([GitHub](https://github.com/base58-io/wdk-wallet-cosmos)) | Wallet Module | Wallet module for Cosmos-compatible blockchains | [Docs](/sdk/community-modules/wdk-wallet-cosmos/) | [Base58](https://base58.io/) |
| [@morpho-org/wdk-protocol-lending-morpho-evm](https://www.npmjs.com/package/@morpho-org/wdk-protocol-lending-morpho-evm) ([GitHub](https://github.com/morpho-org/sdks/tree/main/packages/wdk-protocol-lending-morpho-evm)) | Lending Module | Morpho EVM lending module for vault deposits, collateral supply, borrowing, repayment, and position reads | [Docs](/sdk/lending-modules/lending-morpho-evm/) | [Morpho Association](https://morpho.org/) |
| [wdk-protocol-swidge-orchestra](https://www.npmjs.com/package/wdk-protocol-swidge-orchestra) ([GitHub](https://github.com/flashnetxyz/wdk-protocol-swidge-orchestra)) | Swidge Module | Flashnet Orchestra Swidge provider for BTC and stablecoin routes returned by Orchestra | [Docs](/sdk/swidge-modules/swidge-orchestra/) | [Flashnet](https://github.com/flashnetxyz) |
| [@rhino.fi/wdk-protocol-swidge-rhinofi](https://www.npmjs.com/package/@rhino.fi/wdk-protocol-swidge-rhinofi) ([GitHub](https://github.com/rhinofi/wdk-protocol-swidge-rhinofi)) | Swidge Module | Rhino.fi cross-chain swap and bridge routes through the WDK swidge interface | [Docs](/sdk/swidge-modules/swidge-rhinofi/) | [Rhino.fi](https://rhino.fi/) |

---

Expand All @@ -32,7 +34,7 @@ Want to extend WDK with your own custom module? Use the `create-wdk-module` CLI
npx @tetherto/create-wdk-module@latest
```

The CLI generates source files, tests, TypeScript type definitions, and CI workflows for all five module types (wallet, swap, bridge, lending, fiat). See the [Create WDK Module documentation](/tools/create-wdk-module) for the full guide, CLI options, and generated project structure.
The CLI generates source files, tests, TypeScript type definitions, and CI workflows for all six module types (wallet, swap, bridge, lending, fiat, swidge). See the [Create WDK Module documentation](/tools/create-wdk-module) for the full guide, CLI options, and generated project structure.

You can also:

Expand Down
7 changes: 4 additions & 3 deletions content/docs/sdk/swap-modules/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ DeFi swap functionality for token exchanges across different DEXs:
| Module | Blockchain | Status | Documentation |
|--------|------------|--------|---------------|
| [`@tetherto/wdk-protocol-swap-velora-evm`](https://github.com/tetherto/wdk-protocol-swap-velora-evm) | EVM | ✅ Ready | [Documentation](/sdk/swap-modules/swap-velora-evm/) |
| `@tetherto/wdk-protocol-swap-stonfi-ton` | TON | In progress | Coming soon |

## Next steps

Expand All @@ -29,6 +28,8 @@ You can also:
- Learn about key concepts like [Account Abstraction](/resources/concepts#account-abstraction) and other important definitions
- Use one of our ready-to-use examples to be production ready

## Combined swap and bridge routes
## Swidge provider routes

When a route needs both a token swap and cross-chain movement, use the [Swidge protocol interface](/sdk/swidge-modules) instead of wiring separate swap and bridge flows manually. The shared interface covers route discovery, quoting, execution, and status tracking for combined asset routes.
For new swap or bridge provider integrations, prefer the [Swidge protocol interface](/sdk/swidge-modules). Swidge can represent swap-only routes, bridge-only routes, and combined swap-and-bridge routes. Existing standalone swap module references remain available for released modules that have not moved to Swidge.

For a released community provider, see [Orchestra](/sdk/swidge-modules/swidge-orchestra), which implements Swidge for BTC and stablecoin routes returned by Flashnet Orchestra.
20 changes: 13 additions & 7 deletions content/docs/sdk/swap-modules/swap-velora-evm/api-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const swap = new VeloraProtocolEvm(account, { swapMaxFee: 200000000000000n })

| Method | Description | Returns |
|--------|-------------|---------|
| `swap(options, config?)` | Perform a token swap | `Promise<{hash: string, fee: bigint, tokenInAmount: bigint, tokenOutAmount: bigint, approveHash?: string, resetAllowanceHash?: string}>` |
| `swap(options, config?)` | Perform a token swap | `Promise<{hash: string, fee: bigint, tokenInAmount: bigint, tokenOutAmount: bigint}>` |
| `quoteSwap(options, config?)` | Get estimated fee and amounts | `Promise<{fee: bigint, tokenInAmount: bigint, tokenOutAmount: bigint}>` |

---
Expand All @@ -47,15 +47,18 @@ Options:
- `to` (`string`, optional): Recipient address (defaults to account address)

Config (ERC‑4337 only):
- `paymasterToken` (`string`, optional): Token symbol/address for fee sponsorship
- `paymasterToken` (`{ address: string }`, optional): Paymaster token override for this swap
- `isSponsored` (`true`, optional): Use sponsorship mode for this swap
- `sponsorshipPolicyId` (`string`, optional): Sponsorship policy override
- `useNativeCoins` (`true`, optional): Pay fees in the chain's native token
- `swapMaxFee` (`bigint`, optional): Per‑swap fee cap (wei)

Returns:
- Standard account: `{ hash, fee, tokenInAmount, tokenOutAmount, approveHash?, resetAllowanceHash? }`
- ERC‑4337 account: `{ hash, fee, tokenInAmount, tokenOutAmount }` (approve may be bundled)
- Standard account: `{ hash, fee, tokenInAmount, tokenOutAmount }`
- ERC‑4337 account: `{ hash, fee, tokenInAmount, tokenOutAmount }`

Notes:
- On Ethereum mainnet, selling USD₮ may first set allowance to 0, then approve.
- Approve the input token with the wallet account before swapping if the spender does not already have enough allowance.
- Requires a provider; requires a non read‑only account to send transactions.

Example:
Expand All @@ -78,7 +81,10 @@ Options are the same as `swap`.
Returns: `{ fee, tokenInAmount, tokenOutAmount }`

Config (ERC‑4337 only):
- `paymasterToken` (`string`, optional): Token symbol/address for fee sponsorship
- `paymasterToken` (`{ address: string }`, optional): Paymaster token override for fee estimation
- `isSponsored` (`true`, optional): Use sponsorship mode for fee estimation
- `sponsorshipPolicyId` (`string`, optional): Sponsorship policy override
- `useNativeCoins` (`true`, optional): Estimate fees in the chain's native token

Works with read‑only accounts.

Expand Down Expand Up @@ -108,7 +114,7 @@ Common errors include:

- `swapMaxFee: bigint` — Upper bound for gas fees (wei)
- `tokenInAmount/tokenOutAmount: bigint` — ERC‑20 base units
- `paymasterToken: string` — token symbol or address (AA only)
- `paymasterToken: { address: string }` — ERC‑4337 paymaster token override

<Cards>
<Card title="Node.js Quickstart" href="/start-building/nodejs-bare-quickstart">
Expand Down
Loading
Loading