Token Service API

Token validation and verification service providing blockchain data validation utilities. Used internally by other platform services for transaction processing.

Service Architecture

ProtocolPortDescription
gRPC9098Primary API (Tonic/Prost)
HTTP8088REST endpoints and health checks

REST Endpoints

Health

MethodPathDescription
GET/healthHealth check
GET/healthzLiveness probe
GET/metricsPrometheus metrics

Validation Endpoints

MethodPathDescription
GET/api/validate/hex/:valueValidate hex string format
GET/api/validate/block-height/:heightValidate block height parameter
GET/api/validate/tx-count/:countValidate transaction count

Validate Hex String

GET /api/validate/hex/0xa1b2c3d4e5f6
X-API-Key: your-api-key

Response

{
  "valid": true,
  "value": "0xa1b2c3d4e5f6",
  "bytes": 6
}

Validate Block Height

GET /api/validate/block-height/12345678
X-API-Key: your-api-key

Response

{
  "valid": true,
  "height": 12345678
}

Authentication

Protected endpoints require API key authentication:

X-API-Key: your-api-key

Rate Limiting

The Token service enforces rate limiting of 1000 requests per minute per API key.

gRPC Service

The Token service primarily operates via gRPC for internal platform communication. Contact support for gRPC proto definitions if building custom integrations.

Error Codes

CodeDescription
INVALID_HEXHex string format is invalid
INVALID_BLOCK_HEIGHTBlock height is out of valid range
RATE_LIMITEDRequest rate limit exceeded