Getting started
This guide will guide you through the first steps of working with the SMARTy Pay API.
Before you can make requests to the SMARTy Pay API, you will need to grab your API key & API secret from your dashboard. You find it under Settings » API Keys.
Choose your client
For simplicity in this guide, we will use the terminal and command-line utilities for making HTTP requests, such as curl and HTTPie. If they are not already installed, please install them through your operating system's package manager before starting.
To verify the installation, please use:
curl --version
Making your first API request
After picking your preferred client, you are ready to make your first call to the SMARTy Pay API. Below, you can see how to send a GET request to dictionary endpoints to get all supported blockchain networks. Don't forget to replace the placesholders with your valid API key & secret.
Request
curl https://partner-api.smartypay.io/v1/dictionary/blockchains \
-u API_KEY:SECRET
You should expect gettins something like this.
Response
{
"blockchains": [
{
"apiType": "WEB3",
"blockchain": "EthereumMainNet",
"isActive": true,
"nativeAsset": {
"code": "ETH",
"formatDecimals": 18,
"isSettlementSupported": false,
"label": "ETH",
"name": "Ethereum native asset",
"symbol": "ETH"
},
"net": "MainNet"
},
{
"apiType": "Tron",
"blockchain": "TronMainNet",
// ...
},
// ... more items
]
}
Congratulations 🎉 ! You just made your first successful interaction with the SMARTy Pay API.
What's next?
Great, you're now set up with an API client and have made your first request to the API. Here are a few links that might be handy as you venture further into the SMARTy Pay:
Continue with the guides
- Learn more about core concepts
- Learn how to create and process one-time payments
- How to work with the reccuring payments
- Withdrawals (or Settlements)
Continue exploring how to work with the API