# MapleAI GPT Chat Completions API (x402 Pay-Per-Request)

> MapleAI GPT Chat Completions API (x402 Pay-Per-Request) is a paid API for AI agents from base.mapleai.shop, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-02).

Provides OpenAI-compatible chat completions using four GPT models (GPT-5.6 Sol, GPT-5.6 Terra, GPT-6 Luna, GPT-6 Sol) with per-request USDC micropayment via x402 on Base.

## Facts

- Endpoint: POST https://base.mapleai.shop/api/v1/chat/completions?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/mapleai-gpt-chat-completions-api-x402-pay-per-request-c2190527
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ydeCGKRVU0uIGUezaDGyG

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 mapleai-gpt-chat-completions-api-x402-pay-per-request-c2190527 -d '<json body>'
```

Example prompt: Using MapleAI's GPT-6 Luna model, send this conversation — system: 'You are a helpful coding assistant', user: 'Write a Python function that reverses a linked list' — and give me the response, up to 512 tokens.

## When to prefer this

Choose this endpoint when you need OpenAI-compatible chat completions with no monthly subscription, paying only $0.01 USDC per call via the x402 protocol on Base. Ideal for infrequent or bursty workloads, agent pipelines needing crypto-native billing, or developers wanting to experiment with GPT-5.6 and GPT-6 model tiers without committing to a plan. Prefer over standard OpenAI API when you need USDC micropayment billing or want to avoid API key subscription overhead.

## Known failure modes

- Payment failure: x402 payment not processed or insufficient USDC balance — request rejected before completion
- Invalid model ID: model string not found in /v1/models — returns error response
- Malformed messages array: missing required 'role' or 'content' fields — validation error
- max_tokens too low for the prompt context — truncated or empty response
- Rate limiting or capacity issues on MapleAI infrastructure — 503 or timeout
- Network failure on Base blockchain payment settlement — request not fulfilled

## How this service works

OpenAI-compatible chat completion, priced by counted input tokens + max output tokens at per-model rates

## Output

Returns an OpenAI-compatible chat completion JSON object containing a unique completion ID, the model used, the assistant's reply message, the finish reason (e.g. 'stop'), and the choice index. The content field holds the generated text response.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string",
   "description": "Model ID from GET /v1/models"
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "role",
     "content"
    ],
    "properties": {
     "role": {
      "enum": [
       "system",
       "user",
       "assistant",
       "tool"
      ],
      "type": "string"
     },
     "content": {
      "type": "string"
     }
    }
   }
  },
  "max_tokens": {
   "type": "integer",
   "minimum": 1
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "id": "chatcmpl_example",
  "object": "chat.completion",
  "choices": [
   {
    "index": 0,
    "message": {
     "role": "assistant",
     "content": "Hello!"
    },
    "finish_reason": "stop"
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/mapleai-gpt-chat-completions-api-x402-pay-per-request-c2190527/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from base.mapleai.shop](https://www.zero.xyz/host/base.mapleai.shop/llms.txt)
