Log in to account

or create one

Language

Social networks

API Setup Guide

All requests to the Swappix API must contain The AUTH-KEY header and The Content-Type header must be application/json; charset=UTF-8. AUTH-KEY available after registration in the Partner Program.

API Endpoint https://swappix.io/api/v1/

Address checking

This request determines the correctness of the entered address. : https://swappix.io/api/v1/check-address

Parameter

cryptoCurrencyStringBTC
cryptoAddressStringbc1q9k0z7fs5wxvpcn5x7gy0l7dhz9prw9yjd3lqr4
# Here is a curl example
curl -X GET "https://swappix.io/api/v1/check-address?cryptoCurrency=BTC&cryptoAddress=bc1q9k0z7fs5wxvpcn5x7gy0l7dhz9prw9yjd3lqr4" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
result: true
}

Exchange Rate Information for Amount

This request retrieves the current exchange rate. The rate does not include the transaction fee (miner fee) charged for each transaction. : https://swappix.io/api/v1/get-rate

Parameter

currencyFromStringBTC
currencyToStringETH
amountfloat1
* withdrawalFee - approximate withdrawal fee. Floating parameter.
# Here is a curl example
curl -X GET "https://swappix.io/api/v1/get-rate?currencyFrom=BTC&currencyTo=ETH&amount=1" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
rate: 13.38099645346961
withdrawalFee: "0.00119 ETH"
result: true
}

Currency List

This request retrieves the list of all available coins. : https://swappix.io/api/v1/currency-list

If tagname is not an empty value, then a tag is mandatory for this currency.
# Here is a curl example
curl -X GET "https://swappix.io/api/v1/currency-list" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
XMR: {
coinName: "Monero",
minamount: 12.27,
maxamount: 15527,
tagname: "",
network: "",
available: true
},
ETH: {
coinName: "Ethereum",
minamount: 1.33,
maxamount: 1693,
tagname: "",
network: "erc20",
available: true
},
DAI: {
coinName: "Dai",
minamount: 2127.89,
maxamount: 2746236,
tagname: "",
network: "erc20",
available: true
},
EOS: {
coinName: "EOS",
minamount: 2072.91,
maxamount: 2526315,
tagname: "MEMO",
network: "",
available: true
},
...
}

All Available Pairs

This request retrieves the list of all pairs available for exchange. : https://swappix.io/api/v1/pairs-list

# Here is a curl example
curl -X GET "https://swappix.io/api/v1/pairs-list" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
BTC: [
"USDT",
"BUSD",
"BNB",
"ETH",
"PAX",
"MATIC"
],
USDT: [
"BTC",
"XRP",
"DOGE",
"ETH"
],
DASH: [
"XMR",
"TUSD",
"ATOM"
],
XTZ: [
"USDT",
"BTC"
],
EOS: [
"ETH",
"PERL"
],
ADA: [
"TRX"
],
TUSD: [
"USDT"
],
ALGO: [
"BTC"
],
...
}

Exchange Setup

This request initiates an exchange. : https://swappix.io/api/v1/new-exchange

Parameter

targetAddressString0x3f8b7c7a2b3451e9f1a4d9a15c4e7d8b23a4d6e7
targetTagString(optional)
senderAddressString1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa
senderTagString(optional)
currencyFromStringBTC
currencyToStringZEC
amountfloat0.5
fixint0
# Here is a curl example
curl -X GET "https://swappix.io/api/v1/new-exchange?targetAddress=0x3f8b7c7a2b3451e9f1a4d9a15c4e7d8b23a4d6e7&targetTag=&senderAddress=1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa&senderTag=&currencyFrom=BTC&currencyTo=ZEC&amount=0.5" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
id: "nvmt36n6nkuu0aug",
depositAddress: "1P3H6Gz89R5zH4eXa2P7EzfU6fXJm6sPzX",
depositTag: "",
result: "true",
}

Fetching Exchange Status

Retrieve information about the current exchange status. : https://swappix.io/api/v1/check-status

Parameter

idStringnvmt36n6nkuu0aug
List of used statuses:
waiting_deposit - waiting for deposit
deposit_received - deposit received
exchanging - in the process of exchange
sending - in the process of sending
success - exchange successfully completed
time_expired - waiting time for funds has expired
failed - exchange ended with an error
sending_failed - sending attempt ended with an error
reverted - the clients funds were returned to them
# Here is a curl example
curl -X GET "https://swappix.io/api/v1/check-status?id=nvmt36n6nkuu0aug" \
     -H "auth-key: bc1qxy2kgdygjrsqtzq2n0yrf2493pkkfj" \
     -H "Content-Type: application/json; charset=UTF-8"

Result example :
{
status: "deposit_received",
from: "BTC",
to: "ZEC",
depositAddress: "1CZvtgpwynyXYhAvnFVWYoMbUmqp8qsoNd",
depositTag: "",
depositHash: "02990d369c4a596dfd0f0f9c5e23c19293cd",
destinationAddress: "1P3H6Gz89R5zH4eXa2P7EzfU6fXJm6sPzX",
destinationTag: "",
refundAddress: "1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa",
refundTag: "",
expectedAmountFrom: "0.5",
expectedAmountTo: "101",
amountFrom: "0.5",
date: "11.02.2024 01:30:21",
txId: null,
amountTo: null,
result: true
}