Get Token Details

This API endpoint fetches token details from SunPump, providing metadata (e.g., name, symbol, URLs) and dynamic data (e.g., market stats, price).

Note: You must provide a valid API key in the request headers to access this endpoint.

Endpoint

  • URL: /sunpump/getTokenDetails

  • Method: POST

  • Content-Type: application/json

  • API Key Header: api-key: your-api-key

Request Body

  • address (string, required): The contract address of the token you want to retrieve details for.

Example Request Body JSON

{
  "address": "TNNND7Gq3h6s6zMdCB56PHvW8959HPh97z" // Token Contract Address
}

Example Request

curl -X POST "https://api.dangeracorn.com/sunpump/getTokenDetails" \
-H "Content-Type: application/json" \
-H "api-key: your-api-key" \
-d '{
  "address": "TNNND7Gq3h6s6zMdCB56PHvW8959HPh97z"
}'

Example Response JSON

{
    "metadata": {
        "name": "TRONDOG",
        "symbol": "TRONDOG",
        "description": "DOG ON TRON",
        "image": "https://cdn.sunpump.meme/public/logo/TRONDOG_TDpZeL_5PshTZjrCHc1.jpg",
        "twitter": null,
        "telegram": null,
        "website": null,
        "ownerAddress": "TDpZeLu2HbhoarLZEdwCZudyoafMgLiqGb",
        "contractAddress": "TNNND7Gq3h6s6zMdCB56PHvW8959HPh97z"
    },
    "data": {
        "currentStatus": "CREATED",
        "priceInTrx": 0.00003710479917223,
        "totalSupply": 1000000000,
        "currentSold": 65359069,
        "marketCap": 5717.79,
        "trxReserve": 2277,
        "tokenReserve": 734640931.41,
        "volume24Hr": 0,
        "priceChange24Hr": 0,
        "pumpPercentage": 2,
        "createTxHash": "6c12fff2f1ad520adc1f79ff38863c26be15b49bbdb7bfee83833876fb452109",
        "launchTxHash": null,
        "active": true
    },
    "status": "success",
    "code": "200"
}

Example Error JSON

Missing address parameter (400)

{
  "error": "Missing address parameter",
  "message": "You must provide a valid token address",
  "code": "400"
}

Failed to fetch token details (500)

{
  "error": "Failed to fetch token details",
  "message": "There was a server-side error",
  "code": "500"
}

Notes

  • Rate Limiting: This endpoint is rate-limited according to your plan's API key limits. Ensure that you handle these limits in your application.

Last updated