LuckyBox
The API related to LuckyBox
GEThttps://open.debox.pro/openapi/lucky_box/user222
Get Luckybox information sent/received by address user
Parameters
Header
app_id
: String
Unique app identifier, obtain from DeBox Open Platform
X-API-KEY
: String
Developer API Key, obtain from DeBox Open Platform
nonce
: String
Random number, 8 digits long
timestamp
: String
Timestamp, accurate to milliseconds
signature
: String
sha1 calculated signature, must strictly follow the signature calculation rules below
Signature calculation rules:
// keep sequence:appsecret -> nonce -> timestamp
signature = SHA1({appsecret}{nonce}{timestamp})
appsecret: Developer App Secret, obtain from [DeBox Open Platform](https://developer.debox.pro/)
Signature calculation requires signing the random number and timestamp using the Developer App Secret corresponding to the X-API-KEY.
Query
wallet_address
: Wallet address, which represents a user
chain_id
: Blockchain network ID, default 1, Ethereum Mainnet
Responses
200: OK
# receive_luckyBox_number Number of LuckyBox received
# receive_luckyBox_total Number of LuckyBox received (amount)
# send_luckyBox_number Number of LuckyBox sent
# send_luckyBox_total Number of LuckyBox sent (amount)
{
"code": 1,
"data": {
"receive_luckyBox_number": 12,
"receive_luckyBox_total": 1235.9,
"send_luckyBox_number": 18,
"send_luckyBox_total": 3199.58
},
"message": "success",
"success": true
}
400: Bad Request
{"error":"Bad Request","code":400,"message":"You X-API-KEY is not available"}
GEThttps://open.debox.pro/openapi/lucky_box/user/group
The number of LuckyBox received by a user in a particular group
Parameters
Header
app_id
: String
Unique app identifier, obtain from DeBox Open Platform
X-API-KEY
: String
Developer API Key, obtain from DeBox Open Platform
nonce
: String
Random number, 8 digits long
timestamp
: String
Timestamp, accurate to milliseconds
signature
: String
sha1 calculated signature, must strictly follow the signature calculation rules below
Signature calculation rules:
// keep sequence:appsecret -> nonce -> timestamp
signature = SHA1({appsecret}{nonce}{timestamp})
appsecret: Developer App Secret, obtain from [DeBox Open Platform](https://developer.debox.pro/)
Signature calculation requires signing the random number and timestamp using the Developer App Secret corresponding to the X-API-KEY.
Query
wallet_address
: Wallet address, which represents a user
chain_id
: Select The blockchain network from which you want to obtain data
group_invite_url
: Group share URL, which represents a group
Responses
200: OK
# receive_luckyBox_number Number of LuckyBox received
{
"code": 1,
"data": {
"receive_luckyBox_number": 8 Number of LuckyBox received
},
"message": "success",
"success": true
}
400: Bad Request
{"error":"Bad Request","code":400,"message":"You X-API-KEY is not available"}
GEThttps://open.debox.pro/openapi/lucky_box/group
Get the total amount of LuckyBox sent by the current group
Request Example:
curl -X GET -H "X-API-KEY: t2XAlEF6......" \
"https://open.debox.pro/openapi/lucky_box/group?\
group_invite_url=https://m.debox.pro/group?id=fxi3hqo5"
Request Example:
curl -X GET -H "X-API-KEY: t2XAlEF6......" \
"https://open.debox.pro/openapi/lucky_box/group?\
group_invite_url=https://m.debox.pro/group?id=fxi3hqo5"
Parameters
Header
app_id
: String
Unique app identifier, obtain from DeBox Open Platform
X-API-KEY
: String
Developer API Key, obtain from DeBox Open Platform
nonce
: String
Random number, 8 digits long
timestamp
: String
Timestamp, accurate to milliseconds
signature
: String
sha1 calculated signature, must strictly follow the signature calculation rules below
Signature calculation rules:
// keep sequence:appsecret -> nonce -> timestamp
signature = SHA1({appsecret}{nonce}{timestamp})
appsecret: Developer App Secret, obtain from [DeBox Open Platform](https://developer.debox.pro/)
Signature calculation requires signing the random number and timestamp using the Developer App Secret corresponding to the X-API-KEY.
Query
group_invite_url
: Group share URL, which represents a group
Responses
200: OK
# sum_amount The total vBOX sended
# total_num The total number sended
{
"code": 200,
"data": {
"sum_amount": 3896,
"total_num": 30
},
"message": "success",
"success": true
}
400: Bad Request
{"error":"Bad Request","code":400,"message":"You X-API-KEY is not available"}