Get swap execution status (deprecated)
Deprecated. Prefer getSwapStatusV2 instead. Retrieves the status of a swap transaction and returns the L1 transaction ID of the receiving transaction (toL1TxId) if the swap has been finalized. For BTC, LTC, and DOGE transactions, you should optionally provide the receiverAddress and toType to check for unconfirmed finalization transactions that may not yet be confirmed on the blockchain.
Optional API key. When provided, increases the allowed number of requests per second.
In: header
Query Parameters
The L1 transaction ID that initiated the swap. Should be passed withput "0x" prefix.
The C1 contract address for the source token.
The C2 contract address for the source token.
The C2 contract address for the destination token.
Backend URL. Default is https://api-cloud.coinweb.io/wallet. This URL is used to query the contract's claim storage to retrieve all orders.
uriThe receiver address on the destination L1 chain. Required only for BTC, LTC, and DOGE transactions. This address is used to check for incoming finalization transactions that may be unconfirmed on the blockchain. Allows tracking swap completion even when the finalization transaction is still pending confirmation.
The type of the destination blockchain. The type of the destination coin or token. Required for all transactions to identify the asset used when querying the finalization transaction status.
"eth" | "btc" | "ltc" | "doge" | "bnb" | "pol" | "trx" | "usdt_trx" | "usdt_bnb" | "usdc_bnb" | "usd1_bnb" | "wbtc_bnb" | "usdt_eth" | "wbtc_eth" | "usdc_eth" | "usd1_eth" | "usdt_pol" | "usdc_pol" | "eth_arb" | "arb_arb" | "usdt_arb" | "usdc_arb" | "eth_base" | "usdt_base" | "usdc_base"Response Body
curl -X GET "https://api.pactswap.io/pactswap_cm/getSwapStatus?fromL1TxId=a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d&fromC1ContractId=0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85&fromC2ContractId=0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85&toC2ContractId=0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85&backendUrl=https%3A%2F%2Fapi-cloud.coinweb.io%2Fwallet&receiverAddress=string&toType=eth"{
"toL1TxId": "a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d",
"isRefund": true,
"pact": {
"id": "order-123-abc",
"baseAmount": "1000000000000000000",
"promisedL1Amount": "50000000",
"pactL1Amount": "50000000",
"minL1Amount": "40000000",
"slippageBips": 50,
"collateral": "1000000000000000000",
"createdAt": 1704067200000,
"executionStatus": "PENDING",
"expirationDate": 1704153600000,
"l1Recipient": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh",
"requestedOrderId": "order-123-abc",
"txId": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
"chainData": {
"address": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh",
"nonce": 0
},
"history": {
"historyId": "a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d",
"timestamp": 1717334400
},
"requestInfo": {
"contractId": "0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85",
"orderId": "order-123-abc",
"l1TxId": "a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d",
"l1Amount": "0x2faf080",
"l1Address": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh"
},
"executionInfo": {
"l1TxId": "a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d",
"l1Amount": "50000000"
},
"marketMaker": {
"auth": "EcdsaContract",
"payload": "020a89e0698443aaf4ecd613317d2fdf90ef73b99244182fc7bb3c6b85f375b876"
},
"isRefund": true,
"affiliateFees": {
"affiliateFeesCweb": "100000000000000000",
"affiliateFeesToken": "50000000",
"affiliateFeesUsdt": "100000000000000000",
"affiliates": [
{
"affiliateId": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"bips": 1
}
],
"token": "BNB",
"oracles": {
"fromToken": {
"decimals": 18,
"l2ContractId": "0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85",
"rate": "100000000000000000",
"roundId": 1,
"token": "BNB"
},
"usdt": {
"decimals": 18,
"l2ContractId": "0x6f20d1802288c90d2a044d3f7afae73fda261b27d85c0e01fdaaf3199b2c0e85",
"rate": "100000000000000000",
"roundId": 1,
"token": "BNB"
}
}
}
}
}Was this documentation helpful? Any suggestions?