Send Reward

Send token rewards to your users on Base. This endpoint allows you to distribute tokens from your reward balance to specified addresses.

POSTapi.metal.build/token/:address/reward

Send reward

This endpoint initiates a token reward distribution.

Required attributes

  • Name
    sendTo
    Type
    string
    Description

    The address to receive the reward.

  • Name
    amount
    Type
    number
    Description

    The amount of tokens to send.

Request

POST
api.metal.build/token/:address/reward
curl https://api.metal.build/token/0x1234567890abcdef1234567890abcdef12345678/reward \
  -H "Content-Type: application/json" \
  -H "x-api-key: YOUR-API-KEY" \
  -d '{
    "sendTo": "0xabcdef1234567890abcdef1234567890abcdef12",
    "amount": 100
  }'

Response

{
  "jobId": "e20b21ec-10ca-5756-938c-855e78add351",
  "status": "pending"
}




GETapi.metal.build/token/:address/reward/status/:jobId

Status

This endpoint will return the status of your reward distribution.

Required attributes

  • Name
    jobId
    Type
    string
    Description

    Job ID of the reward distribution.

Request

GET
api.metal.build/token/:address/reward/status/:jobId
curl https://api.metal.build/token/0x1234567890abcdef1234567890abcdef12345678/reward/status/e20b21ec-10ca-5756-938c-855e78add351 \
  -H "x-api-key: YOUR-API-KEY"

Pending Response

{
  "jobId": "e20b21ec-10ca-5756-938c-855e78add351",
  "status": "pending",
}

Successful Response

{
  "jobId": "e20b21ec-10ca-5756-938c-855e78add351",
  "status": "success",
}

Was this page helpful?