API Documentation
Note that is mandatory make API requests using port 443 (HTTPS). Otherwise you will receive error 403 (denial of access). Responses are given in JSON format
Transfer
Endpoint: https://dragonwallet.us.to/api/payout.php
Request method: GET
Request parameters:
- key (str) - your secret key you got when started bot
- value (float) - value to be sent
- ticker (str) - currency ticker (lowercase)
- to (str) - recipient's Telegram ID
Response parameters:
- success (bool) - indicates if request was processed successfully
- message (str) - debug message
Get balances
Endpoint: https://dragonwallet.us.to/api/balances.php
Request method: GET
Request parameters:
- key (str) - your secret key you got when started bot
Response parameters:
- success (bool) - indicates if request was processed successfully
- message (str) - debug message
- balances (obj) - an object containing all balances for account, null on error
"balances" object example: {"nvc": 1000, "bnb": 0.2, "usdt":10.000001, "btc": 0.00011981, "evmos": 219.2046}
Check if user exists
Endpoint: https://dragonwallet.us.to/api/checkuser.php
Request method: GET
Request parameters:
- id (str) - user's Telegram ID
Response parameters:
- exists (bool) - existence indicator
Supported currencies
Endpoint: https://dragonwallet.us.to/api/tickers.php
Request method: GET
Request parameters:
- display (void) - just specify it
Response:
- Array containing all tickers of supported currencies
Accept payment
Endpoint: https://dragonwallet.us.to/api/invoice.php
User will receive notification of approval request
Request method: GET
Callback method: GET
Request parameters:
- key (str) - your secret key
- user (str) - Telegram ID of user that will receive notification
- ticker (str) - ticker of currency (in lowercase) you wish to get paid in, for example, "usdt"
- value (float) - value of invoice
- status (str) - URL where notifications will be forwarded
Response parameters:
- success (bool) - indicates if request was processed successfully
- message (str) - debug message, ok if notification was sent
- id (str) - invoice ID
Note: If you got "ok" from server, it does not means that invoice was paid. Await callback on your listening URL (status).
Forwarded parameters:
- id (str) - invoice ID
- value (str) - amount that user paid (decimal number in string)
- ticker (str) - currency ticker
- client (str) - Telegram ID of user that paid invoice
- proof (str) - SHA-1 hash of your secret key (proofs that this notification was sent by our server)
Note: Callbacks are sent only on successful payments. Then, if you got callback it means that your invoice was paid.
If you lost secret key, reset it in settings. All apps using an old key will receive denial of access. Restore it also if you noticed suspicious activity of your account