Skip to main content

Prerequisites

  • An agent whose budget admits the inference provider as a merchant. The default allow-all setting does; a budget restricted to a specific allowlist needs the provider added, or every call fails with payment_refused.
  • An API key for that agent. Mint one on the agent’s page. See Mint a key.

Choose a model

The Inference page lists the models the provider prices, grouped by what each produces into Text, Image, Video, Audio, and Other tabs. Text, image, video, and audio models are callable through the inference endpoint today; the other tab says its models are listed for pricing only. Each row shows the identifier to send as model, with a copy button, and the model’s display name when the provider publishes one that differs from the identifier, and its price in the unit the model is billed in: text models in USD per 1M tokens for input, output, cached input, and cache writes, with their context window and maximum output in tokens; image models per image; video models per second with any per-call surcharge and length limits; audio models per 1K characters, per track, or per generation, with their input and duration limits. A model priced by input length shows each tier’s price under the base price in each cell, with the input-token threshold it applies from, and a chip under its name naming the thresholds. A model with no charge is marked Free. Any other published price or limit shows as the provider published it. The page is public, and signed-in users reach it from the Inference entry in the sidebar. Agents read the same list from GET https://inference.agentic.anchorage.com/v1/models, with no API key. Each entry carries the identifier, the model’s owner in owned_by (the maker’s name, or anchorage when no maker is listed or the listed owner is the provider itself), and, where the provider publishes them, a display name, the context window and maximum output in tokens, category tags, a billing mode, and whether the model is currently available. Each entry also states which kind of model it is (chat, image, video, audio, or other), whether it is callable through the endpoint and, when it is, the endpoint path to send it to (for example /v1/chat/completions), whether it is free, and which of its pricing keys are limits rather than prices, so a client can pick a model without knowing the provider’s pricing shapes. Prices are decimal strings in the same units the page shows.

Set up the client

Point your OpenAI-compatible client at these values.
  • base_url is https://inference.agentic.anchorage.com/v1.
  • The API key is the agent’s API key, sent as the bearer token. The snippets read it from the AGENT_API_KEY environment variable.
  • model is an identifier from the model list, for example openai/gpt-4o-mini.
The Inference page’s How to connect card walks through these three values with ready-to-paste snippets for curl, Python, and TypeScript, naming a text model from the list. Each callable model table names the route its models are served on. Under the card, Connect your harness shows the block to add the endpoint as a custom provider in Hermes or in OpenClaw. The Agents page and each agent’s page link there with Set up inference.

Use Claude Code or an Anthropic SDK

Claude Code and an Anthropic SDK’s message-creation calls use POST /v1/messages, which speaks Anthropic’s Messages API. Point them at these values.
  • The base URL is https://inference.agentic.anchorage.com, without /v1. The client adds /v1/messages itself.
  • The API key is the agent’s API key. Send it the way the client normally sends an Anthropic key.
  • model is a Claude model’s identifier from the model list.
For Claude Code, set these environment variables before you start it:
Also set ANTHROPIC_MODEL and, for its background tasks, ANTHROPIC_DEFAULT_HAIKU_MODEL, each to a Claude model’s identifier from the list, so every call Claude Code makes names a model the list prices. For an SDK, pass the same two values as the client’s base_url (or baseURL) and api_key (or apiKey). Claude Code streams every response, and a streamed response is cut off after 120 seconds. Set CLAUDE_CODE_MAX_OUTPUT_TOKENS to keep long answers under that. A request body is limited to 1.5 MiB, which a long session or one with images can pass; run /compact to shrink it. See Anthropic Messages API for the headers it forwards and the error shape it returns.

Control repeat requests (optional)

Send an Idempotency-Key header to control whether a repeated request shares a charge or pays again. See Managing idempotency keys.

Raise your client’s timeout

Inference requests can take longer than expected. Before your request even reaches the provider, it has to authenticate, check your budget, and sign the payment. Give your client more than three minutes, so it doesn’t give up on a call you already paid for.

Ask for a typed judgment (free)

Send a yes/no, multiple-choice, or scored question about a piece of text to the same host, with the same API key. It isn’t billed.
See Typed judgments for the question types, limits, and errors. To generate an image or a video instead, see Generate an image or video. For speech, sound effects, or music, see Generate speech, sound effects, or music. See Paid inference for the full flow, the failure modes, and approvals.