Skip to content

Generated from api/openapi.yaml (OpenAPI 3.1). Base URL: https://api.teemli.com. Auth: Authorization: Bearer <token or tml_ API key>. Errors are application/problem+json; writes accept an Idempotency-Key header.

Admin console (M5a, product.md 7.11, 7.13), admins only. Metadata only: agents, people, activity and spend come from narrow SECURITY DEFINER functions; admins never get conversations, memory, files or connections. Kill switch per agent and organisation-wide (an admin pause stays until an admin resumes). Removing a person runs offboarding: agents stop, app accounts are revoked, the computer is deleted, laptops and phones are signed out, memory and conversations are archived or erased per offboarding.

People, agents working now, spend vs budget, alerts

Section titled “People, agents working now, spend vs budget, alerts”
GET /v1/orgs/{org}/admin/overview

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OK — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Organisation settings (name, slug, offboarding policy, budget + alert threshold, switches, ZDR, personal plans and keys)

Section titled “Organisation settings (name, slug, offboarding policy, budget + alert threshold, switches, ZDR, personal plans and keys)”
GET /v1/orgs/{org}/admin/settings

Personal model access switches, all on by default for every organisation (founder, 4 Dec 2026): allow_personal_subscriptions (ChatGPT plans; null reads as on), allow_grok_plan (Grok plans), allow_personal_keys (a person’s own Anthropic / Gemini / OpenRouter keys). Each serves only the person’s own agents. personal_subscriptions_allowed is what applies now for ChatGPT (read-only).

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OrgSettings — object
PUT /v1/orgs/{org}/admin/settings

switches accepts network, browser, computer, laptop, password_manager (booleans), ai_employees (everyone | admins), safety_review (boolean, off by default: the AI safety reviewer, a second model that approves, blocks or asks about agents’ sensitive actions) and safety_review_model (its model id; empty = the default small, fast model). offboarding: archive | erase. allow_personal_subscriptions, allow_grok_plan, allow_personal_keys: booleans (people’s own ChatGPT plans, Grok plans, API keys).

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OrgSettings — object
  • 422 Invalid input — Problem

One page of people with role, status, agent counts, spend vs budget, teams (metadata only)

Section titled “One page of people with role, status, agent counts, spend vs budget, teams (metadata only)”
GET /v1/orgs/{org}/admin/people

Server-side search, filters, sort and cursor paging (F1, built for 1,000+ people). Empty parameters are ignored. Spend is computed only for the page, or by one grouped aggregate when sorting by spend. counts are the status tabs within the other filters (role, team, q), roles the role chips within the status filter, and total the rows matching every filter — so the tab counts always match the rows.

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
limit query integer
cursor query string Opaque; next_cursor of the previous page
q query string Name or email contains (case-insensitive; % and _ are literal)
role query owner, admin, member, guest
status query active, invited, removed
team query string (uuid) People in this team
sort query name, email, role, status, spend, budget, last_active, created, agents
dir query asc, desc Default: desc for spend, budget, last_active, created, agents; asc otherwise

Responses

  • 200 A page of people — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Invite by email (status invited; they join on first sign-in; an email is sent)

Section titled “Invite by email (status invited; they join on first sign-in; an email is sent)”
POST /v1/orgs/{org}/admin/people

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
email (required) string
role member, admin, owner
display_name string

Responses

  • 201 {person, emailed} — object
  • 409 Conflicting state (card already answered, duplicate in flight, name taken) — Problem

Role and monthly AI budget (only owners grant or remove owner; the last owner stays)

Section titled “Role and monthly AI budget (only owners grant or remove owner; the last owner stays)”
PATCH /v1/orgs/{org}/admin/people/{person}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
person (required) path string (uuid)

Request body (JSON)

Field Type Description
role string
budget_monthly_usd number
clear_budget boolean

Responses

  • 200 The person — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Remove someone (offboarding, product.md 7.13)

Section titled “Remove someone (offboarding, product.md 7.13)”
DELETE /v1/orgs/{org}/admin/people/{person}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
person (required) path string (uuid)

Responses

  • 200 {removed, erased, computers_deleted, connections_revoked, devices_signed_out, turns_stopped} — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Bring a removed person back (archived agents, routines and conversations return)

