Skip to content

Authentication

The Workspace API authenticates with API keys. A key is tied to a workspace and acts with admin privileges, so treat it like a password.

  1. Sign in as a workspace admin.
  2. Open your workspace API key settings.
  3. Create a new key and give it a descriptive name (e.g. “Zapier”, “ETL job”).
  4. Copy the key now — the full value (ml_live_…) is shown once. After that, only a masked hint is displayed.

Send the key as a Bearer token on every request:

Terminal window
export MIXERLEAD_API_KEY="ml_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
curl https://ai.mixerlead.com/api/ai/models \
-H "Authorization: Bearer $MIXERLEAD_API_KEY"
Node.js (fetch)
const res = await fetch("https://ai.mixerlead.com/api/ai/models", {
headers: { Authorization: `Bearer ${process.env.MIXERLEAD_API_KEY}` },
});
const data = await res.json();
Python (requests)
import os, requests
res = requests.get(
"https://ai.mixerlead.com/api/ai/models",
headers={"Authorization": f"Bearer {os.environ['MIXERLEAD_API_KEY']}"},
)
res.raise_for_status()
print(res.json())

By default, requests use your workspace’s default project. To target a specific project, add the X-Project-Id header:

Terminal window
curl https://ai.mixerlead.com/api/agents \
-H "Authorization: Bearer $MIXERLEAD_API_KEY" \
-H "X-Project-Id: <your_project_id>"
  • List your keys to see their names, masked hints, and last‑used time.
  • Rotate by creating a new key, updating your integration, then deleting the old one.
  • Revoke a key by deleting it — it stops working immediately.
SituationResponse
Missing or malformed key401 Unauthorized
Unknown / revoked key401 Unauthorized
Rate limit exceeded429 Too Many Requests

See Errors & rate limits for the full reference.