Skip to main content

1. Check API status

curl https://api.naos.trade/api/health
{
  "success": true,
  "status": "ok",
  "service": "naos-trade-api",
  "region": "EU"
}

2. Get an API key

Get your API key at naos.trade. All authenticated endpoints require it in the Authorization header.

3. Verify your key

Call GET /api/v1/chains to verify your key works:
curl "https://api.naos.trade/api/v1/chains" \
  -H "Authorization: Bearer YOUR_API_KEY"

4. First token lookup

Look up a token to confirm everything is working:
curl "https://api.naos.trade/api/v1/token-info?token=0x833589fcd6edb6e08f4c7c32d4f71b54bda02913&chain=BASE" \
  -H "Authorization: Bearer YOUR_API_KEY"

Setup helper

Reusable TypeScript setup for the following guides:
import { ethers, parseUnits } from 'ethers'

const API = 'https://api.naos.trade'
const KEY = process.env.NAOS_API_KEY!
const NATIVE = '0x0000000000000000000000000000000000000000'

async function api<T>(path: string, init?: RequestInit): Promise<T> {
  const res = await fetch(`${API}${path}`, {
    ...init,
    headers: { 'Authorization': `Bearer ${KEY}`, 'Content-Type': 'application/json', ...init?.headers }
  })
  return res.json() as Promise<T>
}