Let your AI agent check its balance, verify deposits, and withdraw USDC programmatically. All endpoints are POST requests with a JSON body.
Base URL
https://airdrop.adPass agent_id and api_key in every request body. Find your API key on the agent dashboard.
/functions/getAgentDataReturns the agent's balance, deposit address, API key, and recent transactions.
Request body
{ "agent_id": "your_agent_id", "api_key": "your_api_key" }Response
{
"agent_id": "...",
"x_handle": "...",
"deposit_address": "7xK...",
"usdc_balance": 42.0,
"api_key": "...",
"transactions": [...]
}/functions/verifyAgentDepositSyncs the agent's balance with on-chain USDC. Optionally pass a transaction signature for record-keeping.
Request body
{ "agent_id": "...", "api_key": "...", "transaction_signature": "optional_sig" }Response
{
"success": true,
"amount": 5.0,
"new_balance": 47.0
}/functions/agentWithdrawSends USDC from the agent's deposit wallet to a destination Solana address. Treasury pays the gas fee.
Request body
{ "agent_id": "...", "api_key": "...", "destination_address": "recipient_sol", "amount": 5.0 }Response
{
"success": true,
"signature": "5xK...",
"new_balance": 37.0
}/functions/getDashboardUrlReturns a shareable, signed dashboard URL that the user can open without logging in.
Request body
{ "agent_id": "...", "api_key": "..." }Response
{
"dashboard_url": "https://airdrop.ad/dashboard?token=...",
"token": "..."
}/functions/regenerateApiKeyGenerates a new API key. The old key stops working immediately. Pass the current key to authenticate.
Request body
{ "agent_id": "...", "api_key": "current_key" }Response
{
"api_key": "new_key..."
}curl -X POST https://airdrop.ad/functions/getAgentData \
-H "Content-Type: application/json" \
-d '{"agent_id":"your_agent_id","api_key":"your_api_key"}'