Check out the newest way to compare different models for a task/agent harness: AutoEvals

API

Regional Endpoints

Use the US-only endpoint to keep inference for Inference.net-hosted models in the United States.

Choose an endpoint based on where you want requests to run:

API base URLWhere requests run
https://api.inference.net/v1Any eligible GPU, in any country.
https://us.api.inference.net/v1Only GPUs located in the United States, for models hosted by Inference.net. GPUs outside the US or with an unknown location are not used.

Both endpoints use the same API keys, model IDs, and request formats. To use the US-only endpoint, change the base URL. You do not need a region parameter or an extra header.

On the US-only endpoint, requests are handled in the US end to end:

  • Edge: Cloudflare terminates TLS and handles the request only in US data centers.
  • Routing: requests for models that Inference.net hosts are routed only to US-hosted GPU capacity.
  • Inference: those models run on a GPU located in the US.

The US-only endpoint controls where models hosted by Inference.net run. Some models, such as GPT, Claude, and Gemini, are served by a third-party provider. Some hosted models also have a third-party provider as a fallback. Requests that go to a third-party provider run where that provider decides.

Use the US-only endpoint

TypeScript
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://us.api.inference.net/v1",
  apiKey: process.env.INFERENCE_API_KEY,
});

const response = await client.chat.completions.create({
  model: "deepseek-v4.1-flash",
  messages: [{ role: "user", content: "What is the meaning of life?" }],
});

console.log(response.choices[0].message.content);

Base URLs

SettingGlobalUS-only
OpenAI-compatible base URLhttps://api.inference.net/v1https://us.api.inference.net/v1
Anthropic Messages base URLhttps://api.inference.nethttps://us.api.inference.net

To use the US-only endpoint with the Anthropic SDK, set baseURL (TypeScript) or base_url (Python) to https://us.api.inference.net.

To use it in a gateway or router such as LiteLLM or Bifrost, or in a coding agent, set the provider base URL to https://us.api.inference.net/v1. Model IDs do not change.

Retries

To keep requests in the US, send retries to us.api.inference.net too. A retry sent to api.inference.net can run outside the US.

On this page