Statuses
Seven public statuses describe an exchange.
The seven statuses
| Status | Meaning | Terminal |
|---|---|---|
pending | Rate held while the exchange prepares | no |
awaiting_deposit | Send exactly fromAmount before validUntil | no |
confirming | Deposit seen and being confirmed | no |
exchanging | Destination asset is being sent | no |
finished | Complete; toTxHash is set | yes |
refunded | The other side failed to deliver; see below | yes |
failed | See reason | yes |
refunded: the exchange was guaranteed by a deposit in SOL or TAO; when the other side fails to deliver, you receive 110% of the exchange value in that asset (refundAsset is sol or tao), priced when the rate was locked, at your address on that side (refundAddress). A subnet-token leg is paid in TAO to that leg's Bittensor address, as free balance.
reason is set only when status is failed; it is null on every other status.
Failure reasons
| reason | Meaning | Credit |
|---|---|---|
pool_lost | Rate could not be retained | refunded |
reserve_rejected | Rate could not be reserved | refunded |
claim_stale | Deposit moved but claim went stale; contact support | refunded |
dest_unpayable | toAddress could not receive the asset. The funds you sent are not returned; only the credit is refunded. Make sure toAddress can receive the asset before you create the exchange | refunded |
asset_unavailable | The subnet token in to was shut down before delivery. The funds you sent are not returned; only the credit is refunded. Do not retry the same to | refunded |
deposit_lapsed | No funds arrived before the deadline | kept; refunded only if the exchange expired before your deposit window ended |
Examples
refunded
{
"status": "refunded",
"refundAsset": "sol",
"refundAddress": "9s4hVRU5nfPF9Er9Y5FexDjxNtvZSYmnVEujxHCX5Gsb",
"reason": null
}failed
{
"status": "failed",
"refundAsset": null,
"refundAddress": null,
"reason": "pool_lost"
}