import { DZapClient } from '@dzapio/sdk';
const dzap = DZapClient.getInstance();
const bundleQuote = await dzap.getZapBundleQuote({
account: '0xUser',
steps: [
// Step 1: bridge USDC Arbitrum → Base
{
type: 'bridge',
srcChainId: 42161,
destChainId: 8453,
srcToken: '0xaf88d065e77c8cC2239327C5EDb3A432268e5831',
destToken: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913',
amount: '500000000', // 500 USDC
},
// Step 2: zap into the USDC/WETH 0.05% pool
{
type: 'zap',
srcChainId: 8453,
destChainId: 8453,
srcToken: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913',
destToken: '0xd0b53D9277642d899DF5C87A3966A349A798F224',
action: 'add-liquidity',
pool: '0xd0b53D9277642d899DF5C87A3966A349A798F224',
},
],
recipient: '0xUser',
refundee: '0xUser',
slippage: 1,
});
const tx = await dzap.buildZapBundleTx({
account: '0xUser',
bundleId: bundleQuote.bundleId,
});
// Then sign + send tx, OR use signGaslessDzapUserIntent for gasless flow.