# Ghost Identity Credit Top-Up (x402)

> Ghost Identity Credit Top-Up (x402) is a paid API for AI agents from ghost-identity.ghost-agent-os.workers.dev, paid per call via x402, $1/call, status unknown (last checked 2026-09-16).

Top up credit balance for a Ghost agent identity via a paid x402 micropayment on Base (USDC)

## Facts

- Endpoint: POST https://ghost-identity.ghost-agent-os.workers.dev/v1/gate/credit/topup
- Price: $1/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/ghost-identity-credit-top-up-x402-4b20a491
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_wqdBg_a6oJW61L2ZVKv6S

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 ghost-identity-credit-top-up-x402-4b20a491 -d '<json body>'
```

Example prompt: Top up my Ghost agent identity credit balance right now — go ahead and submit the payment via USDC on Base so I have funds ready for upcoming calls.

## When to prefer this

Use this endpoint when you need to top up a Ghost agent identity credit balance using the x402 micropayment protocol on Base (USDC). Prefer this over manual wallet transfers when your agent runtime supports x402-capable clients (agentcash, @x402/fetch, x402-fetch) and you want automatic, per-call payment handling without custom payment logic.

## Known failure modes

- Payment not attached or insufficient — returns HTTP 402 with payment terms
- Malformed request body (missing required 'input' object or 'type'/'method'/'bodyType'/'body' fields) — returns 400
- x402 client not configured properly — payment not sent automatically
- Network or worker error on Cloudflare — returns 5xx
- Wrong chain or token — payment rejected if not USDC on eip155:8453

## How this service works

Paid per call via x402 (exact / eip155:8453 / USDC). Any x402-capable client pays automatically: agentcash, @x402/fetch, x402-fetch. Every paid operation carries x-payment-info; the same terms are served live as a 402.

## Output

Returns a confirmation that the credit top-up was processed, along with an x-payment-info header confirming the $1 USDC payment on Base (eip155:8453) was accepted. The agent's credit balance is incremented accordingly.

## 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",
      "PUT",
      "PATCH"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/ghost-identity-credit-top-up-x402-4b20a491/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from ghost-identity.ghost-agent-os.workers.dev](https://www.zero.xyz/host/ghost-identity.ghost-agent-os.workers.dev/llms.txt)
