Custom linking

Get front page

GET https://oswap.io/#/

https://oswap.io/#/

Get specific swap pair

GET https://oswap.io/#/swap/:identifier

Path Parameters

NameTypeDescription

identifier

string

Load the input asset and output asset from pool or load output asset from encoded asset ID

Query Parameters

NameTypeDescription

reverse

boolean

Flips the input asset with output asset if it has any value

https://oswap.io/#/swap/AR3SHS7SFH3PF6ZM6UIF7HWIV44TZ46H?reverse=1 <!-- pool address -->
https://oswap.io/#/swap/P+bT6OZY/eR765RrBORfAUl27FU/pAU10GMkuLc3s9U= <!-- not encoded, no url parameters -->
https://oswap.io/#/swap/P-bT6OZY_eR765RrBORfAUl27FU_pAU10GMkuLc3s9U <!-- base64url -->
https://oswap.io/#/swap/P%2BbT6OZY%2FeR765RrBORfAUl27FU%2FpAU10GMkuLc3s9U%3D <!-- encodeURIComponent -->

Swap and send to address

GET https://oswap.io/#/send/:poolAddress

Path Parameters

NameTypeDescription

poolAddress

string

Load the input asset and output asset from pool

Query Parameters

NameTypeDescription

reverse

boolean

Flips the input asset with output asset if it has any value

to

string

Wallet address

https://oswap.io/#/send?to=FAB6TH7IRAVHDLK2AAWY5YBE6CEBUACF <!-- just "to" address -->
https://oswap.io/#/send/AR3SHS7SFH3PF6ZM6UIF7HWIV44TZ46H?reverse=1&to=FAB6TH7IRAVHDLK2AAWY5YBE6CEBUACF <!-- pool address with "to" address -->

Create new pool with asset

GET https://oswap.io/#/create-pool/:assetId

Path Parameters

NameTypeDescription

assetId

string

Unit ID of asset definition

https://oswap.io/#/create-pool/P+bT6OZY/eR765RrBORfAUl27FU/pAU10GMkuLc3s9U= <!-- not encoded -->
https://oswap.io/#/create-pool/P-bT6OZY_eR765RrBORfAUl27FU_pAU10GMkuLc3s9U <!-- base64url -->
https://oswap.io/#/create-pool/P%2BbT6OZY%2FeR765RrBORfAUl27FU%2FpAU10GMkuLc3s9U%3D <!-- encodeURIComponent -->

Add liquidity to pool (both assets)

GET https://oswap.io/#/add-liquidity/:poolAddress

Path Parameters

NameTypeDescription

poolAddress

string

Address of pool AA

https://oswap.io/#/add-liquidity
https://oswap.io/#/add-liquidity/AR3SHS7SFH3PF6ZM6UIF7HWIV44TZ46H

Add liquidity to pool (one asset)

GET https://oswap.io/#/add-liquidity-2/:poolAddress

Path Parameters

NameTypeDescription

poolAddress

string

Address of pool AA

https://oswap.io/#/add-liquidity-2/AR3SHS7SFH3PF6ZM6UIF7HWIV44TZ46H

Remove liquidity from pool

GET https://oswap.io/#/remove-liquidity/:poolAddress

Path Parameters

NameTypeDescription

poolAddress

string

Address of pool AA

https://oswap.io/#/remove-liquidity/AR3SHS7SFH3PF6ZM6UIF7HWIV44TZ46H

Get all pools

GET https://oswap.io/#/pools

https://oswap.io/#/pools

Get pools that contain specific asset

GET https://oswap.io/#/asset/:assetId

Path Parameters

NameTypeDescription

assetId

string

Unit ID of asset definition

https://oswap.io/#/asset/P+bT6OZY/eR765RrBORfAUl27FU/pAU10GMkuLc3s9U= <!-- not encoded -->
https://oswap.io/#/asset/P-bT6OZY_eR765RrBORfAUl27FU_pAU10GMkuLc3s9U <!-- base64url -->
https://oswap.io/#/asset/P%2BbT6OZY%2FeR765RrBORfAUl27FU%2FpAU10GMkuLc3s9U%3D <!-- encodeURIComponent -->
https://oswap.io/#/asset/base <!-- Obyte Bytes -->

Last updated