> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stigg.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Supported providers and gateways

> Which LLM providers and gateways the Stigg Agent SDK wraps, and what it meters on each.

<CardGroup cols={2}>
  <Card title="Anthropic" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#D97757"/><g fill="#ffffff" transform="translate(7.04 7.04) scale(0.7467)"><path d="M17.3041 3.541h-3.6718l6.696 16.918H24Zm-10.6082 0L0 20.459h3.7442l1.3693-3.5527h7.0052l1.3693 3.5528h3.7442L10.5363 3.5409Zm-.3712 10.2232 2.2914-5.9456 2.2914 5.9456Z"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/anthropic">
    Messages API, streaming included, with the full prompt-caching breakdown
  </Card>

  <Card title="OpenAI" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#000000"/><g fill="#ffffff" transform="translate(7.04 7.04) scale(0.7467)"><path d="M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364 15.1192 7.2a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.407-.667zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/openai">
    Chat Completions and Responses API, streaming included
  </Card>

  <Card title="Google Gemini" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#4285F4"/><path fill="#ffffff" d="M16 6c0 5.523 4.477 10 10 10-5.523 0-10 4.477-10 10 0-5.523-4.477-10-10-10 5.523 0 10-4.477 10-10z"/></svg>} href="/documentation/ai-agents/llm-wrappers/providers/gemini">
    One-shot calls and chats, streaming included, with thinking tokens reported separately
  </Card>

  <Card title="OpenRouter" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#6467F2"/><g fill="#ffffff" transform="translate(7.04 7.04) scale(0.7467)"><path d="M16.804 1.957l7.22 4.105v.087L16.73 10.21l.017-2.117-.821-.03c-1.059-.028-1.611.002-2.268.11-1.064.175-2.038.577-3.147 1.352L8.345 11.03c-.284.195-.495.336-.68.455l-.515.322-.397.234.385.23.53.338c.476.314 1.17.796 2.701 1.866 1.11.775 2.083 1.177 3.147 1.352l.3.045c.694.091 1.375.094 2.825.033l.022-2.159 7.22 4.105v.087L16.589 22l.014-1.862-.635.022c-1.386.042-2.137.002-3.138-.162-1.694-.28-3.26-.926-4.881-2.059l-2.158-1.5a21.997 21.997 0 00-.755-.498l-.467-.28a55.927 55.927 0 00-.76-.43C2.908 14.73.563 14.116 0 14.116V9.888l.14.004c.564-.007 2.91-.622 3.809-1.124l1.016-.58.438-.274c.428-.28 1.072-.726 2.686-1.853 1.621-1.133 3.186-1.78 4.881-2.059 1.152-.19 1.974-.213 3.814-.138l.02-1.907z"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/openrouter">
    Gateway: bills the credits actually charged and the model that actually served, through the OpenRouter or OpenAI client
  </Card>

  <Card title="LiteLLM Proxy" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#1F2937"/><text x="50%" y="50%" dy="0.35em" fill="#ffffff" fontFamily="Arial, sans-serif" fontSize="15" fontWeight="600" textAnchor="middle">L</text></svg>} href="/documentation/ai-agents/llm-wrappers/providers/litellm">
    Self-hosted or cloud gateway: bills the cost LiteLLM computed for each call
  </Card>

  <Card title="Groq" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#F55036"/><g fill="#ffffff" fillRule="evenodd" transform="translate(7.04 7.04) scale(0.7467)"><path d="M12.036 2c-3.853-.035-7 3-7.036 6.781-.035 3.782 3.055 6.872 6.908 6.907h2.42v-2.566h-2.292c-2.407.028-4.38-1.866-4.408-4.23-.029-2.362 1.901-4.298 4.308-4.326h.1c2.407 0 4.358 1.915 4.365 4.278v6.305c0 2.342-1.944 4.25-4.323 4.279a4.375 4.375 0 01-3.033-1.252l-1.851 1.818A7 7 0 0012.029 22h.092c3.803-.056 6.858-3.083 6.879-6.816v-6.5C18.907 4.963 15.817 2 12.036 2z"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/groq">
    Groq's own client or the OpenAI client, reported under Groq's own event name
  </Card>

  <Card title="Mistral" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#FA520F"/><g fill="#ffffff"><rect x="8.0" y="8.0" width="3.2" height="3.2"/><rect x="20.8" y="8.0" width="3.2" height="3.2"/><rect x="8.0" y="11.2" width="3.2" height="3.2"/><rect x="11.2" y="11.2" width="3.2" height="3.2"/><rect x="17.6" y="11.2" width="3.2" height="3.2"/><rect x="20.8" y="11.2" width="3.2" height="3.2"/><rect x="8.0" y="14.4" width="3.2" height="3.2"/><rect x="11.2" y="14.4" width="3.2" height="3.2"/><rect x="14.4" y="14.4" width="3.2" height="3.2"/><rect x="17.6" y="14.4" width="3.2" height="3.2"/><rect x="20.8" y="14.4" width="3.2" height="3.2"/><rect x="8.0" y="17.6" width="3.2" height="3.2"/><rect x="14.4" y="17.6" width="3.2" height="3.2"/><rect x="20.8" y="17.6" width="3.2" height="3.2"/><rect x="8.0" y="20.8" width="3.2" height="3.2"/><rect x="20.8" y="20.8" width="3.2" height="3.2"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/mistral">
    Chat, fill-in-the-middle and agent calls, streaming included
  </Card>

  <Card title="Ollama" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#000000"/><g fill="#ffffff" fillRule="evenodd" transform="translate(7.04 7.04) scale(0.7467)"><path d="M7.905 1.09c.216.085.411.225.588.41.295.306.544.744.734 1.263.191.522.315 1.1.362 1.68a5.054 5.054 0 012.049-.636l.051-.004c.87-.07 1.73.087 2.48.474.101.053.2.11.297.17.05-.569.172-1.134.36-1.644.19-.52.439-.957.733-1.264a1.67 1.67 0 01.589-.41c.257-.1.53-.118.796-.042.401.114.745.368 1.016.737.248.337.434.769.561 1.287.23.934.27 2.163.115 3.645l.053.04.026.019c.757.576 1.284 1.397 1.563 2.35.435 1.487.216 3.155-.534 4.088l-.018.021.002.003c.417.762.67 1.567.724 2.4l.002.03c.064 1.065-.2 2.137-.814 3.19l-.007.01.01.024c.472 1.157.62 2.322.438 3.486l-.006.039a.651.651 0 01-.747.536.648.648 0 01-.54-.742c.167-1.033.01-2.069-.48-3.123a.643.643 0 01.04-.617l.004-.006c.604-.924.854-1.83.8-2.72-.046-.779-.325-1.544-.8-2.273a.644.644 0 01.18-.886l.009-.006c.243-.159.467-.565.58-1.12a4.229 4.229 0 00-.095-1.974c-.205-.7-.58-1.284-1.105-1.683-.595-.454-1.383-.673-2.38-.61a.653.653 0 01-.632-.371c-.314-.665-.772-1.141-1.343-1.436a3.288 3.288 0 00-1.772-.332c-1.245.099-2.343.801-2.67 1.686a.652.652 0 01-.61.425c-1.067.002-1.893.252-2.497.703-.522.39-.878.935-1.066 1.588a4.07 4.07 0 00-.068 1.886c.112.558.331 1.02.582 1.269l.008.007c.212.207.257.53.109.785-.36.622-.629 1.549-.673 2.44-.05 1.018.186 1.902.719 2.536l.016.019a.643.643 0 01.095.69c-.576 1.236-.753 2.252-.562 3.052a.652.652 0 01-1.269.298c-.243-1.018-.078-2.184.473-3.498l.014-.035-.008-.012a4.339 4.339 0 01-.598-1.309l-.005-.019a5.764 5.764 0 01-.177-1.785c.044-.91.278-1.842.622-2.59l.012-.026-.002-.002c-.293-.418-.51-.953-.63-1.545l-.005-.024a5.352 5.352 0 01.093-2.49c.262-.915.777-1.701 1.536-2.269.06-.045.123-.09.186-.132-.159-1.493-.119-2.73.112-3.67.127-.518.314-.95.562-1.287.27-.368.614-.622 1.015-.737.266-.076.54-.059.797.042zm4.116 9.09c.936 0 1.8.313 2.446.855.63.527 1.005 1.235 1.005 1.94 0 .888-.406 1.58-1.133 2.022-.62.375-1.451.557-2.403.557-1.009 0-1.871-.259-2.493-.734-.617-.47-.963-1.13-.963-1.845 0-.707.398-1.417 1.056-1.946.668-.537 1.55-.849 2.485-.849zm0 .896a3.07 3.07 0 00-1.916.65c-.461.37-.722.835-.722 1.25 0 .428.21.829.61 1.134.455.347 1.124.548 1.943.548.799 0 1.473-.147 1.932-.426.463-.28.7-.686.7-1.257 0-.423-.246-.89-.683-1.256-.484-.405-1.14-.643-1.864-.643zm.662 1.21l.004.004c.12.151.095.37-.056.49l-.292.23v.446a.375.375 0 01-.376.373.375.375 0 01-.376-.373v-.46l-.271-.218a.347.347 0 01-.052-.49.353.353 0 01.494-.051l.215.172.22-.174a.353.353 0 01.49.051zm-5.04-1.919c.478 0 .867.39.867.871a.87.87 0 01-.868.871.87.87 0 01-.867-.87.87.87 0 01.867-.872zm8.706 0c.48 0 .868.39.868.871a.87.87 0 01-.868.871.87.87 0 01-.867-.87.87.87 0 01.867-.872zM7.44 2.3l-.003.002a.659.659 0 00-.285.238l-.005.006c-.138.189-.258.467-.348.832-.17.692-.216 1.631-.124 2.782.43-.128.899-.208 1.404-.237l.01-.001.019-.034c.046-.082.095-.161.148-.239.123-.771.022-1.692-.253-2.444-.134-.364-.297-.65-.453-.813a.628.628 0 00-.107-.09L7.44 2.3zm9.174.04l-.002.001a.628.628 0 00-.107.09c-.156.163-.32.45-.453.814-.29.794-.387 1.776-.23 2.572l.058.097.008.014h.03a5.184 5.184 0 011.466.212c.086-1.124.038-2.043-.128-2.722-.09-.365-.21-.643-.349-.832l-.004-.006a.659.659 0 00-.285-.239h-.004z"/></g></svg>} href="/documentation/ai-agents/llm-wrappers/providers/ollama">
    Models you host yourself: meter and limit your own capacity
  </Card>

  <Card title="Amazon Bedrock" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#01A88D"/><text x="50%" y="50%" dy="0.35em" fill="#ffffff" fontFamily="Arial, sans-serif" fontSize="15" fontWeight="600" textAnchor="middle">B</text></svg>} href="/documentation/ai-agents/llm-wrappers/providers/bedrock">
    Gateway: the Converse API, for every model Bedrock serves
  </Card>

  <Card title="TypeSafe" icon={<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg"><rect width="32" height="32" rx="8" fill="#0E7C66"/><text x="50%" y="50%" dy="0.35em" fill="#ffffff" fontFamily="Arial, sans-serif" fontSize="15" fontWeight="600" textAnchor="middle">T</text></svg>} href="/documentation/ai-agents/llm-wrappers/providers/typesafe">
    Typed question answering through the TypeSafe client
  </Card>
</CardGroup>

**Also works with any OpenAI-compatible endpoint**, through the OpenAI client:

<div style={{display: "flex", flexWrap: "wrap", gap: "10px", marginTop: "8px"}}>
  <a href="/documentation/ai-agents/llm-wrappers/providers/together" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><g><path d="M17.385 11.23a4.615 4.615 0 100-9.23 4.615 4.615 0 000 9.23zm0 10.77a4.615 4.615 0 100-9.23 4.615 4.615 0 000 9.23zm-10.77 0a4.615 4.615 0 100-9.23 4.615 4.615 0 000 9.23z" opacity=".2" /><circle cx="6.615" cy="6.615" r="4.615" /></g></svg>Together AI</span></a>
  <a href="/documentation/ai-agents/llm-wrappers/providers/fireworks" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path clipRule="evenodd" d="M14.8 5l-2.801 6.795L9.195 5H7.397l3.072 7.428a1.64 1.64 0 003.038.002L16.598 5H14.8zm1.196 10.352l5.124-5.244-.699-1.669-5.596 5.739a1.664 1.664 0 00-.343 1.807 1.642 1.642 0 001.516 1.012L16 17l8-.02-.699-1.669-7.303.041h-.002zM2.88 10.104l.699-1.669 5.596 5.739c.468.479.603 1.189.343 1.807a1.643 1.643 0 01-1.516 1.012l-8-.018-.002.002.699-1.669 7.303.042-5.122-5.246z" /></svg>Fireworks AI</span></a>
  <a href="/documentation/ai-agents/llm-wrappers/providers/deepseek" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M23.748 4.482c-.254-.124-.364.113-.512.234-.051.039-.094.09-.137.136-.372.397-.806.657-1.373.626-.829-.046-1.537.214-2.163.848-.133-.782-.575-1.248-1.247-1.548-.352-.156-.708-.311-.955-.65-.172-.241-.219-.51-.305-.774-.055-.16-.11-.323-.293-.35-.2-.031-.278.136-.356.276-.313.572-.434 1.202-.422 1.84.027 1.436.633 2.58 1.838 3.393.137.093.172.187.129.323-.082.28-.18.552-.266.833-.055.179-.137.217-.329.14a5.526 5.526 0 01-1.736-1.18c-.857-.828-1.631-1.742-2.597-2.458a11.365 11.365 0 00-.689-.471c-.985-.957.13-1.743.388-1.836.27-.098.093-.432-.779-.428-.872.004-1.67.295-2.687.684a3.055 3.055 0 01-.465.137 9.597 9.597 0 00-2.883-.102c-1.885.21-3.39 1.102-4.497 2.623C.082 8.606-.231 10.684.152 12.85c.403 2.284 1.569 4.175 3.36 5.653 1.858 1.533 3.997 2.284 6.438 2.14 1.482-.085 3.133-.284 4.994-1.86.47.234.962.327 1.78.397.63.059 1.236-.03 1.705-.128.735-.156.684-.837.419-.961-2.155-1.004-1.682-.595-2.113-.926 1.096-1.296 2.746-2.642 3.392-7.003.05-.347.007-.565 0-.845-.004-.17.035-.237.23-.256a4.173 4.173 0 001.545-.475c1.396-.763 1.96-2.015 2.093-3.517.02-.23-.004-.467-.247-.588zM11.581 18c-2.089-1.642-3.102-2.183-3.52-2.16-.392.024-.321.471-.235.763.09.288.207.486.371.739.114.167.192.416-.113.603-.673.416-1.842-.14-1.897-.167-1.361-.802-2.5-1.86-3.301-3.307-.774-1.393-1.224-2.887-1.298-4.482-.02-.386.093-.522.477-.592a4.696 4.696 0 011.529-.039c2.132.312 3.946 1.265 5.468 2.774.868.86 1.525 1.887 2.202 2.891.72 1.066 1.494 2.082 2.48 2.914.348.292.625.514.891.677-.802.09-2.14.11-3.054-.614zm1-6.44a.306.306 0 01.415-.287.302.302 0 01.2.288.306.306 0 01-.31.307.303.303 0 01-.304-.308zm3.11 1.596c-.2.081-.399.151-.59.16a1.245 1.245 0 01-.798-.254c-.274-.23-.47-.358-.552-.758a1.73 1.73 0 01.016-.588c.07-.327-.008-.537-.239-.727-.187-.156-.426-.199-.688-.199a.559.559 0 01-.254-.078c-.11-.054-.2-.19-.114-.358.028-.054.16-.186.192-.21.356-.202.767-.136 1.146.016.352.144.618.408 1.001.782.391.451.462.576.685.914.176.265.336.537.445.848.067.195-.019.354-.25.452z" /></svg>DeepSeek</span></a>
  <a href="/documentation/ai-agents/llm-wrappers/providers/xai" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M6.469 8.776L16.512 23h-4.464L2.005 8.776H6.47zm-.004 7.9l2.233 3.164L6.467 23H2l4.465-6.324zM22 2.582V23h-3.659V7.764L22 2.582zM22 1l-9.952 14.095-2.233-3.163L17.533 1H22z" /></svg>xAI</span></a>
  <a href="/documentation/ai-agents/llm-wrappers/providers/perplexity" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M19.785 0v7.272H22.5V17.62h-2.935V24l-7.037-6.194v6.145h-1.091v-6.152L4.392 24v-6.465H1.5V7.188h2.884V0l7.053 6.494V.19h1.09v6.49L19.786 0zm-7.257 9.044v7.319l5.946 5.234V14.44l-5.946-5.397zm-1.099-.08l-5.946 5.398v7.235l5.946-5.234V8.965zm8.136 7.58h1.844V8.349H13.46l6.105 5.54v2.655zm-8.982-8.28H2.59v8.195h1.8v-2.576l6.192-5.62zM5.475 2.476v4.71h5.115l-5.115-4.71zm13.219 0l-5.115 4.71h5.115v-4.71z" /></svg>Perplexity</span></a>
  <a href="/documentation/ai-agents/llm-wrappers/providers/vllm" style={{textDecoration: "none", color: "inherit"}}><span style={{display: "inline-flex", alignItems: "center", gap: "8px", padding: "6px 12px", border: "1px solid rgba(127, 127, 127, 0.25)", borderRadius: "999px", fontSize: "14px"}}><svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" fillRule="evenodd" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M0 4.973h9.324V23L0 4.973z" /><path d="M13.986 4.351L22.378 0l-6.216 23H9.324l4.662-18.649z" /></svg>vLLM</span></a>
</div>

[How OpenAI-compatible support works](/documentation/ai-agents/llm-wrappers/providers/openai-compatible)

`stigg.wrap(client)` recognizes each of these from the client object itself, so you do not name the vendor. Each provider's page shows how to wrap it and exactly what is reported.

## Why some vendors use the OpenAI client

Many vendors and gateways, including OpenRouter, LiteLLM Proxy, Groq, Mistral and Ollama, expose an API in **OpenAI's format**, and support calling it with OpenAI's `openai` client, alongside or instead of a client of their own. So you wrap an `OpenAI` client whose `baseURL` points at that vendor. Here `OpenAI` names the format of the API, not who you are calling or paying.

The SDK then picks the recipe from the address:

| The client points at | Recipe | Events | Reports |
| - | - | - | - |
| `openrouter.ai` | OpenRouter, selected automatically | `openrouter.*` | Tokens, `cost`, and the model that served |
| Your LiteLLM Proxy | LiteLLM, passed with your proxy's URL | `litellm.*` | Tokens, `cost`, and the model that served |
| `api.groq.com` | Groq, selected automatically | `groq.*` | Tokens |
| Anything else in OpenAI's format, including Mistral and Ollama | OpenAI | `openai.*` | Tokens |

Where a vendor has its own client, such as `@openrouter/sdk`, `groq-sdk`, `@mistralai/mistralai` or `ollama`, you can wrap that client instead. The SDK recognizes it by its shape.

## At a glance

| Provider | Event name | Metrics reported |
| - | - | - |
| [Anthropic](/documentation/ai-agents/llm-wrappers/providers/anthropic) | `anthropic.messages.create` | `input_tokens`, `output_tokens`, `cache_read_input_tokens`, `cache_creation_input_tokens`, `total_tokens` |
| [OpenAI](/documentation/ai-agents/llm-wrappers/providers/openai), Chat Completions | `openai.chat.completions.create` | `prompt_tokens`, `completion_tokens`, `cached_tokens`, `total_tokens` |
| [OpenAI](/documentation/ai-agents/llm-wrappers/providers/openai), Responses | `openai.responses.create` | `input_tokens`, `output_tokens`, `cached_tokens`, `total_tokens` |
| [Google Gemini](/documentation/ai-agents/llm-wrappers/providers/gemini) | `gemini.models.generateContent`, `gemini.models.generateContentStream` | `promptTokenCount`, `candidatesTokenCount`, `cachedContentTokenCount`, `thoughtsTokenCount`, `toolUsePromptTokenCount`, `totalTokenCount` |
| [Google Gemini](/documentation/ai-agents/llm-wrappers/providers/gemini), chats | `gemini.chats.sendMessage`, `gemini.chats.sendMessageStream` | The same as Gemini above |
| [Groq](/documentation/ai-agents/llm-wrappers/providers/groq) | `groq.chat.completions.create` | `prompt_tokens`, `completion_tokens`, `cached_tokens`, `total_tokens` |
| [Mistral](/documentation/ai-agents/llm-wrappers/providers/mistral) | `mistral.chat.complete`, `mistral.chat.stream`, `mistral.chat.parse`, `mistral.chat.parseStream`, `mistral.fim.complete`, `mistral.fim.stream`, `mistral.agents.complete`, `mistral.agents.stream` | `prompt_tokens`, `completion_tokens`, `total_tokens` |
| [Ollama](/documentation/ai-agents/llm-wrappers/providers/ollama) | `ollama.chat`, `ollama.generate` | `prompt_eval_count`, `eval_count`, `total_tokens` |
| [OpenRouter](/documentation/ai-agents/llm-wrappers/providers/openrouter), Chat Completions | `openrouter.chat.send`, `openrouter.chat.completions.create` | `prompt_tokens`, `completion_tokens`, `cached_tokens`, `total_tokens`, `cost` |
| [OpenRouter](/documentation/ai-agents/llm-wrappers/providers/openrouter), Responses | `openrouter.responses.send`, `openrouter.responses.create` | `input_tokens`, `output_tokens`, `cached_tokens`, `total_tokens`, `cost` |
| [LiteLLM Proxy](/documentation/ai-agents/llm-wrappers/providers/litellm), Chat Completions | `litellm.chat.completions.create` | `prompt_tokens`, `completion_tokens`, `cached_tokens`, `total_tokens`, `cost` (non-streaming calls only) |
| [LiteLLM Proxy](/documentation/ai-agents/llm-wrappers/providers/litellm), Responses | `litellm.responses.create` | `input_tokens`, `output_tokens`, `cached_tokens`, `total_tokens`, `cost` (non-streaming calls only) |
| [Amazon Bedrock](/documentation/ai-agents/llm-wrappers/providers/bedrock) | `bedrock.send` | `inputTokens`, `outputTokens`, `cacheReadInputTokens`, `cacheWriteInputTokens`, `totalTokens` |
| [TypeSafe](/documentation/ai-agents/llm-wrappers/providers/typesafe) | `typesafe.systemOne` | `input_tokens`, `output_tokens`, `total_tokens` |
| [OpenAI-compatible](/documentation/ai-agents/llm-wrappers/providers/openai-compatible) | `openai.chat.completions.create`, `openai.responses.create` | The same as OpenAI |

For any other vendor, including your own models, see [Bring your own vendor](/documentation/ai-agents/llm-wrappers/providers/custom).

## How usage is reported

* **Same names as the vendor.** Each metric keeps the name the vendor uses, such as `input_tokens` for Anthropic, `prompt_tokens` for OpenAI or `promptTokenCount` for Gemini. You can compare the numbers in Stigg directly with the vendor's own usage reports, such as its usage dashboard.
* **A total, and its parts.** Every vendor also reports a total: the vendor's own where it publishes one, such as `total_tokens` or `totalTokenCount`, and otherwise the sum of the parts, added up by the SDK (Anthropic, Ollama and TypeSafe). The total includes the other counters, so price the total or the parts, never both.
* **Every usage field, not just the named metrics.** Each event also includes every usage field the vendor returned, with a `raw.` prefix (`raw.<field name>`). If a vendor adds a field the SDK does not report as a metric yet, you can build a meter on it without waiting for an SDK update.
* **No prompts or responses.** Only usage numbers are sent to Stigg. The text of your prompts and the model's responses never leaves your application.


## Related topics

- [Gateways](/documentation/ai-agents/llm-wrappers/gateways.md)
- [LLM and gateway wrappers](/documentation/ai-agents/llm-wrappers/overview.md)
- [OpenAI](/documentation/ai-agents/llm-wrappers/providers/openai.md)
- [LiteLLM Proxy](/documentation/ai-agents/llm-wrappers/providers/litellm.md)
- [OpenAI-compatible endpoints](/documentation/ai-agents/llm-wrappers/providers/openai-compatible.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.