# Model Access Gateway – Gemini 3.1 Pro Chat Completions (x402, USDC)

> Model Access Gateway – Gemini 3.1 Pro Chat Completions (x402, USDC) is a paid API for AI agents from modelaccessgateway.com, paid per call via x402, $0.0014/call, status unknown (last checked 2026-10-16).

Runs OpenAI-compatible chat completions against Google Gemini 3.1 Pro, billed per call in USDC on Base via x402 — no API key or account required.

## Facts

- Endpoint: POST https://modelaccessgateway.com/llm/gemini-3.1-pro?utm_source=zero.xyz
- Price: $0.0014/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/model-access-gateway-gemini-3-1-pro-chat-completions-x402-usdc-ccc1a251
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_MwUy-1yLfTpeEUzAPZbQo

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 model-access-gateway-gemini-3-1-pro-chat-completions-x402-usdc-ccc1a251 -d '<json body>'
```

Example prompt: Ask Gemini 3.1 Pro to write a detailed product description for a new ergonomic office chair aimed at remote workers, keeping the tone professional and the response under 300 words — pay for it with USDC on Base, no API key needed.

## When to prefer this

Choose this endpoint when you need Gemini 3.1 Pro specifically, want OpenAI-compatible request/response format, require no account or API key setup, and prefer crypto-native micropayments in USDC via x402 rather than monthly subscriptions. Ideal for autonomous agents that need to pay programmatically per inference call with automatic refund guarantees on failure.

## Known failure modes

- Model failure triggers automatic USDC refund to the caller's wallet
- Invalid or missing messages array returns a 400 validation error
- Payment insufficient or x402 handshake failure prevents inference from starting
- max_tokens exceeding 16384 returns a schema validation error
- Network timeout or model unavailability may return a 5xx error with no charge

## How this service works

LLM inference API: OpenAI-compatible chat completions for 136 AI models (Claude, GPT, Gemini, Grok, DeepSeek, Qwen, Kimi, GLM), paid per call in USDC on Base with x402. No account, no API key, automatic refund if the model fails.

## Output

Returns an OpenAI-compatible chat.completion JSON object containing the assistant's message content, finish reason (e.g. 'stop'), token usage breakdown (prompt, completion, total), model identifier ('google/gemini-3.1-pro'), and a unique completion ID. Streaming mode returns server-sent events instead.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string",
   "description": "Optional: fixed by the route (google/gemini-3.1-pro)"
  },
  "tools": {
   "type": "array"
  },
  "stream": {
   "type": "boolean",
   "description": "true: server-sent events after payment"
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "role"
    ],
    "properties": {
     "role": {
      "enum": [
       "system",
       "user",
       "assistant",
       "tool",
       "developer"
      ],
      "type": "string"
     },
     "content": {
      "type": [
       "string",
       "array",
       "null"
      ]
     }
    }
   },
   "minItems": 1
  },
  "max_tokens": {
   "type": "integer",
   "maximum": 16384,
   "minimum": 1,
   "description": "Optional, default 4096"
  },
  "temperature": {
   "type": "number",
   "maximum": 2,
   "minimum": 0
  },
  "response_format": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "id": "chatcmpl-7f3c2a91",
  "model": "google/gemini-3.1-pro",
  "usage": {
   "total_tokens": 10,
   "prompt_tokens": 9,
   "completion_tokens": 1
  },
  "object": "chat.completion",
  "choices": [
   {
    "index": 0,
    "message": {
     "role": "assistant",
     "content": "OK"
    },
    "finish_reason": "stop"
   }
  ],
  "created": 1791979200
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/model-access-gateway-gemini-3-1-pro-chat-completions-x402-usdc-ccc1a251/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from modelaccessgateway.com](https://www.zero.xyz/host/modelaccessgateway.com/llms.txt)
