[{"data":1,"prerenderedAt":229},["ShallowReactive",2],{"docs:en:\u002Fdocs\u002Fduel\u002Fguide\u002Ftrade":3},{"id":4,"title":5,"body":6,"cover":220,"description":221,"extension":222,"meta":223,"navigation":224,"path":225,"seo":226,"stem":227,"__hash__":228},"docs\u002Fdocs\u002Fduel\u002Fguide\u002Ftrade.md","Trade a duel",{"type":7,"value":8,"toc":207},"minimark",[9,13,22,27,89,92,109,113,134,139,155,163,167,173,177,184,188,196,200],[10,11,5],"h1",{"id":12},"trade-a-duel",[14,15,16,17,21],"p",{},"Every duel has a trade panel: on a computer beside the duel, on a phone behind the ",[18,19,20],"strong",{},"Buy"," buttons at the bottom of the\nscreen. It works like Uniswap's swap widget: what you pay above, what you receive below, and a button between them that\nflips the two.",[23,24,26],"h2",{"id":25},"three-trades","Three trades",[28,29,30,46],"table",{},[31,32,33],"thead",{},[34,35,36,40,43],"tr",{},[37,38,39],"th",{},"You pay",[37,41,42],{},"You receive",[37,44,45],{},"What happens",[47,48,49,63,75],"tbody",{},[34,50,51,55,58],{},[52,53,54],"td",{},"ETH",[52,56,57],{},"A side",[52,59,60,62],{},[18,61,20],{},": the side's price goes up, and the split moves toward it.",[34,64,65,67,69],{},[52,66,57],{},[52,68,54],{},[52,70,71,74],{},[18,72,73],{},"Sell",": the side's price goes down, and the split moves away from it.",[34,76,77,80,83],{},[52,78,79],{},"One side",[52,81,82],{},"The other side",[52,84,85,88],{},[18,86,87],{},"Switch",": the side you leave is sold for ETH and all of it buys the other, in one transaction.",[14,90,91],{},"Pick the asset of each field from its menu, which also shows what your wallet holds. Picking the asset of the other\nfield swaps the two fields, as on Uniswap.",[14,93,94,95,98,99,102,103,108],{},"With default terms, trades against ETH pay ",[18,96,97],{},"1.2%"," in ETH, and a switch through ETH pays on both legs. A direct A\u002FB switch instead burns ",[18,100,101],{},"0.5%"," of the token you leave. The panel quotes both routes and takes the greater net output; it shows the route and the duel’s actual fee terms. See ",[104,105,107],"a",{"href":106},"\u002Fdocs\u002Fduel\u002Fconcepts\u002Ffees","Fees",".",[23,110,112],{"id":111},"before-you-confirm","Before you confirm",[114,115,116,122,128],"ul",{},[117,118,119,121],"li",{},[18,120,42],{}," is a quote from the Uniswap V4 Quoter: what the swap would give right now, fees included.",[117,123,124,127],{},[18,125,126],{},"Slippage"," (Auto at 2%, a preset, or a custom value up to 50% in the settings) sets the minimum output you accept. If execution would return less, the swap fails. The deadline is 10 minutes by default, adjustable up to 3 hours: inclusion after it fails, but it does not cancel a pending transaction. A failed transaction can still cost network gas.",[117,129,130,133],{},[18,131,132],{},"Price impact"," compares the quote with the pool’s current price. The details under the quote show the rate, minimum received and fee.",[135,136,138],"h3",{"id":137},"large-trades","Large trades",[14,140,141,142,145,146,149,150,154],{},"Past ",[18,143,144],{},"5%"," price impact, the button turns red; past ",[18,147,148],{},"15%",", it asks for a second tap. A large trade can move the price substantially. If the subsequent ",[104,151,153],{"href":152},"\u002Fdocs\u002Fduel\u002Fconcepts\u002Frealignment","realignment"," runs, it can partly offset that move and capture profit for the pot. Selling straight back may return much less than you paid; the absence of a holding lock does not guarantee available liquidity.",[156,157,160],"callout",{"title":158,"type":159},"Round trips cost more than the fees","tip",[14,161,162],{},"Internal illustrative measurements on a fresh duel with default terms put an immediate buy then sell at about 5% lost for 1 ETH, 10% for 5 ETH and 22% for 20 ETH, including fees and realignment. These are not fixed rates; costs vary with pool state. Trade a size the duel can carry.",[135,164,166],{"id":165},"selling-all-of-a-side","Selling all of a side",[14,168,169,170,172],{},"An ETH pool can hold less ETH than its side's holders could ask of it: after each purchase, the ",[104,171,153],{"href":152}," sells into it tokens taken from the pool between the sides, and the ETH they fetch goes to the other side's pool. Selling everything at once can then bring the pool back to its launch price before every token is sold. The Duel router sells the rest in the same transaction: into the same pool once the realignment after the sale has bought those tokens back, then what it could not buy back through the pool between the sides into the other side's ETH pool, where their ETH went. The panel quotes the whole sale, and names what would stay in your wallet only when the other side's pool cannot pay for it either.",[23,174,176],{"id":175},"approvals","Approvals",[14,178,179,180,183],{},"Buying with ETH needs no approval. Selling or switching a side's token takes one transaction too: your wallet first asks\nfor a signature, a permit (EIP-2612) that lets the Duel router move exactly that amount, then for the trade, which uses\nit. The signature approves the token and nothing else: the price, the minimum received and the recipient belong to the\ntrade, which you confirm next. A contract wallet (a Safe, say) cannot sign a permit the token accepts: it approves the\nrouter with a transaction instead, once per token, as anyone can choose to by turning off ",[18,181,182],{},"Approve by signature"," in\nthe swap settings. If the trade fills only in part (the pool moved meanwhile), the rest of the permit stays approved for\nthe router. The router only ever pulls tokens from the wallet that sends the swap.",[23,185,187],{"id":186},"in-the-first-seconds","In the first seconds",[14,189,190,191,195],{},"With default launch terms, for 10 seconds after a duel launches, buys pay an ",[104,192,194],{"href":193},"\u002Fdocs\u002Fduel\u002Fconcepts\u002Ffees#the-anti-snipe-tax","anti-snipe tax"," that\nstarts at 98% and halves at least once a second. The trade panel shows it while it lasts. Waiting a few seconds is\nalmost always better.",[23,197,199],{"id":198},"other-ways-to-trade","Other ways to trade",[14,201,202,203,108],{},"Duel's pools are ordinary Uniswap V4 pools with a hook: any V4 router, terminal or aggregator can trade them, and the\nhook applies the same fees and rules whoever routes the swap. Only the Duel router sells in several passes: through another router, a sale bigger than what its ETH pool can pay for stops at the pool's launch price, and the rest stays in your wallet. See ",[104,204,206],{"href":205},"\u002Fdocs\u002Fduel\u002Fcontracts\u002Fintegrate","Build on Duel",{"title":208,"searchDepth":209,"depth":210,"links":211},"",2,3,[212,213,217,218,219],{"id":25,"depth":209,"text":26},{"id":111,"depth":209,"text":112,"children":214},[215,216],{"id":137,"depth":210,"text":138},{"id":165,"depth":210,"text":166},{"id":175,"depth":209,"text":176},{"id":186,"depth":209,"text":187},{"id":198,"depth":209,"text":199},null,"How to trade a duel: buy a side with ETH, sell it or switch sides in one transaction, with slippage, deadline, price impact and approval by signature.","md",{},true,"\u002Fdocs\u002Fduel\u002Fguide\u002Ftrade",{"title":5,"description":221},"docs\u002Fduel\u002Fguide\u002Ftrade","VeRfRg7iyhf9m988dhMF2WcsXBAkxjB6Q0mtaoj0lA0",1791226974097]