> For the list of every page, fetch /llms.txt. The API contract is the OpenAPI file linked from the API reference.

Live on the hosted beta since 2026-11-28.

- A sandbox cost that Meadow can no longer check against the vendor now says so: `cost_status` `price_unknown`, no cost, and the new `cost_reason` value `vendor_window_unavailable`, when the account stores no key for that vendor or the sandbox ended more than 4 days ago with no billed time from the vendor. Replacing or deleting a Daytona or Modal key now first reads the billed time of your ended sandboxes with the old key, which can make `PUT` and `DELETE /v1/provider-keys/{provider}` take up to 20 seconds longer. See [Usage and cost](/call-models/usage-and-cost#when-a-sandbox-cost-is-final).
- `sort: price` and `POST /v1/sandboxes/route` now price Daytona when the request has no `resources.disk_mb`. Meadow assumes the disk Daytona grants most often when none is asked for, and marks that price `price_estimated` with `cost_reason` `default_disk_assumed`. Before, Daytona's price was unknown and a price sort put it last. See [Sandboxes](/run-sandboxes/sandboxes#sort-by-price-or-start-time).
- The daily vendor cost check now reports orphans: sandboxes alive at Daytona or Modal whose create attempt Meadow already cleaned up, matched by vendor id or by vendor name. An orphan whose attempt never learned its vendor id now gets a usage record. Nothing is deleted unless the server sets `MEADOW_ORPHAN_SWEEP_DELETE=true`. See [Usage and cost](/call-models/usage-and-cost#checks-against-your-vendor-accounts).
- The `error` event that ends a broken streamed command now carries `error.retry` `check_outcome` and `error.outcome` `unknown`, and `error.code` when the error has one. See [Running commands](/run-sandboxes/running-commands).
- New: `provider.sort` on a sandbox create and `routing.sandboxes.sort` on a project: `price` orders the vendors by the hourly list price of the size asked for, `latency` by the median create time of the account's last 20 creates per vendor in 24 hours. `throughput` returns 400. An `order` wins over a `sort`. `POST /v1/sandboxes/route` shows `sort` and `median_create_ms`, and `route_source` can be `request_sort` or `project_sort`. See [Sandboxes](/run-sandboxes/sandboxes#sort-by-price-or-start-time).
- New: an error from a route under `/v1/sandboxes` carries `error.retry` (`safe`, `after_fix`, `check_outcome`, `never`) and `error.outcome` (`not_started`, `unknown`), BoxRouter's names and values. When the response has `x-should-retry`, `retry` agrees with it. A 503 `server_restarting` or `database_unavailable` on `POST /v1/sandboxes/route` now has `x-should-retry: true`: a dry run creates nothing. See [Errors](/reference/errors#retry-and-outcome-on-sandbox-routes).
- A preview Python SDK, `meadow-python` 0.1.0 (import name `meadow`), for sandboxes, images, projects, keys, provider keys, usage, budgets and the audit log. It is not on PyPI yet: install it from source as [Python SDK](/run-sandboxes/python-sdk-preview) shows. Model calls keep using the official OpenAI and Anthropic SDKs.
- New: `POST /v1/sandboxes/route` takes a create body and returns the vendors a create would try, in order, with the reason for each move, the wait, the list price and the health, without creating anything.
- `DELETE /v1/sandboxes/{sandbox_id}/execs/{exec_id}` on a background command that has already exited still returns its final state unchanged, and now also ends the processes the command left running: every process with the command's new `MEADOW_EXEC_ID` environment variable and the rest of its session. Before, it ended nothing. A command that exits by itself still leaves its children running until you call `DELETE`.
- A command, a background command read, stdin, a kill or a file call on a running sandbox makes one database statement fewer before Meadow calls the vendor, about 15 ms on the hosted beta.
- `GET /v1/usage` answers sooner when no other usage read is running on the same server: three of its five parts (totals, series, models, keys, sandboxes) are read at a time instead of one. The figures are the same.
- A served model call now carries the vendor's own service tier header when the vendor that served it sent one: `x-gemini-service-tier` from Google and `x-amzn-bedrock-service-tier` from Bedrock, as the vendor wrote them, on streamed and non-streamed responses. It is absent on vendor errors and for a provider tried before a fallback. No other new vendor header is returned.
- A Bedrock call is priced at the tier Bedrock reports in `X-Amzn-Bedrock-Service-Tier`. `default` keeps the AWS list price; `flex`, `priority` and `reserved` now have no cost (`cost_reason` `pricing_modifier`), because the price table holds only Bedrock's standard rates. Before, every Bedrock call was priced at the standard rate.
- A sandbox create that the vendor refused before it made a sandbox, such as a Modal create whose image does not build, now has a usage record that costs 0. Its `cost` reads 0 with `cost_status` `price_table`, where it read `price_unknown` with `cost_reason` `not_recorded` for good. `GET /v1/usage` counts it in `sandboxes` and its few seconds in `sandbox_seconds`, at no cost, as it already did for a Daytona create that never started.
- The cost of an ended sandbox is final sooner. Meadow reads the time the vendor billed 2 minutes after the sandbox ends, then again with a wait that doubles, up to 6 hours, for 4 days. When the vendor has the time by then, the cost is final within about 4 minutes of the end. Before, the vendor's time was read by a comparison that ran at most every 6 hours, so an ended sandbox could keep Meadow's longer clock, labelled `price_table`, for about 7 hours, although this page said up to an hour. A sandbox that runs across midnight UTC now gets the vendor's time too. See [Usage and cost](/call-models/usage-and-cost#when-a-sandbox-cost-is-final).
- The [quickstart](/get-started/quickstart) reaches a model response before sandbox setup. The guides now use consistent provider and API key terminology, and navigation puts model and sandbox guides before account administration. Existing page URLs and renamed heading anchors still work; no API behavior changed.
- Removing a person from an account revokes every key they minted, and lowering their role revokes the keys the new role could not mint. Each revoked key has an `api_key.deleted` audit entry with `reason`. Keys an API key minted are not affected. The keys a `member` or `viewer` minted in a restricted project they can no longer see are revoked too, with `reason` `project.updated`, `project_member.removed` or `member.updated`.
- Restricted projects. `PATCH /v1/projects/{project_id}` takes `restricted`, and every project carries it. A `member` or `viewer` sees a restricted project only after `PUT /v1/projects/{project_id}/members/{user_id}`. To anyone else it answers 404 `project_not_found`, and its keys, sandboxes, images, usage and provider keys are left out of every list and total. New: `listProjectMembers`, `addProjectMember`, `removeProjectMember`, and the audit types `project_member.added` and `project_member.removed`. Keys are not affected.
- `GET /v1/invite-links/{token}` shows an open invite from its link with no credential: account name, role, masked address and expiry. Any other token gets the same 404 `invite_not_found`.
- `GET /v1/retention` returns how many days usage records and audit log entries are kept.
- `GET /v1/usage/requests` takes `request_id`, and each record carries `attempt`: 0 for the call, 1, 2 and so on for the vendor attempts given up on after sending.
- `POST /v1/access-requests` takes the private beta access form (`email`, `name`, `company`, `use_case`, `needs`) with no credential, and answers 202 `{"status":"received"}` to every valid request. More than 300 an hour in total get 429 `access_request_rate_limited`. Nothing changes for code that sends a key.
- Image objects carry `project_id`. A signed-in person may call `GET /v1/models`, and may call `GET /v1/models`, `GET /v1/sandboxes` and `GET /v1/images` without `x-meadow-project` to read the whole account. Nothing changes for a key.
- `POST /v1/provider-keys/{provider}/verify` checks a stored vendor credential again without sending it, and sets `verified_at` when the vendor accepts it. See [Provider keys](/set-up-your-account/provider-keys#check-a-stored-key-again).
- `GET /v1/usage/requests` takes `status` (`served` or `failed`) and `fell_back` (`true` or `false`), applied before paging, so every page holds only matching calls.
- The audit log gains the types `access.approved` and `access.revoked`, written with `actor.type` `system` when Meadow's operators approve or revoke beta access.
- Azure calls can have a cost. The Azure provider key takes a new optional field, `deployment_types`, that maps a deployment name to Azure's deployment type (`GlobalStandard`, `DataZoneStandard`, `Standard`, a provisioned type, a batch type or `DeveloperTier`). A call to a listed OpenAI model on a `GlobalStandard` deployment is priced at Azure's global prices, which equal OpenAI's. Every other call through Azure still has no cost, with a new `cost_reason`: `deployment_type_unknown` (no type stored), `deployment_type_unpriced` (Data Zone, Standard, batch or developer: Data Zone and Standard prices depend on the resource's region, which Meadow does not store) or `provisioned_throughput`. A key with a dollar `limit` can now call a `GlobalStandard` deployment. Do: store `deployment_types` to have Azure calls priced.
- A Gemini route: `POST /v1beta/models/{model}:generateContent` and `:streamGenerateContent?alt=sse`, also under `/v1`, in Google's own format with no conversion, served by your `google` or `vertex` key. Meadow reads the key from `x-goog-api-key`, `?key=` or `Authorization`. Usage records show `format` `generate_content`, and `GET /v1/models` lists `generate_content` in `formats`. Meadow's errors on this route use Google's envelope. See [Gemini clients](/call-models/gemini-clients).
- A vendor's error no longer carries the key or token Meadow sent to that vendor, in an error body or in an error event inside a stream: Meadow replaces each copy with `[REDACTED]`, on every model route and stream format.
- The Meadow dashboard can call the API for a signed-in person. `GET /v1/me`, `GET /v1/me/preferences`, `PUT /v1/me/preferences`, `GET /v1/members`, `PATCH` and `DELETE /v1/members/{user_id}`, `GET` and `POST /v1/invites`, `DELETE /v1/invites/{invite_id}` and `POST /v1/invites/{invite_id}/accept` are new and take a session token only. `GET /v1/me` also answers a person in no account, with the open invites to their verified email. The audit log gains the types `invite.created`, `invite.revoked`, `member.updated`, `member.removed` and `member.joined`. Key objects carry `created_by_user_id`, null for a key another key minted. An audit log entry for a change a person made has `actor.type` `session` and `actor.session.user` with their id and email: code that reads `actor.type` must accept the new value. Nothing else changes for a key.
- Six new error codes belong to the Meadow dashboard's sign-in and never answer an API key: 401 `session_token_invalid` and `session_token_expired`, 403 `user_token_not_allowed`, `no_account_access` and `role_not_allowed`, and 503 `session_keys_unavailable`. See [Errors](/reference/errors). Nothing changes for code that sends an API key.
- A call that was at its vendor when a Meadow server stopped without warning now gets a usage record about an hour later: `kind` `abandoned_attempt`, `cost_reason` `interrupted`, `cost` `null`, no tokens, and a new field `held_usd` (with `held_tokens`) on `GET /v1/usage/requests` with the amount the call held. Before, it got no record. Key limits and hard budgets were already charged that amount, and still are; `held_usd` shows where a limit's move came from. Every other record has `held_usd` and `held_tokens` `null`.
- Bedrock serves Chat Completions and Responses for the models it hosts other than Claude, through AWS's OpenAI-compatible route. Pin the id, for example `bedrock/openai.gpt-oss-120b-1:0`, on `/v1/chat/completions` or `/v1/responses`. These calls have no cost in Meadow yet, so a key with a dollar `limit` is refused. Do: pin the full Bedrock model id.
- The Bedrock provider key takes a Bedrock API key: send `{"api_key": ..., "region": ...}` instead of an access key. Meadow then calls Bedrock's Anthropic Messages route with the key in `x-api-key`. The key is stored without a check, so make one model call after storing it. Do: generate the key in the Bedrock console under API keys.
- A Vertex error in Google's format now reaches you in the route's envelope: Anthropic's on `/v1/messages`, OpenAI's on Chat Completions, with Google's message, and on Chat Completions Google's `status` (such as `RESOURCE_EXHAUSTED`) in `code`. Before, Meadow returned Google's body as written. Do: read `error.message` and `error.type` as on any other vendor.
- The first call with a key in a minute no longer waits for Meadow to write the key's `last_used_at`. The write runs beside the call and lands within 2 seconds. A `GET /v1/key` can therefore show the time before that same call.
- Two model providers, `fireworks` and `deepseek`, each with an `api_key` credential. Both take Chat Completions, Responses and Messages, and serve pinned ids only, such as `fireworks/accounts/fireworks/models/kimi-k3` and `deepseek/deepseek-flash`. Three Fireworks models are priced. Every DeepSeek call has no cost, with the new `cost_reason` `time_of_day_price`, so a key with a dollar limit cannot call DeepSeek. No real call has been made to either vendor.
- New: `GET /v1/pricing` returns the price table Meadow costs usage with, and needs no key. It carries `prices_as_of` per vendor and lists in `stale_vendors` each vendor whose prices were last compared with its page more than 30 days ago. It returns price fields only, not Meadow's notes on each entry. See [Usage and cost](/call-models/usage-and-cost#the-prices-meadow-uses).
- A model call reaches the vendor sooner: Meadow reads the project, the usable provider keys and the first provider's key in one database statement instead of three. On the hosted beta each statement takes about 15 ms. `GET /v1/models` reads them the same way. A provider key you remove while a call is starting can still serve that call, for up to 5 seconds on a key with a limit: see [Known limits](/reference/known-limits#provider-keys).
- Bedrock calls have a cost. The listed Claude models on `bedrock` are priced from the AWS Price List: a `global.` model id at AWS's global rates, and every other inference profile (`us.`, `ca.`, `eu.`, `apac.`, `jp.`, `au.`, or none) at AWS's regional rates, 1.1 times the global ones. Before, every Bedrock call had no cost (`provider_not_priced`). A key with a dollar `limit` and a budget with `hard_limit` now let these calls through and charge them. A Bedrock model or geography prefix Meadow does not list still has no cost, and is still refused under a dollar limit.
- A Bedrock error passed to you on `POST /v1/messages` now has Anthropic's error envelope, with AWS's message and the same status. Before, it was AWS's own body, `{"message": ...}`. Do: if you read `message` at the top level of a Bedrock error, read `error.message`.
- A key can carry `allowed_providers` (model providers) and `allowed_sandbox_providers` (`daytona`, `modal`) next to `allowed_models`, on `POST /v1/keys`, `PATCH /v1/keys/{key_id}` and every key object. `allowed_providers` is OpenRouter's name. Every attempt of a model call stays on the list, fallbacks included, and `GET /v1/models` lists only those providers. A call or sandbox create whose route keeps no listed provider returns 403 with `error.code` `key_provider_access_denied`. See [Model and provider allowlists](/call-models/model-and-provider-allowlists).
- `PATCH /v1/keys/{key_id}` takes `allowed_models`, `allowed_providers` and `allowed_sandbox_providers`. Before, each returned 400 `unknown field in key update request`. A new list must stay inside the lists of the keys above the changed key and of the calling key. A key's lists now hold every key below it from its next call, also when they were narrowed after those keys were minted.
- A model the key may not call returns 403 with `error.code` `key_model_access_denied` and `error.param` `model` (`models` for a fallback entry), in the OpenAI or Anthropic envelope. Before, it returned 403 with `error.code` `forbidden` and no `param`. The status and `error.type` are unchanged. Code that matches the code `forbidden` must add the new code.
- `allowed_models: []`, and an entry with a provider prefix Meadow does not know such as `acme/model-1`, return 400 on `POST /v1/keys`. Before, `[]` made a key that could call no model, and the unknown prefix never matched.
- Correction: a Gemini call that sent `service_tier` `priority` or `flex` was priced at the standard rate and marked `price_table`, so a priority call read 44 percent low and a flex call at twice its cost. A call is now priced at the tier the vendor says it served: Google's `x-gemini-service-tier` header, or `service_tier` in the answer for the other vendors. A call that asked for a tier and got no answer on it has no cost, with the new `cost_reason` `service_tier_unconfirmed`. A downgrade to standard is priced at standard. Records made before this change are not corrected.
- The `priority` and `flex` tiers are priced for the Google and OpenAI models whose pricing pages list them, and xAI `priority` as an estimate at twice the list price. Before, these calls had no cost. Under a dollar limit or a hard budget, a request for a tier Meadow has no price for (OpenAI `scale`, for example) is now refused with 403 `key_spend_price_unknown` before any vendor is called. Before, it was reserved at the standard rate.
- A call to `gpt-6-astra-law`, `gpt-6-astra-healthcare` or `gpt-6.1-sol-healthcare` that writes to the prompt cache now has no cost (`cost_reason` `no_cache_rate`), because OpenAI publishes no cache write price for these models. Before, it was priced at a cache write rate OpenAI does not list.
- Correction to dollar limits and hard budgets. A streamed call that was cut, a stream the vendor ended without token counts, and an answer with no token counts were charged 0 US dollars to a key's `limit` and to a budget with `hard_limit`, though the vendor billed them. They are now charged the whole amount held for the call, as [Spend limits](/call-models/spend-limits#the-limit-can-be-passed-by-one-call) says. On the hosted beta this was wrong from 2026-11-28 until this fix. Calls already counted at 0 are not counted again.
- Sandbox creates remember a failing vendor. After 3 failed creates in a row on one vendor within 10 minutes, or one quota, capacity or rate limit answer, the vendor is open for 60 or 30 seconds, then one create tries it again. A route with no order tries your other vendor first while one is open. An order you set (`provider.order`, or the project's `routing.sandboxes.order`) is tried as written unless its first vendor answered quota exceeded or no capacity, or failed 3 creates in a row. `GET /v1/provider-keys` shows this as `sandbox_health` on the `daytona` and `modal` entries.
- Sandboxes have `skipped_providers`: each vendor Meadow moved to the end of the route, with the reason and `retry_at`.
- A vendor that rejects the stored key (401 or 403) fails its attempt at once with reason `auth_failed`, the next vendor is tried, and the rejection does not count against the vendor's health. Before, a key rejected while a create was waiting for the vendor kept the create waiting until `create_timeout_seconds`.
- An unknown model is a 404. This changes a status. A plain model id Meadow cannot resolve now returns 404 with `error.code` `model_not_found` on `POST /v1/chat/completions`, `POST /v1/responses` and `POST /v1/messages`, in the format's envelope: `invalid_request_error` in OpenAI's, `not_found_error` with `error.details.error_code` `model_not_found` in Anthropic's. It returned 400 with `error.code` `parameter_invalid`. This is how OpenAI and Anthropic answer a model they do not serve, so their SDKs now raise `NotFoundError` where they raised `BadRequestError`. The message and `param` (`model`) did not change. See [Models](/call-models/models#model-ids).
- What did not change: an unlisted `claude-`, `gpt-`, `gemini-` or `grok-` id on a project with that vendor's key still goes to the vendor, and the vendor's own 404 comes back. A model with no stored key that serves it is still 422 `no_provider_key`, and a pinned id no provider accepts in that format is still 400. Do: if you catch `BadRequestError` or check for 400 to find an unknown model, catch `NotFoundError` or check for 404 and `error.code` `model_not_found`.
- A model call is priced at the model the vendor's answer names (`served_model`). When that model has no price, the record has no cost and `cost_reason` is the new value `served_model_unknown`. Before, such a call was priced at the model you asked for.
- `gemini-2.5-pro` and `gemini-2.5-flash` calls from 2026-12-01 are priced at the rates Google bills after it routes them to `gemini-3.8-flash` and `gemini-3.5-flash-lite`, as estimates (`price_estimated`). Before, they would have had no cost from that date.
- `gemini-2.5-flash` and `gemini-2.5-pro` are no longer in `GET /v1/models`. Google's API now serves them only to accounts that used them before, and moves both to other models on 2026-12-01 ([Google's deprecations page](https://aistudio.google.com/docs/deprecations)). Vertex lists 2026-10-20 as their retirement date. A new account with a Google key got a 404 from Google for a model Meadow listed. With a Google key, the plain id still goes to Google as written, as any unlisted `gemini-` id does, so an account Google still serves keeps working. Do: through OpenRouter, pin the id (`openrouter/google/gemini-2.5-flash`), or move to a listed model such as `gemini-3.8-flash`, which Google names as a replacement. Vertex lists both 2.5 ids as retired.
- A 404 from the only vendor in the route now comes back as the vendor wrote it, with `x-meadow-provider`, as a 404 for a pinned id already did. It was a 502 `all_providers_failed`, or `provider_error` with `allow_fallbacks: false`. A route with more than one vendor still moves on after a 404, and returns the 502 when no vendor serves the call. Do: if you treat a 502 as "the model is not served", also handle a 404 with the vendor's body. See [Routing and fallbacks](/call-models/routing-and-fallbacks#what-does-not-trigger-a-fallback).
- Budgets: `PUT`, `GET` and `DELETE` on `/v1/budget` (the account) and `/v1/projects/{project_id}/budget`. A budget has `limit_usd`, `reset_interval` and `alert_thresholds`, and never refuses a call. When spend first reaches a threshold in a window, Meadow sends one `budget.threshold_crossed` webhook event to the project's `webhook_url` (for the account budget, to every project's) and one email to `notification_channel.recipients`. A receiver that assumed every event is a sandbox event must branch on `type`. See [Budgets and alerts](/call-models/budgets-and-alerts).
- Audit log: `GET /v1/audit-logs` lists the changes made through the API to keys, projects, provider keys and budgets, with the key that made each one, the time and the request id. It holds no secret. Entries are kept 400 days. See [Audit log](/set-up-your-account/audit-log). The Security page has a new Retention table.
- Key rotation: `POST /v1/keys/{key_id}/rotate` gives a key a new secret and keeps its id, limits, counters and child keys. `grace_period_seconds` (at most 604800) keeps the old secret working while you deploy the new one. The key object gains `previous_secret_expires_at`. See [Authentication](/set-up-your-account/authentication#rotate-a-key).
- A budget can stop spend: `hard_limit: true` on `PUT /v1/budget` and `PUT /v1/projects/{project_id}/budget` makes `limit_usd` a ceiling for the window. Model calls and sandbox creates past it are refused with 402 `budget_exceeded`. The budget object gains `hard_limit` and `enforced_spend_usd`. See [Budgets and alerts](/call-models/budgets-and-alerts#stop-at-the-limit).
- This can change one thing for existing code: when neither the request nor the project sets `create_timeout_seconds`, Meadow now waits 120 seconds on a vendor that is not the last in the route, and 300 on the last. Before, it waited 300 on each. Set `create_timeout_seconds` to wait the same time on every vendor. GPU sandboxes keep 300 on each.
- `max_sandboxes` can be set: on a key (`POST /v1/keys`, `PATCH /v1/keys/{key_id}`) and on a project (`POST /v1/projects`, `PATCH /v1/projects/{project_id}`). It caps how many sandboxes are alive at once. A create past it returns 403 with `error.code` `key_sandbox_limit_exceeded` or `project_sandbox_limit_exceeded`. Before, `POST /v1/keys` returned 400 for the field. Key and project objects now carry `max_sandboxes`. See [Sandboxes](/run-sandboxes/sandboxes#limit-how-many-run-at-once).
- `GET /v1/sandboxes/{sandbox_id}` and `GET /v1/sandboxes` return `cost` on each sandbox: `cost_per_hour`, `cost`, `currency`, `cost_status`, `cost_reason` and the billed window. It is the figure `GET /v1/usage` counts for that sandbox. See [Usage and cost](/call-models/usage-and-cost#the-cost-of-one-sandbox).
- A key can carry a limit in US dollars: `limit` on `POST /v1/keys` and `PATCH /v1/keys/{key_id}`, with `usage` and `limit_remaining` on every key object. The names are OpenRouter's. It covers model calls and sandboxes of the key and of every key minted from it, and `limit_reset` resets it. A spent limit returns 402 with `error.type` `insufficient_quota` and `error.code` `key_spend_limit_exceeded`. Both the status and the type are new: code that lists every status or every `error.type` must add them. A key with a `limit` must send an output cap on every model request, and can only call models Meadow has a price for (403 `key_spend_price_unknown` otherwise). Keys without a `limit` are not affected. Running sandboxes are not stopped by a spent limit unless the key has `limit_action` `stop_sandboxes`. See [Spend limits](/call-models/spend-limits).

Errors on the model routes use the vendor's format. This is a breaking change.

An error Meadow makes on `/v1/chat/completions`, `/v1/responses`, `/v1/messages` or `/v1/models` is now written in OpenAI's or Anthropic's own error envelope, so the official SDKs raise their usual typed errors with their fields filled. The same holds for the vendor paths Meadow answers with a 404, such as `/v1/embeddings`. Every other route keeps Meadow's envelope. See [Errors on model routes](/reference/errors#errors-on-model-routes) for the full table.

Before, on every route:

```json
{"error":{"type":"unauthorized","code":"api_key_invalid","message":"invalid api key"},"request_id":"req_0000252a"}
```

After, on `/v1/chat/completions`, `/v1/responses` and `/v1/models`:

```json
{"error":{"message":"invalid api key","type":"invalid_request_error","param":null,"code":"api_key_invalid"},"request_id":"req_0000252a"}
```

After, on `/v1/messages`:

```json
{"type":"error","error":{"type":"authentication_error","message":"invalid api key","details":{"error_code":"api_key_invalid"},"code":"api_key_invalid"},"request_id":"req_0000252a"}
```

What changed:

- `error.type` on those routes is the vendor's string: `invalid_request_error`, `rate_limit_error`, `server_error`, `service_unavailable_error` in OpenAI's envelope, and `invalid_request_error`, `authentication_error`, `permission_error`, `not_found_error`, `conflict_error`, `request_too_large`, `rate_limit_error`, `api_error` in Anthropic's. A wrong method (405) is `invalid_request_error` in both. A key that has spent a dollar limit (402) is `insufficient_quota` in OpenAI's envelope and `billing_error` in Anthropic's.
- On `/v1/messages` the body gains the top-level `"type": "error"` and `error.details.error_code`.
- In OpenAI's envelope `error.param` is always present, and `null` when there is none.
- Every `/v1/messages` response carries a `request-id` header with the same value as `x-request-id`.

What did not change: every HTTP status, every `error.code`, `error.message`, `error.attempts`, `request_id`, `x-request-id`, `retry-after`, `x-should-retry`, error events inside a stream, and a vendor error that is passed through.

What to do:

- If your code reads `error.type` on a model route, switch it to the HTTP status and `error.code`, or to the vendor's type strings above. `unauthorized`, `forbidden`, `not_found`, `conflict`, `no_provider_key`, `rate_limited`, `all_providers_failed`, `provider_error`, `unavailable` and `internal` are no longer sent on those routes.
- If your code reads `error.code`, the status or `request_id`, change nothing.
- If you use the OpenAI or Anthropic SDK, catch its normal classes. `e.code` (OpenAI) and `e.error_code` (Anthropic) hold Meadow's code.
- Meadow's Go SDK, `mdw` and the Python client read both the old and the new body. On a model route their `Type` or `type` field now holds the vendor's string, and `Code` or `code` is unchanged.

New in the `mdw` CLI, in builds from this date:

- `mdw mcp` runs a Model Context Protocol server on standard input and output, with 17 tools for sandboxes, images, keys, and usage. It changes no API behavior. See [MCP server](/get-started/mcp-server) and [Get started with your agent](/get-started/get-started-with-your-agent).
- A call whose stream was cut, or whose vendor sent no token counts, now has an estimated cost when its model has a list price. It has `cost_status` `price_estimated` and `cost_reason` `stream_cut` or `usage_not_reported`, and it is inside `estimated_price_cost`. Before, it had no cost. The output estimate now counts the text received and not the size of the stream, so it is lower than before.
- A cut stream through OpenRouter is read back from OpenRouter a minute or more later. Its record then holds OpenRouter's tokens and cost, with `usage_status` `measured`, `cost_status` `provider_reported` and `cost_reason` `vendor_lookup`.
- A sandbox that has ended is costed over the time the vendor billed, which starts when the vendor started it. `sandbox_seconds` is still Meadow's own count from the create call. A create attempt that never served the sandbox and that the vendor never started costs 0. A sandbox cost can go down up to an hour after the sandbox ended.
- A Daytona spot GPU sandbox is marked as an estimate (`price_estimated`).
- Anthropic calls with US-only inference (`inference_geo: "us"`) and fast mode (`speed: "fast"`) now have a cost, at the prices on Anthropic's pricing page. Before, they had none.
- A command that exits by itself now leaves the processes it started in the background running, as the API reference already said. Before, every background command, and every blocking or streamed command on Daytona, ended its whole process group when it exited, so a server started with `nohup ... &` died with the command that started it. A timeout, or a kill of a running background command, still ends the whole group. See [Processes a command leaves running](/run-sandboxes/running-commands#processes-a-command-leaves-running).
- This can change two things for existing code. A command whose child keeps `stdout` or `stderr` open finishes when the command exits, and output the child writes more than about one second later is no longer recorded. `DELETE` on a background command that has already exited no longer ends the processes it left.
- The fixed limits on requests in flight are gone: 16 model calls per key and 60 open requests per account, on each server. A server now admits every request while it has a free slot. On a full server a request waits up to 3 seconds, freed slots go first to the account with the fewest requests open, and a request that gets none returns 429 with `error.code` `account_in_flight_limit_exceeded`. `in_flight_limit_exceeded` is no longer returned by the hosted service. See [Token and request limits](/call-models/token-and-request-limits#the-in-flight-limit-and-retry-after).
- `x-should-retry` is sent on more responses. The 429s for a full server, a full body budget and a busy limit check carry `true`: no vendor was called. A 5xx on a model route carries `false`, because a vendor may have received the call. The official OpenAI and Anthropic SDKs obey the header, so they stop resending a failed model call.
- Usage: `output_tokens` now holds every token billed at the output price. Gemini leaves thinking tokens out of its output count and shows them only in its total. The cost had them and `output_tokens` did not. `reasoning_tokens` is the part of `output_tokens` that was reasoning, as on OpenAI and OpenRouter. This changes the figures `GET /v1/usage` and `GET /v1/usage/requests` return for Gemini calls, including past ones. See [Usage and cost](/call-models/usage-and-cost#tokens).
- `GET /v1/usage/requests` returns three more fields on each record: `total_tokens`, `unattributed_tokens` and `cost_reason`.
- A direct Anthropic call on a model older than Claude 4.6, such as Claude Haiku 4.5, now has a cost. Anthropic reports `inference_geo: "not_available"` for those models, and Meadow read that as a region with its own price. Calls recorded before this change keep no cost.
- A served call whose tokens Meadow had to estimate says why in `cost_reason`: `stream_cut` or `usage_not_reported`.
- A key with no `max_requests` or `max_tokens` anywhere in its chain now shows `requests_used` and `tokens_used`: the calls it served, read from the usage records. Before, both were 0. `last_used_at` now moves when a key authenticates any call, a sandbox call included, at most once a minute for each key. Before, it moved only for model calls on a key with a limit. See [Authentication](/set-up-your-account/authentication#read-a-key-and-its-usage).
- On-demand Daytona sandboxes of every GPU class now have a cost. Before, only H100 and RTX 4090 did.

Standard conventions. One status changes: a wrong method is a 405, where it was a 404. The rest only add.

- A known path called with the wrong method returns 405 with `error.code` `method_not_allowed` and an `Allow` header that lists the methods the path accepts. It returned 404 `route_not_found`. An unknown path still returns 404. If your code matched a 404 for a wrong method, match 405.
- Webhook deliveries also carry the [Standard Webhooks](https://www.standardwebhooks.com) headers `webhook-id`, `webhook-timestamp` and `webhook-signature`, so a Standard Webhooks library can verify them. `x-meadow-signature` is still sent and did not change. A new or rotated webhook secret is written in standard base64. A secret you already hold keeps working. See [Webhooks](/run-sandboxes/webhooks#verify-the-signature).
- The Go SDK, `mdw` and the Python client call `https://api.usemeadow.ai` when `MEADOW_BASE_URL` is not set. Before, they refused to start without it. `mdw --version` prints the version, and each client sends its version in `User-Agent`: `meadow-go/<version>`, `mdw/<version>`, `meadow-python/<version>`.
- A `traceparent` header (W3C Trace Context), or Google's `X-Cloud-Trace-Context`, is read on every route. Meadow writes the trace id on its log lines for the request. It changes nothing in the response.