---
title: "Update a service account."
method: PUT
path: "/v1/serviceAccounts/{id}"
tags: ["serviceAccountManagement"]
---

# Update a service account.

`PUT /v1/serviceAccounts/{id}`

Update an existing service account in the organization.

## Path parameters

- `id` string, required

## Request body

- UpdateServiceAccountDefinition
  - `name` string — Name of the service account.
  - `isActive` boolean — This has the value `true` if the service account is active and `false` if it has been deactivated.
  - `roleIds` string[] — List of role identifiers associated with the service account.
  - `email` string, email — New email address of the service account.

## Response `200`

The service account was successfully updated.

- ServiceAccountModel
  - `name` string, required — Name of the service account.
  - `email` string, email, required — Email address of the service account.
  - `roleIds` string[], required — List of roleIds associated with the service account.
  - `createdAt` string, date-time, required — Creation timestamp in UTC in [RFC3339](https://tools.ietf.org/html/rfc3339) format.
  - `createdBy` string, required — Identifier of the user who created the resource.
  - `modifiedAt` string, date-time, required — Last modification timestamp in UTC.
  - `modifiedBy` string, required — Identifier of the user who last modified the resource.
  - `id` string, required — Unique identifier for the service account.
  - `isActive` boolean — True if the service account is active.

## Other responses

- `default` — Operation failed with an error.

---

[API](https://skmtc.net/sumologic/apis/sumo-logic-api.md) · [All operations](https://skmtc.net/sumologic/apis/sumo-logic-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/sumologic/sumo-logic-api/revisions/18a824df1e78/schema)
