# Quickstart

Create an API key, point base_url at Amux AI, and make your first request.

Making a first request usually takes two changes: the **address** and the **key**.

## Four steps

1. Sign in and decide which account is billed
2. Add credit to that account
3. Create an API key
4. Make your first request

## 1. Sign in and confirm the account

Signing up creates a **personal workspace** that is ready to use. For team use, create an **organization** instead: balance, members, and permissions are managed at that level and stay fully separate from the personal workspace.

Balance belongs to an **account** — one for the personal account, one for each organization. They are independent and cannot be transferred between each other, so decide who is billed before adding credit. See [accounts, organizations, and workspaces](/docs/organizations).

## 2. Add credit

Add credit on the console's billing page. Billing is **prepaid credit drawn down by actual usage**: inference is charged at the price shown on the model page for the provider that served it, with upstream discounts already included.

Top-ups carry no processing fee — the credit you receive equals the amount you pay. See [top-ups and auto top-up](/docs/billing/top-up).

Subscription billing has not shipped.

## 3. Create a key

Create a key on the console's **API keys** page. A key can be **viewed in full again** on that page later; there is no need to regenerate it.

Keys are bound to a **workspace**, and charges are recorded against that workspace's account. Create separate keys per project or per purpose: usage, cost, and logs are all reported per key, and requests made with the same key cannot be separated afterwards.

Keys also carry spend limits, model allowlists, and their own routing configuration. See [API keys](/docs/api-keys).

## 4. Make your first request

Amux AI (amux.ai) implements the OpenAI protocol natively, so the official SDK works directly:

```python
from openai import OpenAI

client = OpenAI(
    base_url="https://gateway.amux.ai/v1",
    api_key="your Amux key",
)

response = client.chat.completions.create(
    model="anthropic/claude-opus-5",
    messages=[{"role": "user", "content": "Explain what an API gateway is in one sentence"}],
)

print(response.choices[0].message.content)
```

```bash
curl https://gateway.amux.ai/v1/chat/completions \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "anthropic/claude-opus-5",
    "messages": [{"role": "user", "content": "Hello"}]
  }'
```

Use the canonical ID shown on the model detail page for `model`, in the form `vendor/model`. Bare names carried over from other environments (such as `claude-haiku-4-5-20251001`) usually work as well, since the platform maintains aliases for common models.

## Supported protocols

All four text protocols are **native implementations**, not translations. Choose the address by the protocol your client speaks, not by the model you are targeting:

| Protocol | Endpoint | Auth header |
|---|---|---|
| OpenAI Chat Completions | `https://gateway.amux.ai/v1/chat/completions` | `Authorization: Bearer` |
| OpenAI Responses | `https://gateway.amux.ai/v1/responses` | `Authorization: Bearer` |
| Anthropic Messages | `https://gateway.amux.ai/v1/messages` | `x-api-key` |
| Google Gemini | `https://gateway.amux.ai/v1beta/models/{model}:generateContent` | `x-goog-api-key` |

This table covers the four text protocol entry points. For the complete list of image, video, and asynchronous task endpoints, see the [Endpoint table](/api-reference#addresses-and-endpoints).

**Protocol and model are independent dimensions.** You can call Claude with the OpenAI SDK, or Gemini with the Anthropic SDK. Not every model supports every protocol, though; the model detail page lists the protocols actually available for it. For parameter differences across protocols, see [protocol conversion compatibility](/api-reference/protocol-conversion).

Image, video, and other asynchronous generation tasks use their own endpoints. See the [API reference](/api-reference) for the full list.

## Choosing a provider

The same model is usually offered by several providers, and price, context length, and supported protocols may differ. By default the platform routes among the available providers and switches to the next one on failure.

**To pin a provider**, append `:<provider>` to the model ID:

```json
{ "model": "anthropic/claude-opus-5:anthropic" }
```

Once pinned, the request fails outright if that provider is unavailable; it will not switch to another.

**To set the sorting strategy for a single request**, append `:@<strategy>`:

```json
{ "model": "anthropic/claude-opus-5:@price" }
```

The available strategies are `@balanced` (default), `@price`, `@latency`, `@throughput`, and `@reliability`.

> ⚠️ The colon is part of the suffix syntax; `@` cannot be attached to the model name on its own. The two suffixes cannot be combined — pinning a single provider leaves one candidate, so a sorting strategy does not apply.

> ⚠️ Strategy suffixes are locked by the key by default. To let callers set a strategy per request, enable "allow request override" in the key's settings.

For sorting strategies, supply tiers, pinned providers, and how the three configuration layers combine, see [routing and failover](/docs/routing).

## Check the charges

After a call completes, the console's **usage** and **cost** pages show spend, the provider that served it, and the distribution across token types. The **logs** page shows the full record and itemized charges for a single call.

Attempts that fail during routing retries are not billed. If the client disconnects midway, usage already produced is still billed — that content has already been generated upstream. For the full rules, see [billing overview](/docs/billing).

## Next

- [Core concepts](/docs/concepts) — how accounts, workspaces, keys, models, and credit relate
- [Routing and failover](/docs/routing) — multi-provider routing strategies and failover rules
- [API keys](/docs/api-keys) — limits, model allowlists, and per-key routing
- [Accounts, organizations, and workspaces](/docs/organizations) — teams, members, and roles
- [Integrations](/integrations) — connecting Claude Code, Cursor, Cherry Studio, and other tools
- [API reference](/api-reference) — full endpoints, parameters, and examples
