Public API

Developer API

Free public REST API with data on 200+ AI models. No authentication, no abusive rate limits, updated daily.

Free
No authentication
1h cache
CORS enabled
CC-BY Attribution

Base URL

https://swen.live

All endpoints accept GET. Responses in JSON with Content-Type: application/json. CORS open for any origin.

Endpoints

GET/api/benchmark

Returns all active models with benchmark data, pricing and capabilities.

Example Response

{
  "meta": {
    "source": "SWEN.AI",
    "url": "https://swen.live/benchmark",
    "methodology": "https://swen.live/benchmark/metodologia",
    "total_models": 212,
    "total_benchmarks": 1847,
    "updated_at": "2026-05-07T14:00:00.000Z",
    "license": "Data aggregated from LMArena, Artificial Analysis, OpenRouter."
  },
  "data": [
    {
      "slug": "gpt-4o",
      "name": "GPT-4o",
      "company": "OpenAI",
      "type": "chat",
      "pricing": {
        "input_per_1m_tokens_usd": 2.5,
        "output_per_1m_tokens_usd": 10.0
      },
      "context_window": 128000,
      "capabilities": {
        "open_source": false,
        "multimodal": true,
        "reasoning": false,
        "tool_calling": true,
        "vision": true,
        "audio": true
      },
      "performance": {
        "tokens_per_second": 98,
        "ttft_ms": 420
      },
      "release_date": "2024-05-13",
      "benchmarks": [
        {
          "benchmark": "Chatbot Arena ELO",
          "category": "overall",
          "score": 1287,
          "max_score": null
        }
      ],
      "url": "https://swen.live/benchmark/gpt-4o"
    }
  ]
}
GET/api/benchmark/rankings

Returns all published editorial rankings (Top 5 by task, best value-for-money, etc.).

Example Response

{
  "meta": {
    "source": "SWEN.AI",
    "total_rankings": 12,
    "updated_at": "2026-05-07T14:00:00.000Z",
    "license": "CC BY 4.0 — Attribution required."
  },
  "data": [
    {
      "slug": "melhores-llms-2026",
      "title": "Melhores LLMs de 2026",
      "subtitle": "O ranking definitivo dos modelos mais capazes",
      "category": "geral",
      "models": [...],
      "url": "https://swen.live/benchmark/ranking/melhores-llms-2026"
    }
  ]
}
GET/api/benchmark/ptbr

Exclusive Brazilian Portuguese proficiency benchmark. Model ranking by average PT-BR score per category.

Example Response

{
  "meta": {
    "source": "SWEN.AI",
    "description": "Benchmark exclusivo de proficiência em português brasileiro (PT/BR) para LLMs.",
    "total_models": 10,
    "total_questions": 20,
    "categories": { "gramática": 4, "compreensão": 6, "geração": 5, "raciocínio": 5 },
    "updated_at": "2026-05-07T14:00:00.000Z"
  },
  "data": [
    {
      "rank": 1,
      "slug": "anthropic-claude-opus-4-7",
      "name": "Claude Opus 4.7",
      "company": "Anthropic",
      "avg_score": 91.4,
      "total_tests": 20,
      "url": "https://swen.live/benchmark/anthropic-claude-opus-4-7"
    }
  ]
}

Model Fields

FieldTypeDescription
slugstringURL identifier for the model (e.g. gpt-4o)
namestringCommercial name of the model
companystringDeveloper company
typestring"chat", "embedding", "image", etc.
pricing.input_per_1m_tokens_usdnumber | nullPrice per 1M input tokens in USD
pricing.output_per_1m_tokens_usdnumber | nullPrice per 1M output tokens in USD
context_windownumber | nullContext window in tokens
capabilities.open_sourcebooleanWhether model weights are public
capabilities.multimodalbooleanSupports multiple modalities
capabilities.reasoningbooleanReasoning model (extended chain-of-thought)
capabilities.tool_callingbooleanSupports function/tool calling
capabilities.visionbooleanSupports image analysis
performance.tokens_per_secondnumber | nullMeasured inference speed
performance.ttft_msnumber | nullTime to First Token in milliseconds
release_datestring | nullRelease date (ISO 8601)
benchmarksarrayList of benchmark results for the model
urlstringURL of the benchmark page on SWEN

Usage Examples

Python
import requests

response = requests.get("https://swen.live/api/benchmark")
data = response.json()

models = data["data"]
print(f"Total de modelos: {data['meta']['total_models']}")

# Filtrar modelos open-source
open_source = [m for m in models if m["capabilities"]["open_source"]]
print(f"\nModelos open-source: {len(open_source)}")

# Top 5 por ELO
def get_elo(model):
    for b in model.get("benchmarks", []):
        if b["benchmark"] == "Chatbot Arena ELO":
            return b["score"]
    return 0

top5 = sorted(models, key=get_elo, reverse=True)[:5]
for m in top5:
    print(f"  {m['name']} (ELO: {get_elo(m)})")
JavaScript
const response = await fetch("https://swen.live/api/benchmark");
const { meta, data: models } = await response.json();

console.log(`Total de modelos: ${meta.total_models}`);

// Modelos com preço abaixo de $1/1M tokens
const baratos = models.filter(
  m => m.pricing.input_per_1m_tokens_usd !== null
    && m.pricing.input_per_1m_tokens_usd < 1
);
console.log(`Modelos abaixo de $1/1M: ${baratos.length}`);

// Ordenar por velocidade
const rapidos = [...models]
  .filter(m => m.performance.tokens_per_second)
  .sort((a, b) =>
    b.performance.tokens_per_second - a.performance.tokens_per_second
  )
  .slice(0, 5);

console.log("Top 5 mais rápidos:");
rapidos.forEach(m =>
  console.log(`  ${m.name}: ${m.performance.tokens_per_second} tok/s`)
);
cURL
# Todos os modelos
curl https://swen.live/api/benchmark

# Com jq — listar nomes e preços
curl -s https://swen.live/api/benchmark | \
  jq '.data[] | {name, company, input: .pricing.input_per_1m_tokens_usd}'

# Apenas open-source
curl -s https://swen.live/api/benchmark | \
  jq '[.data[] | select(.capabilities.open_source == true) | {name, company}]'

Limits & Fair Use

Cache: Responses are cached for 1 hour on Vercel servers. No need to poll more frequently than that.

Rate limit: No explicit rate limit for reasonable use. If your app makes more than 100 requests/hour, consider caching locally.

License: Data requires attribution to SWEN and primary sources (LMArena, Artificial Analysis, OpenRouter). Commercial use permitted with attribution.

Attribution: When using the data, include: "Data via SWEN (swen.live/benchmark)"

SLA: API provided without uptime guarantee. For production-critical use, we recommend caching data locally.

About the Data

Benchmark data is collected from primary sources: LMArena (Chatbot Arena ELO), Artificial Analysis (Intelligence Index, speed, latency), OpenRouter (real-time pricing) and our own measurements. Data is updated daily. See the full methodology for details on collection, normalization and inclusion criteria.

Explore the data: