config prop of type WidgetConfig. Every field is optional; omit a field to fall back to its default.
Configuration options
| Field | Type | Default | Purpose |
|---|---|---|---|
theme | "light" | "dark" | system preference | Color theme. See Customize. |
enableDelta | boolean | true | Enable Delta intents (gasless, MEV-protected). |
enableCrossChain | boolean | true | Enable crosschain swaps. |
srcChains | SupportedChainId[] | all supported | Restrict source-chain picker. |
destChains | SupportedChainId[] | all supported | Restrict destination-chain picker. |
tradeModes | TradeMode[] | all four modes | Limit which forms appear ("swap" | "limit" | "otc" | "twap"). |
tokenLists | string[] | curated defaults | Token-list URLs to populate token pickers. |
excludeUI | WidgetElements[] | [] | Hide UI chunks ("wallet-management" | "activities" | "snackbars"). |
enableDegenMode | boolean | true | Allow users to bypass high-price-impact warnings. |
widgetMode | "standalone" | "dapp" | "standalone" | Who owns the wallet connection. See Wallet management. |
debug | boolean | false | Verbose console logging. |
partnerConfig | PartnerConfig | — | Partner fee/revenue config. See Monetize. |
referrerConfig | ReferrerConfig | — | Referrer revenue config. See Monetize. |
privyAppId | string | — | Optional. Adds Privy to the connector list in standalone mode. See Wallet management. |
privyClientId | string | — | Optional. Only effective when privyAppId is set. |
Chains and routes
srcChains, destChains
Restrict the chain dropdowns to a subset. Useful when your integration only services specific networks.
How chain selection behaves:
- An empty array or one containing only invalid chain IDs falls back to all default chains.
- Invalid IDs in an otherwise valid list are dropped (with
console.warn). - Not all source chains can bridge to all destination chains; unsupported pairs are filtered out at runtime.
- Same-chain swaps (source == destination) are always allowed for any chain in
srcChains.
enableCrossChain
enableDelta
false, hides Delta-mode swaps and Delta-only trade modes (limit, TWAP). The widget falls back to Market-API swaps only.
Trade modes
tradeModes
"swap" | "limit" | "otc" | "twap".
Similar fallback rules apply here:
- An empty array or one with only invalid modes falls back to all default modes.
- If the currently selected mode becomes disabled, the widget switches to the first enabled mode.
limitandtwapare Delta-only. IfenableDelta: false(or the user disables Delta in Settings) and yourtradeModeslist contains only Delta-only modes, the widget falls back toswap.
Theme
theme
Hiding UI
excludeUI
Hide specific UI chunks when your host app provides its own equivalents.
| Key | Hides |
|---|---|
"wallet-management" | The wallet button in the header |
"activities" | The activity / transaction history panel |
"snackbars" | In-widget toast notifications |
Token lists
tokenLists
Add custom token-list URLs. The widget merges them with curated defaults if you spread them.
Behavior flags
enableDegenMode
true (default), users can toggle Degen Mode in Trading Parameters to trade tokens with high price impact or missing USD price data. When false, the toggle is hidden and users can’t bypass price-impact warnings.
debug
Pre-filling the form
Use theinput prop (not config) to pre-select tokens, amounts, and form type, for example to support deep links into a specific trade.
Related pages
- Customize — theme details and CSS scoping.
- Wallet management —
widgetMode,provider, optionalprivyAppId. - Monetize —
partnerConfigandreferrerConfig. - Widget API reference — full type definitions.