Organization
Get Current Organization
client.organization.retrieve(options?): OrganizationInfoRetrieve information about the organization associated with the authenticated API key.
Models
OrganizationAPI Keys
List API Keys
client.organization.apiKeys.list(query?, options?): Page<APIKey>Retrieve API Key (Admin API)
client.organization.apiKeys.retrieve(apiKeyID, options?): APIKeyRetrieve information about a single API key in your organization, looked up by its ID. This Admin API endpoint requires an Admin API key, is intended for programmatic key management, and never returns the key's secret value. To view or create your own API keys, go to API keys in the Claude Console.
Update API Key
client.organization.apiKeys.update(apiKeyID, body, options?): APIKeyOrganizationExternal Keys
Create External Key
client.organization.externalKeys.create(body, options?): ExternalKeyCreate an external key config owned by the caller's organization.
List External Keys
client.organization.externalKeys.list(query?, options?): PageCursor<ExternalKey>List external key configs in the caller's organization.
Get External Key
client.organization.externalKeys.retrieve(externalKeyID, options?): ExternalKeyRetrieve a single external key config in the caller's organization by ID.
Update External Key
client.organization.externalKeys.update(externalKeyID, body, options?): ExternalKeyPartially update an external key config. Omitted fields are left unchanged.
Delete External Key
client.organization.externalKeys.delete(externalKeyID, options?): ExternalKeyDeleteResponseDelete an external key config.
Validate External Key
client.organization.externalKeys.validate(externalKeyID, options?): ExternalKeyValidateResponseValidate an external key config against the customer's KMS.
OrganizationFederationIssuers
Create Federation Issuer
client.organization.federation.issuers.create(body, options?): FederationIssuerRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
List Federation Issuers
client.organization.federation.issuers.list(query?, options?): PageCursor<FederationIssuer>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Get Federation Issuer
client.organization.federation.issuers.retrieve(federationIssuerID, options?): FederationIssuerRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Update Federation Issuer
client.organization.federation.issuers.update(federationIssuerID, body, options?): FederationIssuerRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Archive Federation Issuer
client.organization.federation.issuers.archive(federationIssuerID, options?): FederationIssuerRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationFederationRules
Create Federation Rule
client.organization.federation.rules.create(body, options?): FederationRuleRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
List Federation Rules
client.organization.federation.rules.list(query?, options?): PageCursor<FederationRule>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Get Federation Rule
client.organization.federation.rules.retrieve(federationRuleID, options?): FederationRuleRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Update Federation Rule
client.organization.federation.rules.update(federationRuleID, body, options?): FederationRuleRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Archive Federation Rule
client.organization.federation.rules.archive(federationRuleID, options?): FederationRuleRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationFederationRulesWorkspaces
Add Federation Rule Workspace
client.organization.federation.rules.workspaces.add(federationRuleID, body, options?): FederationRuleWorkspaceRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
List Federation Rule Workspaces
client.organization.federation.rules.workspaces.list(federationRuleID, query?, options?): PageCursor<FederationRuleWorkspace>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Remove Federation Rule Workspace
client.organization.federation.rules.workspaces.remove(workspaceID, params, options?): WorkspaceRemoveResponseRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationInvites
Create Invite
client.organization.invites.create(body, options?): OrganizationInviteInvite a user to join the organization by email.
List Invites
client.organization.invites.list(query?, options?): Page<OrganizationInvite>List the organization's invites.
Get Invite
client.organization.invites.retrieve(inviteID, options?): OrganizationInviteRetrieve an invite by ID.
Delete Invite
client.organization.invites.delete(inviteID, options?): InviteDeleteResponseDelete a pending invite.
OrganizationService Accounts
Create Service Account
client.organization.serviceAccounts.create(body, options?): ServiceAccountRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
List Service Accounts
client.organization.serviceAccounts.list(query?, options?): PageCursor<ServiceAccount>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Get Service Account
client.organization.serviceAccounts.retrieve(serviceAccountID, options?): ServiceAccountRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Update Service Account
client.organization.serviceAccounts.update(serviceAccountID, body, options?): ServiceAccountRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Archive Service Account
client.organization.serviceAccounts.archive(serviceAccountID, options?): ServiceAccountRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationService AccountsWorkspaces
Add Workspace To Service Account
client.organization.serviceAccounts.workspaces.add(serviceAccountID, body, options?): ServiceAccountWorkspaceMemberRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
List Workspaces For Service Account
client.organization.serviceAccounts.workspaces.list(serviceAccountID, query?, options?): PageCursor<ServiceAccountWorkspaceMember>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Remove Workspace From Service Account
client.organization.serviceAccounts.workspaces.remove(workspaceID, params, options?): WorkspaceRemoveResponseRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationUsers
List Users
client.organization.users.list(query?, options?): Page<OrganizationUser>List the organization's members.
Get User
client.organization.users.retrieve(userID, options?): OrganizationUserRetrieve a member of the organization by user ID.
Update User
client.organization.users.update(userID, body, options?): OrganizationUserUpdate a member's organization role.
Remove User
client.organization.users.remove(userID, options?): UserRemoveResponseRemove a member from the organization.
OrganizationWorkspaces
List Workspaces
client.organization.workspaces.list(query?, options?): Page<Workspace>Create Workspace
client.organization.workspaces.create(body, options?): WorkspaceGet Workspace
client.organization.workspaces.retrieve(workspaceID, options?): WorkspaceUpdate Workspace
client.organization.workspaces.update(workspaceID, body, options?): WorkspaceArchive Workspace
client.organization.workspaces.archive(workspaceID, options?): WorkspaceOrganizationWorkspacesRate Limits
List Workspace Rate Limits
client.organization.workspaces.rateLimits.list(workspaceID, query?, options?): PageCursor<WorkspaceRateLimit>List a workspace's rate limits.
OrganizationWorkspacesMembers
List Workspace Members
client.organization.workspaces.members.list(workspaceID, query?, options?): Page<WorkspaceMember>Create Workspace Member
client.organization.workspaces.members.add(workspaceID, body, options?): WorkspaceMemberGet Workspace Member
client.organization.workspaces.members.retrieve(userID, params, options?): WorkspaceMemberUpdate Workspace Member
client.organization.workspaces.members.update(userID, params, options?): WorkspaceMemberDelete Workspace Member
client.organization.workspaces.members.remove(userID, params, options?): MemberRemoveResponseOrganizationWorkspacesService Accounts
List Service Account Workspace Members
client.organization.workspaces.serviceAccounts.list(workspaceID, query?, options?): PageCursor<ServiceAccountWorkspaceMember>Requires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Create Service Account Workspace Member
client.organization.workspaces.serviceAccounts.add(workspaceID, body, options?): ServiceAccountWorkspaceMemberRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Get Service Account Workspace Member
client.organization.workspaces.serviceAccounts.retrieve(serviceAccountID, params, options?): ServiceAccountWorkspaceMemberRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Update Service Account Workspace Member
client.organization.workspaces.serviceAccounts.update(serviceAccountID, params, options?): ServiceAccountWorkspaceMemberRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
Delete Service Account Workspace Member
client.organization.workspaces.serviceAccounts.remove(serviceAccountID, params, options?): ServiceAccountRemoveResponseRequires an OAuth access token with the org:admin scope, from ant auth login --scope org:admin or a workload identity federation rule; Admin API keys are not accepted. See Manage WIF with the Admin API.
OrganizationRate Limits
List Organization Rate Limits
client.organization.rateLimits.list(query?, options?): PageCursor<OrganizationRateLimit>List Messages API rate limits for your organization.
OrganizationCompliance Settings
Get Compliance Settings
client.organization.complianceSettings.retrieve(options?): OrganizationComplianceSettingsRetrieve your organization's Compliance Settings.
Update Compliance Settings
client.organization.complianceSettings.update(body, options?): OrganizationComplianceSettingsUpdate your organization's Compliance Settings.