Ensure the AirSwap CLI is installed.
$ yarn global add airswap
In development, set the chain to 4
with the airswap chain
command. The following examples assume a local development server is running at http://localhost:3000
.
Request a maximum quote to see what's available.
$ airswap quote:maxAirSwap CLI 1.3.8 — https://support.airswap.io/get a max quote from a peer RINKEBYlocator: http://localhost:3000buy or sell: buytoken: wethfor: daiResponse: http://localhost:3000Selling up to 0.25 WETH for 100 DAI
Request a quote for 0.1 WETH.
$ airswap quote:getAirSwap CLI 1.3.8 — https://support.airswap.io/get a quote from a peer RINKEBYlocator: http://localhost:3000buy or sell: buyamount: 0.1of: wethfor: daiQuote from http://localhost:3000✨ Buy 0.1 WETH for 40 DAIPrice 0.0025 WETH/DAI (400 DAI/WETH)
You can debug all Quote and Order API methods using the quote
and order
AirSwap CLI commands.