# Gambit Chat — Pay-per-call LLM via USDC on Base (x402)

> Gambit Chat — Pay-per-call LLM via USDC on Base (x402) is a paid API for AI agents from gambit.barrioenergy.com, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-13).

Sends a chat message to a GPU-hosted language model on Gambit, paid per-call with USDC on Base via the x402 protocol

## Facts

- Endpoint: POST https://gambit.barrioenergy.com/x402/chat
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/gambit-chat-pay-per-call-llm-via-usdc-on-base-x402-dde356d7
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_KqLJ8XHGhMFH_EB_0-jeU

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 gambit-chat-pay-per-call-llm-via-usdc-on-base-x402-dde356d7 -d '<json body>'
```

Example prompt: Ask Gambit's GPU-hosted Qwen model — paying $0.02 in USDC on Base — to explain the difference between proof-of-work and proof-of-stake in 3 sentences, using up to 300 tokens.

## When to prefer this

Choose this endpoint when you need a pay-per-call LLM inference endpoint that accepts USDC on Base via x402 — ideal for autonomous agents, bots, or scripts that need to avoid subscription management and prefer crypto micropayments. Prefer this over L402 Lightning endpoints if you already operate on Base/EVM. Avoid if you need streaming responses or guaranteed model availability at scale.

## Known failure modes

- 402 Payment Required if USDC payment on Base is not provided or insufficient
- Invalid model name returns an error or empty response
- Malformed messages array (missing role or content) causes a 400 error
- Max tokens exceeded or model unavailable may cause timeouts or errors
- Insufficient USDC balance on Base results in payment failure

## How this service works

Gambit GPU shop. Humans: /signup ($1 credit), X-API-Key on /v1/*, QR Lightning top-up. Bots: L402 Lightning (LIVE) on /l402/*, x402 USDC on Base on /x402/*, or POST /v1/register ($0) then POST /v1/topup/lightning. Handwritten letter POST /x402/letter at $25.00 USDC. Funnel https://gambit.barrioenergy.com. Free probe GET|POST /x402/models.

## Output

Returns a JSON object containing the model name and an assistant message object with role and content fields — the generated text response from the GPU-hosted LLM.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string"
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "role",
     "content"
    ],
    "properties": {
     "role": {
      "type": "string"
     },
     "content": {
      "type": "string"
     }
    }
   }
  },
  "max_tokens": {
   "type": "integer",
   "default": 512
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "model": "qwen3.6:35b-a3b",
  "message": {
   "role": "assistant",
   "content": "Hi."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/gambit-chat-pay-per-call-llm-via-usdc-on-base-x402-dde356d7/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from gambit.barrioenergy.com](https://www.zero.xyz/host/gambit.barrioenergy.com/llms.txt)