Section titled “Bring a removed person back (archived agents, routines and conversations return)”
POST /v1/orgs/{org}/admin/people/{person}/restore

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
person (required) path string (uuid)

Responses

  • 200 The person — object

Bulk action on people: change role, set monthly budget, remove, resend invitation

Section titled “Bulk action on people: change role, set monthly budget, remove, resend invitation”
POST /v1/orgs/{org}/admin/people/bulk

At most 1,000 ids. Each id gets its own result; ids outside the caller’s organisation are refused (“not in your organisation”) and never touched. Only owners make or demote owners, an organisation keeps at least one active owner, nobody changes their own role or removes themselves, and removal runs the same offboarding as DELETE /admin/people/{person}.

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
ids (required) array of string (uuid)
action (required) role, budget, remove, resend_invite
value string \ number \

Responses

  • 200 Per-id results — AdminBulkResult
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Invite from CSV (preview with dry_run, then invite)

Section titled “Invite from CSV (preview with dry_run, then invite)”
POST /v1/orgs/{org}/admin/people/import

csv is the file’s text: rows of email, role (member | admin | owner, default member), team (created if missing) and name; a header row naming the columns is optional. Up to 2,000 rows. Every row goes through the same rules as a single invitation (valid address, not already in the organisation, only owners invite owners, refused for a domain another organisation verified); a dry run changes nothing. Invitations are offers the invitee accepts after signing in; emails go out in the background.

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
csv (required) string
dry_run boolean

Responses

  • 200 Per-row results — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Export people as CSV (same filters and sort as GET /admin/people; every matching row)

Section titled “Export people as CSV (same filters and sort as GET /admin/people; every matching row)”
GET /v1/orgs/{org}/admin/people.csv

Cells starting with = + - @ (or tab / CR) are prefixed with an apostrophe so spreadsheets don’t run them as formulas.

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
q query string
role query owner, admin, member, guest
status query active, invited, removed
team query string (uuid)
sort query string
dir query asc, desc

Responses

  • 200 CSV: name, email, role, status, teams, agents, ai_employees_managed, spend_month_usd, budget_monthly_usd, last_active_utc, joined_utc, invited_utc, removed_utc, scim
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Create a team (name, description, member_ids, budget_monthly_usd — alert only)

Section titled “Create a team (name, description, member_ids, budget_monthly_usd — alert only)”
POST /v1/orgs/{org}/admin/teams

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 201 Team — object

Change a team (members replace the list when given)

Section titled “Change a team (members replace the list when given)”
PATCH /v1/orgs/{org}/admin/teams/{team}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
team (required) path string (uuid)

Responses

  • 200 Team — object
DELETE /v1/orgs/{org}/admin/teams/{team}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
team (required) path string (uuid)

Responses

  • 200 Deleted — object

One page of agents’ metadata (status, owner or manager, connections, budget, spend, last active, working) — never content

Section titled “One page of agents’ metadata (status, owner or manager, connections, budget, spend, last active, working) — never content”
GET /v1/orgs/{org}/admin/agents

Server-side search (agent name, owner or manager, AI employee address), filters, sort and cursor paging (F1, built for 3,000+ agents). status is the agent’s own status, except stopped for a personal agent whose owner left (no pause or resume; delete it). last_active_at is the latest turn or usage record. counts are the state tabs within the other filters (all = everything but retired), kinds the kind chips within the state filter, total the rows matching every filter.

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
limit query integer
cursor query string
q query string
status query active, paused, stopped, retired Default: everything but retired
kind query personal, ai_employee
owner query string (uuid) Owner or manager
team query string (uuid) Owner or manager in this team
sort query name, owner, status, kind, spend, budget, last_active, created
dir query asc, desc

Responses

  • 200 A page of agents — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem
PATCH /v1/orgs/{org}/admin/agents/{agent}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
agent (required) path string (uuid)

Request body (JSON)

Field Type Description
budget_monthly_usd number
clear_budget boolean

Responses

  • 200 The agent’s metadata — AdminAgent

Delete a stopped agent (its owner left) with its conversations, routines and memory; spend history stays

