Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.chat402.xyz/llms.txt

Use this file to discover all available pages before exploring further.

API Key Authentication

All API requests require an API key in the Authorization header.

Getting Your API Key

  1. Visit chat402.xyz
  2. Connect your wallet
  3. Go to API Keys page
  4. Click “Create New API Key”
  5. Copy and save the key (starts with pp_)

Using Your API Key

Include the API key in the Authorization header:
Authorization: Bearer pp_1234567890abcdef...

Example Request

curl -X POST https://api.chat402.xyz/api/v1/prompt \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"gpt-3.5-turbo","prompt":"Hello!"}'
Keep your API key secret! Anyone with your key can use your balance.