Skip to content

Token API

This page provides routes for managing tokens. The following routes are available:

Retrieve the name of the token

This endpoint retrieves the name of the token.

GET https://api.token.web3sandpit.com/api/v1/tokens/token-name

INFO

Authentication: Requires ApiKey for authentication. Permissions: Requires USER role with read permission.

Parameters

None

Example

json
{}
json
  {
    "name": "Example Token"
    "status":"success"
  }

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

Retrieve the symbol of the token

This endpoint retrieves the symbol of the token.

GET https://api.token.web3sandpit.com/api/v1/tokens/token-symbol

INFO

Authentication: Requires ApiKey for authentication.

Permissions: Requires USER role with read permission.

Parameters

None

Example

json
{}
json
{
  "symbol": "EXT",
  "status": "success"
}

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

Retrieve the total supply of the token

This endpoint retrieves the total supply of the token.

GET https://api.token.web3sandpit.com/api/v1/tokens/total-supply

INFO

Authentication: Requires ApiKey for authentication.

Permissions: Requires USER role with read permission.

Parameters

None

Example

json
{}
json
{
  "totalSupply": "1000000",
  "status": "success"
}

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

Retrieve the token balance for the authenticated user

This endpoint retrieves the token balance for the authenticated user.

GET https://api.token.web3sandpit.com/api/v1/tokens/my-token-balance

INFO

Authentication: Requires ApiKey for authentication.

Permissions: Requires USER role with read permission.

Parameters

None

Example

json
{}
json
{
  "balance": "1000",
  "status": "success"
}

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

Retrieve the token balance for the organization

This endpoint retrieves the token balance for the organization.

GET https://api.token.web3sandpit.com/api/v1/tokens/balance/organization

INFO

Authentication: Requires ApiKey for authentication.

Permissions: Requires OWNER role with read permission.

Parameters

None

Example

json
{}
json
{
  "balance": "5000",
  "status": "success"
}

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

Transfer the token to a wallet address by email

This endpoint transfers tokens to a specific wallet address.

POST https://api.token.web3sandpit.com/api/v1/tokens/transfer

INFO

Authentication: Requires ApiKey for authentication.

Permissions: Requires USER role with write permission.

Parameters

None

Example

json
{
  "email": "example@example.com",
  "amount": "1000"
}
json
{
  "blockHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
  "blockNumber": 1,
  "from": "0x0000000000000000000000000000000000000000",
  "gas": 21000,
  "gasPrice": 1000000000,
  "hash": "0x0000000000000000000000000000000000000000000000000000000000000000",
  "status": "success",
  "to": "0x0000000000000000000000000000000000000000",
  "value": 1000
}

HTTP Response Codes

Status CodeTextDescription
200OKWith an array of user objects and pagination information.
400Bad RequestThe request was invalid or cannot be processed.
401UnauthorizedAuthentication is required or has failed.
403ForbiddenThe authenticated user is not authorized to perform the requested action.
404Not FoundThe requested resource could not be found.
500Internal Server ErrorAn unexpected error occurred.

API Documentation created with ❤️ by TrackGenesis