Bungeeexchange

Bungeeexchange swap integrations match transaction handling to the funding source

Bungeeexchange swap integrations distinguish a connected-wallet transaction from a transfer to a deposit address. Its legacy API has a migration path to Socket Swap V3, where userOps identifies transaction, deposit, or centralized-exchange withdrawal funding. Choose the flow by how the origin transfer will occur, then apply the selected route’s requirements. Deposit quotes require a refund address, and some return previews requiring activation before funding. Available routes depend on the particular integration and its supported funding methods.

Updated on
A Socket Swap V3 deposit preview retains its quote identifier through activation, which supplies the transfer instructions needed for funding.

Wallet transactions and deposit transfers differ at the origin

A direct tx route fits an integration able to sign and submit the origin transaction from a connected wallet. A deposit route supplies a destination for the origin transfer. Its funding can come from a wallet, an exchange, or a supported non-EVM chain. A wallet can therefore participate in either category, because these categories describe origin execution separately from where the user holds funds. The dedicated cex-withdraw category identifies centralized-exchange withdrawal funding and requires an exchange parameter.

The sender, recipient, and refund address have separate jobs

Treating them as interchangeable can change who submits the transaction, who receives the output, or where a refund goes.

The transaction sender

For tx routes, the required userAddress identifies the wallet submitting the returned transaction. A route with an approval object needs enough ERC-20 allowance for approval.spenderAddress to cover approval.amount before submission. The integration checks the existing allowance first, because an approval object does not establish whether another approval is necessary. Native-token inputs return no approval object. The integration also discards quotes past expiresAt before submission.

The output recipient

receiverAddress identifies the intended output recipient. A receiving wallet may differ from the sending wallet in supported flows. The receiver does not become the origin transaction sender merely because the quote names it.

The refund destination

Every Socket Swap V3 quote using userOps=deposit requires a refundAddress . It names the return destination, while receiverAddress names the swap recipient. Supplying a refund address does not establish that a refund has occurred; Incognito transaction quotes also require one under separate eligibility rules.


Deposit previews need activation before funding

A deposit quote can describe a route before it supplies usable transfer instructions. The activationRequired flag identifies whether the route already has those instructions or needs an activation request.

Routes already ready for a transfer

When activationRequired is false , the response already includes txData and depositData . The integration skips activation and uses the returned transfer details. This preparation state does not establish origin payment or destination delivery, which require their own execution evidence.

Routes awaiting activation

A true flag means the route remains a preview without txData or depositData ; activation returns those fields while retaining quoteId . The integration obtains that response before presenting the funding address, token, amount, and any memo.

Deposit routes support manual and programmatic funding

A deposit route supports a manually initiated transfer or programmatic origin submission when its returned execution data supports that method. The manual presentation uses depositData , including the address, token, amount, and optional memo. The programmatic method uses txData . The sender must use the specified origin network and input asset alongside all returned transfer details. An optional memo belongs to that particular instruction set when present, so moving only an address between interfaces can discard relevant payment information.

Manual deposit funding remains distinct from the legacy API’s manualRoute response category. Swap V3 uses depositData for transfer instructions, whereas manualRoute named a legacy response object.


Exchange withdrawal funding needs an exchange identifier

The dedicated withdrawal mode adds information about the centralized exchange supplying the funds. A quote using cex-withdraw requires exchange , so the funding location becomes part of the request. The generic deposit mode can also accept an exchange-origin transfer. These alternatives describe different integration arrangements around the same broad funding source. An exchange-held balance therefore does not select the dedicated withdrawal mode automatically. Support still depends on the particular exchange integration and returned route. The available route must support the specified exchange, asset, and withdrawal network.

Input control and output targeting are separate quote choices

A fixed-input quote defines the quantity of the selected token entering the swap and returns a quoted output. Socket Swap V3 defaults to EXACT_INPUT with inputAmount . This suits a task centered on a known source quantity. It does not fix the destination quantity independently. Deposit instructions and the selected route still govern the origin transfer. Funding category and amount objective describe different parts of the request, so choosing one does not settle the other.

Output-targeted quotes reverse that relationship. EXPECTED_OUTPUT targets outputAmount with an estimated input, while EXACT_OUTPUT solves the input for a guaranteed output amount. Both omit inputAmount . Both output modes require eligible direct tx providers and exclude Incognito; deposit funding does not provide access to those quoting modes.


Incognito restricts the funding path to direct transactions

Swap V3 Incognito supports eligible direct tx routes on EVM networks and Solana, with a required refund address. It rejects deposit and cex-withdraw requests and excludes output-targeted quoting. Its provider filter selects houdini and changenow for privacy-capable routing. The feature separates sending and receiving wallets in the user-facing transaction path. Same-chain, same-token transfers remain possible within this mode. Those constraints affect the funding choice before route speed or quoted output enters the comparison.


A fixed source quantity can use wallet or deposit funding

A fixed source quantity can fund a direct wallet transaction or a deposit transfer when the integration supports the corresponding route. The choice changes how the origin payment enters the swap while preserving a fixed-input objective.

  • Choose tx when the integration can sign and submit the returned origin transaction from userAddress .
  • Choose deposit for funding through the route’s deposit instructions, and supply refundAddress .
  • Select cex-withdraw for a supported exchange-withdrawal integration, with the required exchange parameter.
  • Use EXACT_INPUT to fix the starting quantity; output-targeted modes determine the required input differently.
  • For a deposit preview, obtain activation and transfer instructions before funding the route.

