Update Service Account
api/admin/service_accounts/update
Nearest release: v2.1.245, published an hour after this site recorded the change. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.
api/admin/service_accounts/update Changed · +19 / -16 lines
# Update Service Account ## Path parameters ## Headers ## Body parameters ## Returns ## Example ### Response (200) ## Update Service Account ### Path Parameters ### Header Parameters ### Body Parameters ### Returns ### Example #### Response
---- -title: Update Service Account -url: https://platform.claude.com/docs/en/api/admin/service_accounts/update ---- +# Update Service Account -## Update Service Account +**POST** `/v1/organizations/service_accounts/{service_account_id}` -**post** `/v1/organizations/service_accounts/{service_account_id}` - Update a service account. Only `description` and `organization_role` are mutable; `name` cannot be
interactive credential (a user OAuth token or a Console session). Admin API keys are not accepted. -### Path Parameters +## Path parameters - `service_account_id: string` ID of the service account to update. -### Header Parameters +## Headers - `"anthropic-beta": optional array of string`
To use multiple betas, use a comma separated list like `beta1,beta2` or specify the header multiple times for each beta. -### Body Parameters +## Body parameters - `description: optional string or null` Replaces the description. Omit to leave unchanged; send `null` to clear (the field is stored as an empty string). + maxLength: 2000 + - `organization_role: optional "admin" or "developer" or null` Replaces the org-level role. Omit or send `null` to leave unchanged.
- `"developer"` -### Returns +## Returns -- `ServiceAccount object { id, archived_at, archived_by_actor_id, 8 more }` +- `ServiceAccount object` Named non-human identity within the caller's organization.
If set, this service account is archived. + format: date-time + - `archived_by_actor_id: string or null` Tagged ID (`user_`/`svac_`) of the actor that archived this service account.
When this service account was created. + format: date-time + - `created_by_actor_id: string or null` Tagged ID (`user_`/`svac_`) of the actor that created this service account.
- `type: "service_account"` - - `"service_account"` + default: service_account - `updated_at: string` When this service account was last updated. + format: date-time + - `updated_by_actor_id: string or null` Tagged ID (`user_`/`svac_`) of the actor that last updated this service account. -### Example +## Example -```http +```bash curl https://api.anthropic.com/v1/organizations/service_accounts/$SERVICE_ACCOUNT_ID \ -H 'Content-Type: application/json' \ -H 'anthropic-version: 2023-06-01' \
-d '{}' ``` -#### Response +### Response (200) ```json {