Section titled “Delete a stopped agent (its owner left) with its conversations, routines and memory; spend history stays”
DELETE /v1/orgs/{org}/admin/agents/{agent}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
agent (required) path string (uuid)

Responses

  • 200 {deleted, id} — object
  • 404 Not found (also returned for rows the caller may not see, and for disabled features) — Problem
  • 422 Invalid input — Problem

Bulk action on agents: pause, resume, set monthly budget, delete (stopped agents only)

Section titled “Bulk action on agents: pause, resume, set monthly budget, delete (stopped agents only)”
POST /v1/orgs/{org}/admin/agents/bulk

At most 1,000 ids, a result per id; ids outside the caller’s organisation are refused and never touched. Stopped agents (owner left) can’t be paused or resumed.

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
ids (required) array of string (uuid)
action (required) pause, resume, budget, delete
value number \ null

Responses

  • 200 Per-id results — AdminBulkResult
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Export agents as CSV (same filters and sort as GET /admin/agents; formula-safe cells)

Section titled “Export agents as CSV (same filters and sort as GET /admin/agents; formula-safe cells)”
GET /v1/orgs/{org}/admin/agents.csv

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
q query string
status query active, paused, stopped, retired
kind query personal, ai_employee
owner query string (uuid)
team query string (uuid)
sort query string
dir query asc, desc

Responses

  • 200 CSV: name, kind, status, owner_or_manager, owner_or_manager_email, email_address, app_connections, spend_month_usd, budget_monthly_usd, last_active_utc, created_utc
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Kill switch for one agent (running turns stop; only an admin resumes it)

Section titled “Kill switch for one agent (running turns stop; only an admin resumes it)”
POST /v1/orgs/{org}/admin/agents/{agent}/pause

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
agent (required) path string (uuid)

Responses

  • 200 The agent’s metadata — object
POST /v1/orgs/{org}/admin/agents/{agent}/resume

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
agent (required) path string (uuid)

Responses

  • 200 The agent’s metadata — object

Give an AI employee a new manager (open cards follow; a manager_left pause lifts)

Section titled “Give an AI employee a new manager (open cards follow; a manager_left pause lifts)”
POST /v1/orgs/{org}/admin/agents/{agent}/manager

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
agent (required) path string (uuid)

Request body (JSON)

Field Type Description
person_id (required) string (uuid)

Responses

  • 200 The agent’s metadata — object
  • 422 Invalid input — Problem

Pause all agents (type the organisation’s name to confirm)

Section titled “Pause all agents (type the organisation’s name to confirm)”
POST /v1/orgs/{org}/admin/pause-all

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
confirm (required) string

Responses

  • 200 OrgSettings — object
  • 422 Invalid input — Problem

Resume all agents (agents paused one by one stay paused)

Section titled “Resume all agents (agents paused one by one stay paused)”
POST /v1/orgs/{org}/admin/resume-all

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OrgSettings — object

Spend this month — total vs budget, daily, by model and team, the top 50 people and agents by spend, alerts

Section titled “Spend this month — total vs budget, daily, by model and team, the top 50 people and agents by spend, alerts”
GET /v1/orgs/{org}/admin/spend

people / agents hold the top 50 by spend; people_total / agents_total say how many there are (page through them with /admin/spend/breakdown). daily is counted in the calling admin’s time zone, named in zone.

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OK — object

Spend this month by person, agent or team — one page, biggest first by default

Section titled “Spend this month by person, agent or team — one page, biggest first by default”
GET /v1/orgs/{org}/admin/spend/breakdown

by=person takes the people filters (q, role, status, team), by=agent the agent filters (q, status, kind, owner, team), by=team q only.

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
by query person, agent, team
limit query integer
cursor query string
q query string
team query string (uuid)
status query string
kind query personal, ai_employee
sort query string
dir query asc, desc

Responses

  • 200 A page of spend rows — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 422 Invalid input — Problem

Export spend by person, agent or team as CSV (same filters as the breakdown; formula-safe cells)

Section titled “Export spend by person, agent or team as CSV (same filters as the breakdown; formula-safe cells)”
GET /v1/orgs/{org}/admin/spend.csv

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
by query person, agent, team
q query string
team query string (uuid)
sort query string
dir query asc, desc

