For developers & agents

One tool call. Ranked routes. Transparent scoring.

Aggressive.ai exposes a public, JSON HTTP API that routes any AI task to the least-expensive model and provider clearing your quality, latency, privacy and tool-use thresholds. Wrap it as a tool inside any agent framework — OpenAI, Anthropic, LangGraph, Vercel AI SDK, custom orchestrators. The same engine powers the web UI; there is no second-tier surface for agents.

POST /api/public/optimize

Route a task end-to-end
POST /api/public/optimize
Content-Type: application/json

{
  "category": "agentic tool calling",
  "location": "EU",
  "minPerformance": 85,
  "maxMonthly": 400,
  "minRating": 4,
  "mode": "aggressive"
}

// category  → task type (RAG QA, code generation, summarisation, embeddings…)
// location  → data-residency region (EU, US, UK, global)
// minPerformance → quality floor, 0-100
// maxMonthly     → monthly inference spend ceiling
// minRating      → provider reliability floor, 0-5
{
  "taskSpec": { ... },
  "top": {
    "providerName": "Groq",
    "planName": "Llama 4 70B — production",
    "monthlyPrice": 148,
    "totalCost12mo": 1776,
    "performance": { "label": "quality 88 / p95 240ms" },
    "reviewRating": 4.6,
    "reviewCount": 6890,
    "friction": { "contractMonths": 0 },
    "score": {
      "price": 94, "performance": 92, "reviews": 88,
      "availability": 90, "frictionPenalty": 4,
      "aggressive": 88,
      "factors": ["Lowest cost per task at the quality floor", "p95 latency inside budget"]
    },
    "explanation": "Groq — Llama 4 70B scored 88/100 in aggressive mode..."
  },
  "offers": [ ... ],
  "pluginsUsed": [
    { "id": "live-model-price-index", "ok": true, "ms": 1820, "count": 8 },
    { "id": "provider-baseline-index", "ok": true, "ms": 30, "count": 8 }
  ]
}

GET /api/public/plugins

Discover available price sources
GET /api/public/plugins

→ {
  "plugins": [ { "id": "live-model-price-index", "category": "inference", "geography": "global", ... } ]
}

Tool definition for LLM agents

Drop into your function-calling spec
{
  "name": "route_ai_task",
  "description": "Given a task type and thresholds, returns ranked model+provider routes optimized for lowest cost that still clears quality, latency, privacy and tool-use requirements.",
  "input_schema": {
    "type": "object",
    "required": ["category"],
    "properties": {
      "category": { "type": "string", "description": "Task type: RAG QA, code generation, summarisation, classification, embeddings, agentic tool calling, transcription…" },
      "location": { "type": "string", "description": "Data-residency region: EU, US, UK, global" },
      "minPerformance": { "type": "number", "description": "Quality floor 0-100" },
      "maxMonthly": { "type": "number", "description": "Monthly inference spend ceiling" },
      "maxContractMonths": { "type": "number", "description": "Commitment tolerance; 0 = on-demand only" },
      "minRating": { "type": "number", "minimum": 0, "maximum": 5, "description": "Provider reliability floor" },
      "mode": { "type": "string", "enum": ["aggressive","balanced","premium"], "default": "aggressive" }
    }
  }
}

Routing modes

One knob, three behaviors
aggressive
Cost-first
Cost 55%, reliability 20%, quality 12%, switching friction -8%.
balanced
Balanced
Cost 30%, quality 25%, reliability 25%, friction -10%.
premium
Quality-first
Quality 50%, cost 15%, reliability 20%, friction -7%.

Resilient by design

Failover, cooldowns, observable

Routing decisions survive provider incidents: degraded or rate-limited endpoints are cooled down automatically and the request retries on the next best route inside your thresholds. Callers always get a JSON response or a clean error envelope, never a leaked upstream failure.

Indexable decision URLs

Every route becomes a shareable page

Every routing run produces a stable, SEO-friendly URL at /search/<slug> populated with the ranked shortlist, decision receipt and JSON-LD structured data. Share it, bookmark it, link to it — the page rebuilds the answer on demand from the slug.