The transaction route supplies origin execution data, while the deposit route supplies transfer instructions after any required activation. Adding Incognito leaves only the eligible tx path, so that feature changes which funding arrangement fits the task.

Origin confirmation and destination delivery are different states

Confirmation of the origin transfer establishes progress on the sending side. In the Swap V3 status model, EXTRACTED means source extraction has confirmed while destination fulfillment remains unfinished. It maps to the high-level IN_PROGRESS state. The status identifier quoteId connects that progress to the selected quote, without establishing destination completion from origin confirmation alone.

COMPLETED identifies delivered funds. FAILED , EXPIRED , and REFUNDED describe other terminal outcomes in the standard flow. A failed route and a processed refund describe different outcomes.

Deposit funding may also produce REFUNDING , REFUND_FAILED , or MANUAL_REVIEW_REQUIRED . These states distinguish refund progress, refund failure, and required review, even after the sender has made a payment. The relevant completion evidence comes from the destination or refund state.

Flow compatibility limits the comparison

Funding mode identifies an origin operation; it does not guarantee every chain, token, or feature combination. Matching origin and destination chain IDs describes a same-chain swap. Different IDs describe a cross-chain swap. Either distinction remains separate from who submits the origin payment. Route comparison then concerns the actual compatible options, rather than a universal ranking of wallet and deposit funding.

Visual summary: Bungeeexchange: Match swap flow to the funding source

Bungeeexchange: Match swap flow to the funding source

  • Incognito restricts the funding path to direct transactions
  • A fixed source quantity can use wallet or deposit funding
  • Origin confirmation and destination delivery are different states
  • Flow compatibility limits the comparison

View image file

Execution format supplies another distinction within a funding category. The txData.kind field identifies the format returned for a transaction-mode route. On Ethereum Virtual Machine (EVM) networks, evm_tx carries the transaction target, calldata, and native value. Solana routes can return instructions or a serialized versioned transaction. Bitcoin-origin btc_deposit data describes a native payment to a deposit address, even within the transaction-mode integration. A funding label therefore cannot replace the returned chain-specific execution instructions.

Legacy Bungee API v1 integrations must also account for the migration’s response changes. Swap V3 returns a flat routes array in place of autoRoute , depositRoute , and manualRoute objects. For direct transaction routes, the returned execution data replaces the legacy Auto Mode signature-and-submit arrangement. The request’s userOps value supplies the funding classification, while quoteId identifies the selected route.

Answers to common questions

What identifies a Bitcoin-origin payment in a Swap V3 response?

The btc_deposit transaction kind identifies native Bitcoin funding. Its object supplies a depositAddress and an amount in satoshis, plus orderHash when applicable. The origin payment is a native BTC transaction, even when the API returns it within a transaction-mode route. Include orderHash as an OP_RETURN output when present. Bitcoin-origin routes also require a BTC refundAddress; an EVM-style contract submission does not apply to this payment.

When should a contract-based sender set contractCaller?

Set contractCaller when a userOps=tx integration submits through an intermediate contract. AllowanceHolder normally requires the signing wallet to be its caller. The parameter authorizes the specified intermediate contract; omitting it can produce CallerNotSignedUser. It does not replace the signing wallet’s authorization or change the recipient. This requirement concerns contract-mediated transaction submission, not ordinary deposit-address funding.

Does a deposit-address route support destination contract execution?

Swap V3 destination payload execution excludes deposit-address routes. It applies to supported userOps=tx routes and also excludes Sui destinations. An eligible request needs destinationPayload and destinationGasLimit together, with receiverAddress identifying an IBungeeExecutor contract. The route attempts the destination call after token delivery; isDestPayloadExecuted reports whether it succeeded. Funding through a deposit address cannot access that feature simply by naming a contract as the output recipient.

How frequently should an integration poll a deposit transfer?

The recommended polling interval for a Socket Swap V3 deposit transfer is 5-10 seconds. Use quoteId to identify the route whose status needs checking. The interval controls status checks and does not set a settlement deadline. PENDING and IN_PROGRESS remain unfinished states, while refund-related and manual-review states require their own handling.

Where should production credentials live in a custom funding integration?

Production backend API keys belong on the server. A dedicated Socket Swap V3 integration sends x-api-key and affiliate headers, while keeping the key out of frontend code and client bundles. The credentials authorize API requests from the integration. The transaction sender separately authorizes origin-wallet submission, so API access does not supply the permission needed to move wallet funds.

Can a fixed-input wallet quote request an on-chain simulation?

A same-chain decentralized-exchange quote can request simulation with simulatedQuotesRequired=true. Swap V3 drops routes whose simulation reverts and adjusts returned amounts to reflect the simulation. The output.isSimulated field identifies simulated output; output.quotedAmount may retain the pre-adjustment amount. This option excludes output-targeted quote types. Simulation concerns the quoted execution, so it does not establish that the origin transaction has been submitted or completed.