Skip to main content

Module admin

Module admin 

Source
Available on crate feature admin only.
Expand description

Anthropic Admin API.

Workspace-, user-, key-, and usage-management endpoints under /v1/organizations. Requires an admin API key (distinct from the regular API key used for Messages/Models/etc.) – pass it via Client::builder().api_key(...) exactly like a normal key. The wire-level x-api-key header is the same; only the key’s permissions differ.

Gated on the admin feature.

§Layout

  • organization – the authenticated organization (me).
  • invites – create / retrieve / list / delete user invites.
  • users – retrieve / list / update / delete users.
  • workspaces – workspace CRUD plus archive.
  • workspace_members – per-workspace membership.

Modules§

api_keys
API keys: retrieve / list / update.
cost_report
Cost report.
invites
Invites: create / retrieve / list / delete.
organization
GET /v1/organizations/me.
rate_limits
Rate-limit listing endpoints (organization-wide and workspace-scoped).
usage_report
Usage reports: messages + claude_code.
users
Users: retrieve / list / update / delete.
workspace_members
Workspace members: create / retrieve / list / update / delete.
workspaces
Workspaces: create / retrieve / list / update / archive.

Structs§

Admin
Top-level namespace handle for the Admin API.
ListParams
Common pagination params for after_id / before_id / limit list endpoints (invites / users / workspaces / members / api keys).

Enums§

InviteStatus
Status of a pending invite.
OrganizationRole
Organization-level user role. Forward-compatible: unknown roles fall through to Self::Other.
WorkspaceRole
Workspace-level role.
WriteOrganizationRole
Subset of OrganizationRole valid as a write value (no admin).
WriteWorkspaceRole
Subset of WorkspaceRole valid as a write value (no workspace_billing).