Responses

  • 200 CSV: month, by, name, detail, status, spend_usd, budget_monthly_usd, percent_of_budget
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Activity log export (≤ 30 days, metadata only — never prompt or reply content)

Section titled “Activity log export (≤ 30 days, metadata only — never prompt or reply content)”
GET /v1/orgs/{org}/admin/activity.csv

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
days query integer

Responses

  • 200 CSV

The organisation’s email domain, whether it’s verified (and how), auto-join, and the DNS TXT record that proves it

Section titled “The organisation’s email domain, whether it’s verified (and how), auto-join, and the DNS TXT record that proves it”
GET /v1/orgs/{org}/admin/domain

API keys: needs the admin:read scope.

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 {domain, claimable, verified, verified_at, verified_via: dns\|google\|microsoft\|dev, auto_join, record: {type: TXT, name: _teemli, host, value}, verified_elsewhere, sso_provider} — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem

Turn auto-join for the verified domain on or off

Section titled “Turn auto-join for the verified domain on or off”
PATCH /v1/orgs/{org}/admin/domain

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
auto_join boolean

Responses

  • 200 The domain status — object

Check the TXT record teemli-domain-verification=<token> at _teemli.<domain> (or the domain) and verify it. Only an admin with an address in the domain; a workspace without a domain claims its admin’s company domain

Section titled “Check the TXT record teemli-domain-verification=<token> at _teemli.<domain> (or the domain) and verify it. Only an admin with an address in the domain; a workspace without a domain claims its admin’s company domain”
POST /v1/orgs/{org}/admin/domain/verify

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 The domain status — object
  • 403 Authenticated but not allowed (e.g. unverified email, not the agent’s controller, card routed to someone else) — Problem
  • 409 Another organisation verified this domain by DNS
  • 422 The record isn’t there yet (or DNS couldn’t be reached)

Single sign-on status, redirect URI and SAML metadata URL to give the identity provider

Section titled “Single sign-on status, redirect URI and SAML metadata URL to give the identity provider”
GET /v1/orgs/{org}/admin/sso

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OK — object

Connect Google Workspace, Microsoft Entra ID, Okta / OIDC or SAML (Keycloak IdP + domain routing)

Section titled “Connect Google Workspace, Microsoft Entra ID, Okta / OIDC or SAML (Keycloak IdP + domain routing)”
PUT /v1/orgs/{org}/admin/sso

The domain must be proven first (re-audit R-2): Okta / OIDC / SAML need the domain verified by DNS; Microsoft needs the tenant that Microsoft itself resolves for the domain (its OpenID configuration; a typed tenant that doesn’t own the domain, common, or an unmanaged tenant is refused); Google Workspace is bound to the domain by hd. The proof is stored as sso.proof (dns | microsoft_tenant | google_hd); only the last two let an admin’s sign-in verify the domain. An organisation that loses its domain to a DNS proof loses its IdP too.

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Request body (JSON)

Field Type Description
provider (required) google, microsoft, okta, oidc, saml
client_id string
client_secret string
tenant_id string
issuer string
metadata_url string
display_name string

Responses

  • 200 OK — object
  • 422 Invalid input — Problem
  • 503 A dependency (e.g. the sign-in service) is unavailable — Problem

Turn single sign-on off (back to email sign-in)

Section titled “Turn single sign-on off (back to email sign-in)”
DELETE /v1/orgs/{org}/admin/sso

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OK — object

SCIM base URL, tokens (hints only) and how many people it manages

Section titled “SCIM base URL, tokens (hints only) and how many people it manages”
GET /v1/orgs/{org}/admin/scim

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 200 OK — object

New SCIM bearer token (shown once; only its sha-256 is stored)

Section titled “New SCIM bearer token (shown once; only its sha-256 is stored)”
POST /v1/orgs/{org}/admin/scim/tokens

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.

Responses

  • 201 {id, token, base_url} — object
DELETE /v1/orgs/{org}/admin/scim/tokens/{token}

API keys: not available (needs a person signed in to the app).

Parameter In Type Description
org (required) path string (uuid) The caller’s organisation id.
token (required) path string (uuid)

Responses

  • 200 Deleted — object