cURL
curl --request POST \ --url https://api.example.com/api/v1/organizations/{organizationID}/serviceaccounts/{serviceAccountID}/rotate \ --header 'Authorization: Bearer <token>'
{ "metadata": { "id": "ee45f34b-9685-40d8-8724-23c31252ca46", "name": "my-service-account", "organizationId": "d4600d6e-e965-4b44-a808-84fb2fa36702", "creationTime": "2024-05-31T14:11:00Z", "provisioningStatus": "provisioned", "healthStatus": "healthy" }, "spec": { "groupIDs": [ "f2000047-19f8-426e-93b9-9f0a5bfa0edd" ] }, "status": { "expiry": "2025-03-14T16:10:00Z", "accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" } }
Rotates a service account’s access token. The returned access token can only be read once.
Operation requires OAuth 2.0 bearer token authentication.
An organization ID.
A service account ID.
A service account creation.
A new service account.
Metadata required by organization scoped resource reads.
Show child attributes
A valid Kubernetes label value, typically used for resource names that can be indexed in the database.
The unique resource ID.
The time the resource was created.
The provisioning state of a resource.
unknown
provisioning
provisioned
deprovisioning
error
The health state of a resource.
healthy
degraded
The organization identifier the resource belongs to.
The resource description, this optionally augments the name with more context.
A list of tags.
A unique tag name.
The value of the tag.
The user who created the resource.
The time a resource was updated.
The user who updated the resource.
The time the resource was deleted.
A service account specification.
A list of group IDs.
A group ID.
A service account status.
When the service token is due to expire.
A long lived access token that can be exchanged for an API access token.