List the workspace's or your own AI accounts
GET /connections/ai-accounts
Requires: connections.read
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters ”org: the workspace’s accounts, used by every member’s tasks; me: the caller’s own, in this workspace.
org: the workspace’s accounts, used by every member’s tasks; me: the caller’s own, in this workspace.
Header Parameters
Section titled “Header Parameters ”Org scope: me or an org slug. Absent means the caller’s active/personal org. It selects the workspace used for permission checks and for most resource filters; operation-specific access rules still apply.
Responses
Section titled “ Responses ”Successful response.
object
object
org: the workspace’s accounts, used by every member’s tasks; me: the caller’s own, in this workspace.
A rotating sign-in; signing in again must use the same method.
How it is paid for, told when it was signed in or pasted: a subscription sign-in or a provider API key. unknown: a Claude token added before Moondeck recorded this; signing in again tells. unverified: a billing class a runner hinted, or one whose writer was not recorded.
The account’s latest usage, as an engine CLI reported it while an agent ran on it. Moondeck never asks the provider itself.
object
As the engine last reported it.
As it reads now: a warning or limit whose reset time has passed is probably_reset. Without a top-level resetsAt, the windows at or above 75% used decide (every window, when none is at or above 75%): probably_reset once all of them are past their reset.
Whether the engine says it is billing past the plan; null when it did not say.
object
The engine’s name for the window: Claude’s five_hour, seven_day, …; Codex’s primary, secondary; Cursor’s included, api.
Its reset time has passed, so the share is probably spent.
When the engine said it, epoch ms.
How long before this response the reading was taken.
The reading is more than a day old.
When usage is null because the provider does not report account limits: e.g. “unknown — Grok doesn’t report account limits”. Otherwise null.
Rolling 5-hour and 7-day turn count and spend from Moondeck’s own ledger for engines that do not report account limits. Absolute figures only; no percent and no fake limit.
object
object
object
openrouter: an OpenRouter key; bedrock: an Amazon Bedrock API key; custom: any endpoint that speaks the engine’s protocol.
The endpoint’s host.
Bedrock only: runtime (Claude Code, Codex) or mantle (Codex only).
The full URL, only in the account’s own Settings listing.
An internal-network connection: typed by hand, runs only on an owned runner serving the workspace.
object
object
object
INVALID_REQUEST — a query parameter does not match the route’s query schema, or the same parameter was sent twice. A repeat is rejected rather than resolved: guards read the first value and a parsed object would keep the last.
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan
UNAUTHORIZED — missing or invalid token, or an org-scoped API key (only user-scoped keys are accepted).
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan
PLAN_LIMIT — the workspace’s plan does not include API access. Every API-key call can return this; session-token calls never do.
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan
FORBIDDEN (lacking the required permission) or SCOPE_REQUIRED (no workspace, or a membership change in progress).
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan
SCOPE_REQUIRED — the x-uai-org scope names a workspace that does not exist, or one the caller is not a member of. The two are deliberately indistinguishable: a 403 would confirm the workspace exists.
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan
SCOPE_REQUIRED — membership reconciliation required, or membership verification unavailable.
object
object
Stable, machine-readable error code
Human-readable explanation
Present on 403 — the permission the caller lacked
Present on 402 — gated feature
Present on 402 — the plan’s cap
Present on 402 — the current plan