Skip to main content
Register a caller-supplied API key against an existing group. This exists for white-label deployments where you already mint keys for your end users and want Baseten inference under the hood without forcing them to rotate. The registered key inherits the group’s full live model set and effective limits, exactly like a key produced by Create an API key. Baseten stores only the hashed key; once registered, the plaintext value is unrecoverable from our side.

Request signing

This endpoint accepts a key you generated, so Baseten verifies that each request came from you. Sign the request body with an Ed25519 private key; Baseten checks the signature against a public key held for your workspace. Requests without a valid signature return 400 Bad Request. Before your first call, generate an Ed25519 keypair and register the public key with Baseten:
The second command prints the 32-byte public key as base64. Send it to Baseten to store for your workspace; until a key is on file, every call returns 400 Bad Request. Keep priv.pem secret. Sign the exact bytes of the JSON body you send, base64-encode the signature, and pass it in the X-Baseten-Signature header. Re-serializing the body before signing (different key order or whitespace) breaks verification, so sign the precise string you send.

Key requirements

The key value you submit must satisfy these constraints. The endpoint returns 400 Bad Request if any check fails: Generate keys with a cryptographically secure random source on your side and bring them to this endpoint. Baseten does not return a generated key from this call.

Authentication

string
required
Base64-encoded Ed25519 signature of the raw request body, produced with your workspace’s private key. See Request signing. A missing or invalid signature returns 400 Bad Request.

Errors

Authorizations

Authorization
string
header
required

Send Authorization: Bearer <api_key>. The legacy Authorization: Api-Key <api_key> scheme is also accepted.

Path Parameters

group_id
string
required

Body

application/json

Request to register a caller-supplied API key against an existing FederatedGroup.

key
string
required

Value of the API key to register

Example:

"my-secure-api-key-value"

name
string | null

Optional name for the Model API key

Example:

"my-model-api-key"

Response

200 - application/json
ok
boolean
required

Whether the registration was successful