API Gateway
https://tronspace.vip/api
Authentication
Creating orders require authentication using an x-api-key
header. You must include a valid API key in every request.
{
"headers": {
"x-api-key": "your-api-key-here"
}
}
Keep your API key secure and never share it in public repositories or client-side code. If you believe your API key has been compromised, contact support immediately for a replacement.
All API endpoints return SuperJSON formatted responses. The response contains two main fields:
json
: The actual response data
meta
: Type information for special data types (Date, BigInt, etc)
{
"json": {
"id": "198dc9ba-39f8-479d-b156-cac11ca5cc8d",
"name": "User",
"createdAt": "2025-01-16T10:37:53.293Z",
"wallet": "TAA9KiqKZSU2tUhqrPpYBHPprxnKVwnik5",
"orders": [
{
"resourceAmountSun": "5325147542",
"payment": "6000100"
}
]
},
"meta": {
"values": {
"createdAt": ["Date"],
"orders.0.resourceAmountSun": ["bigint"],
"orders.0.payment": ["bigint"]
}
}
}
When processing the response, use the meta
field to properly decode special types: - Dates will be ISO strings in json
but marked as Date
in meta - Large numbers will be strings in json
but marked as bigint
in meta
Responses are generated using AI and may contain mistakes.