# Agent Toolbox Credits Purchase ($1 USDC)

> Agent Toolbox Credits Purchase ($1 USDC) is a paid API for AI agents from agent-toolbox.zafermemon87.workers.dev, paid per call via x402, $1/call, status unknown (last checked 2026-11-22).

Purchase $1 USDC worth of API credits for the Agent Toolbox service, receiving an API key with a credit balance usable across all Agent Toolbox tools.

## Facts

- Endpoint: POST https://agent-toolbox.zafermemon87.workers.dev/v1/credits/1?utm_source=zero.xyz
- Price: $1/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent-toolbox-credits-purchase-1-usdc-696622ad
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Z1hoWJDHKm-rB7Cfu68_D

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agent-toolbox-credits-purchase-1-usdc-696622ad -d '<json body>'
```

Example prompt: Buy $1 of Agent Toolbox credits using my x402 wallet so I can start calling their image generation, web-to-Markdown, and translation tools — I'll need the API key it returns.

## When to prefer this

Use this endpoint when an agent needs to obtain or top up an Agent Toolbox API key funded with USDC via the x402 micropayment protocol. This is the entry point for all Agent Toolbox capabilities (image generation, web-to-Markdown, speech-to-text, embeddings, translation, summaries, email checks, exchange rates, DNS lookups). Prefer this over other credit systems when you need a pay-per-call, no-subscription model with instant key provisioning and crypto payment support.

## Known failure modes

- Payment not received or x402 payment header missing/invalid — returns 402 Payment Required
- Insufficient USDC balance in wallet — payment fails before key is issued
- Duplicate or replayed payment token — may be rejected to prevent double-spend
- Network or worker error — returns 5xx with no key issued
- Malformed request body — returns 400 Bad Request

## How this service works

Buy $1.00 of Agent Toolbox credits for $1: returns an API key (shown once) that pays for every tool over HTTP and MCP with no per-call payment. Send an existing key in X-API-Key to top it up instead.

## Output

Returns a newly generated API key (prefixed `atb_`), a key ID, the total credits added in USD (base amount plus any bonus), and instructions on how to use the key as a Bearer token on subsequent Agent Toolbox API calls. Example response includes fields: key, plain (human-readable summary), key_id, balance (endpoint to check), paid_usd, bonus_usd, credits_added_usd.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "properties": {}
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "key": "atb_6f1c0e9a4b2d7c8e5f3a1b0c9d8e7f6a5b4c3d2e1f0a9b8c",
  "plain": "New API key with $5.50 of credits. Send it as Authorization: Bearer atb_... on any tool or MCP call.",
  "key_id": "3f2a91c07d5e",
  "balance": "GET /account with the key",
  "paid_usd": 5,
  "bonus_usd": 0.5,
  "credits_added_usd": 5.5
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent-toolbox-credits-purchase-1-usdc-696622ad/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent-toolbox.zafermemon87.workers.dev](https://www.zero.xyz/host/agent-toolbox.zafermemon87.workers.dev/llms.txt)
