IMPORTANT: No additional bug fixes or documentation updates
will be released for this version. For the latest information, see the
current release documentation.
Delete service account tokens APIedit
Deletes service account tokens for a service
in a
specified namespace
.
Requestedit
DELETE /_security/service/<namespace>/<service>/credential/token/<token_name>
Prerequisitesedit
-
To use this API, you must have at least the
manage_service_account
cluster privilege.
Descriptionedit
The API response indicates whether the specified service account token is found and deleted or it is not found.
Path parametersedit
-
namespace
- (Required, string) Name of the namespace.
-
service
- (Required, string) Name of the service name.
-
token_name
- (Required, string) Name of the service account token.
Examplesedit
The following request deletes the token1
service account token from the
elastic/fleet-server
service account:
DELETE /_security/service/elastic/fleet-server/credential/token/token42
If the service account token is successfully deleted, the request returns
{"found": true}
. Otherwise, the response will have status code 404
and
found` will be set to false
.
{ "found" : true }