Admin
Administrative endpoints for managing organizations and users at the system level. All admin endpoints are mounted at /api/v2/admin.
Danger: Admin endpoints modify system state. Use with caution in production. These endpoints require admin privileges -- requests from non-admin users receive a 403 Forbidden response.
Dashboard statistics
GET /api/v2/admin/stats
Returns aggregate statistics for the admin dashboard.
Authentication: API key (admin required)
import requests
response = requests.get(
"https://jaot.io/api/v2/admin/stats",
headers={"Authorization": "Bearer ok_live_admin_key..."}
)
stats = response.json()
print(f"Organizations: {stats['total_organizations']}")
print(f"Users: {stats['total_users']}")
print(f"Executions: {stats['total_executions']}")
print(f"Active orgs (7d): {stats['active_organizations_7d']}")Response (200)
{
"total_organizations": 42,
"total_users": 156,
"total_executions": 8920,
"active_organizations_7d": 18
}Response fields
| Field | Type | Description |
|---|---|---|
total_organizations | int | Total registered organizations |
total_users | int | Total registered users |
total_executions | int | Total solver executions across all orgs |
active_organizations_7d | int | Organizations with activity in the last 7 days |
List organizations
GET /api/v2/admin/organizations
List all organizations in the system with pagination.
Authentication: API key (admin required)
Query parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
page | int | 1 | Page number |
page_size | int | 20 | Items per page |
search | string | -- | Search by organization name |
response = requests.get(
"https://jaot.io/api/v2/admin/organizations",
headers={"Authorization": "Bearer ok_live_admin_key..."},
params={"search": "acme", "page_size": 10}
)
data = response.json()
for org in data["items"]:
print(f"{org['name']} (plan={org['plan']})")Organization overview
GET /api/v2/admin/organizations/{organization_id}/overview
Returns a single, read-only aggregate of everything about one organization — its configuration and limits, execution statistics, and its members, API keys, models and most-recent executions. Designed for "viewing" an organization without editing it. No state is modified.
Authentication: API key (admin required)
response = requests.get(
"https://jaot.io/api/v2/admin/organizations/org_b7e4d1a0/overview",
headers={"Authorization": "Bearer ok_live_admin_key..."},
)
data = response.json()
org = data["organization"]
print(f"{org['name']} (plan={org['plan']}, BYOK={org['byok_configured']})")
print(f"Users: {data['counts']['users']}, executions: {data['counts']['executions']}")
for user in data["users"]:
print(f" - {user['name']} ({user['email']}) role_admin={user['is_admin']}")Response (200)
| Field | Type | Description |
|---|---|---|
organization | object | Org config & limits: plan, rate_limit_per_minute, rate_limit_per_day, ai_builder_enabled, byok_configured (bool — whether the org has its own LLM key; the key is never returned), max_private_plugins, is_active, is_verified, is_public_profile, slug, website_url, created_at, owner_user_id |
owner | object | null | The owning user (id, name, email) |
counts | object | users, active_users, api_keys, active_api_keys, models, executions |
execution_stats | object | total, completed, failed, running |
users | array | The org's users (id, name, email, is_admin, can_build_plugins, is_active, created_at) |
api_keys | array | The org's API keys — key_prefix only; the secret is never returned |
models | array | The org's models (display_name, source: marketplace/custom, total_executions, last_executed_at) |
recent_executions | array | Up to 20 most-recent solve executions |
List users
GET /api/v2/admin/users
List all users in the system with pagination.
Authentication: API key (admin required)
Query parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
page | int | 1 | Page number |
page_size | int | 20 | Items per page |
search | string | -- | Search by name or email |
response = requests.get(
"https://jaot.io/api/v2/admin/users",
headers={"Authorization": "Bearer ok_live_admin_key..."},
params={"search": "alice"}
)
data = response.json()
for user in data["items"]:
print(f"{user['name']} ({user['email']}) - org: {user['organization_id']}")List executions across the platform
GET /api/v2/admin/executions
Every model execution on the platform, newest first, with the organization each one belongs to. This is the admin view: GET /api/v2/models/executions/all returns only the caller's own organization.
Authentication: API key (admin required)
Query parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
page | int | 1 | Page number |
page_size | int | 20 | Items per page (max 100) |
status | string | -- | completed, failed, running, pending |
origin | string | -- | How the run was created |
organization_id | string | -- | Narrow to one organization |
The response carries a stats block alongside the page: total and avg_execution_time_ms are computed in the database over everything the filters select, not over the rows served, so they do not change when you turn the page.
The payloads are not included. Read input_data and result_data from GET /api/v2/models/executions/{id}.
response = requests.get(
"https://jaot.io/api/v2/admin/executions",
headers={"Authorization": "Bearer ok_live_admin_key..."},
params={"status": "failed"}
)
data = response.json()
print(f"{data['stats']['total']} failed runs, {data['stats']['avg_execution_time_ms']:.0f} ms on average")
for run in data["items"]:
print(f"{run['id']} - {run['organization_name']} - {run['model_name']}")Errors
| Status | Description |
|---|---|
| 401 | Missing or invalid API key |
| 403 | User is not an admin (is_admin must be true) |
| 404 | Organization or user not found |