# Telnyx x402 Gateway – Llama 3.1 70B Chat Completions

> Telnyx x402 Gateway – Llama 3.1 70B Chat Completions is a paid API for AI agents from x402.telnyx.com, paid per call via x402, $0.007016/call, status unknown (last checked 2026-10-10).

Send an OpenAI-compatible chat completion request to Meta Llama 3.1 70B Instruct, paid per-call in USDC via the x402 protocol on Telnyx infrastructure.

## Facts

- Endpoint: POST https://x402.telnyx.com/v1/chat/completions/_t/llama-3.1-70b?utm_source=zero.xyz
- Price: $0.007016/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-10
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/telnyx-x402-gateway-llama-3-1-70b-chat-completions-a5d49c6b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_hqPNcsawFFSVgKdQ2d51k

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 telnyx-x402-gateway-llama-3-1-70b-chat-completions-a5d49c6b -d '<json body>'
```

Example prompt: Ask Llama 3.1 70B via Telnyx to explain the difference between supervised and unsupervised learning in three sentences, keeping the response under 200 tokens and temperature at 0.7, and pay for it per-call with USDC.

## When to prefer this

Choose this endpoint when you need OpenAI-compatible Llama 3.1 70B inference with pay-per-call USDC billing via x402, avoiding monthly subscriptions or API key management. It is ideal for agents or pipelines that require metered, on-chain-accountable LLM calls, especially when integrating with Coinbase-ecosystem or x402-aware infrastructure. Prefer it over standard Telnyx API auth flows when you want trustless per-request micropayments rather than pre-paid credits.

## Known failure modes

- Insufficient USDC balance or failed x402 payment results in 402 Payment Required
- Exceeding max_tokens limit (>1024) or message count (>32) triggers 422 validation error
- Content exceeding 8000 characters per message causes request rejection
- Invalid or missing required 'messages' array returns a 400 Bad Request
- Model overload or Telnyx infrastructure issues may cause 503 or timeout responses

## How this service works

Pay USDC per request for Telnyx Inference and Audio (text-to-speech, speech-to-text) through x402.

## Output

Returns an OpenAI-compatible chat.completion JSON object containing the assistant's generated message, finish reason (e.g. 'stop'), token usage breakdown (prompt, completion, total), a unique completion ID, and the object type field.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "n": {
   "type": "integer",
   "const": 1,
   "description": "Fixed to one completion per paid call."
  },
  "model": {
   "type": "string",
   "const": "meta-llama/Meta-Llama-3.1-70B-Instruct",
   "description": "Model identifier; fixed to meta-llama/Meta-Llama-3.1-70B-Instruct on this route."
  },
  "tools": {
   "type": "array",
   "items": {
    "type": "object"
   },
   "maxItems": 16
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "role",
     "content"
    ],
    "properties": {
     "role": {
      "enum": [
       "system",
       "user",
       "assistant",
       "tool"
      ],
      "type": "string"
     },
     "content": {
      "type": "string",
      "maxLength": 8000
     }
    }
   },
   "maxItems": 32,
   "description": "OpenAI-style chat messages."
  },
  "max_tokens": {
   "type": "integer",
   "maximum": 1024,
   "minimum": 1
  },
  "temperature": {
   "type": "number",
   "maximum": 2,
   "minimum": 0
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "id": "chatcmpl-xxx",
  "usage": {
   "total_tokens": 16,
   "prompt_tokens": 12,
   "completion_tokens": 4
  },
  "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/telnyx-x402-gateway-llama-3-1-70b-chat-completions-a5d49c6b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.telnyx.com](https://www.zero.xyz/host/x402.telnyx.com/llms.txt)
