API Queries - Add Funds
The add_funds API function will top up your Above.com account if you have a credit card saved on file. The amount will be charged to your credit card and added instantly to your Above.com account balance. Currently a credit card can not be added via the API. You will need to log in at Above.com, click Account in the top-right, then the Billing Details tab to add a credit card on file.
Additional Parameters
- amount - Amount in USD to be charged to your credit card on file. You can optionally specify cents, however do not include a dollar sign.
Your API key is required and all values should be correctly URL encoded.
Example
In the below example, we will add USD$116.25 to our account (amount=116.25). If the query is successful, the API will return a confirmation message and also the new balance of your Above.com account.
Queryhttps://www.above.com/registrar/api/query.html?key=APIKEY&query=add_funds&amount=116.25
Response<results code="100"> <msg>Funds have now been added to your account</msg> <balance>289.54</balance> </results>
Error Codes
Possible error responses for this function are:
- 1401 - Invalid amount specified or amount not specified
- 1402 - No credit card on file
- 1403 - Transaction declined
- General errors, such as 401 - Invalid API key or 500 - System unavailable.