Guide to atomic swap - trustless cross-chain trading
Atomic swaps, or atomic cross-chain trading, is a decentralized cryptocurrency-to-cryptocurrency trading method that relies on smart contracts, without having to trust any intermediary, or third party. The Komodo project is currently the most prominent project in the "atomic swaps" arena, yet it is still under development.
Atomic swap, or atomic cross-chain trading, is the exchange of one cryptocurrency to another cryptocurrency, without the need to trust a third-party. The atomic swap process is completely trustless and works by ensuring both parties fulfill the requirements of the trade, as defined in the contract. If one fails to meet the requirements, the time-locked contract will refund the other user. Let’s explain an atomic swap with a classic example of Alice and Bob. Alice owns one komodo coin, but really wants one dash instead. Normally, Alice would have to trade her komodo coin for an intermediary coin, like bitcoin, in order to trade the bitcoin for one dash coin. If so, she will lose some money because she has to trade twice. With atomic swap technology available, users are able to trade on a peer-to-peer basis without the need for an exchange. A time-locked contract will be used to act as the escrow between Alice and Bob. Alice puts in her one komodo coin and Bob has to send his dash coin to the contract. The contract will take care of the swap, so Alice becomes the owner of one dash and Bob of one komodo coin.