ai_chat
Cheap LLM chat completion (flat $0.002). One-shot LLM completion for agents: send a prompt (and optional system message), get the answer text. Flat $0.002 per call, no account or API key; cheaper than typical x402 chat proxies. Up to ~2,000 chars of prompt and 600 output tokens. GET or POST JSON {prompt, system}. Example output: {"model":"gpt-5-nano","text":"bullish","usage":{"promptTokens":30,"completionTokens":2}}. Price: $0.002 USDC on Base via x402 (pass the payment in _meta["x402/payment"]).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | User prompt (max 2000 chars) | |
| system | No | Optional system message (max 1000 chars) | |
| max_tokens | No | Max output tokens, 16-600 (default 400) |