Skip to main content

personal_access_tokens

Creates, updates, deletes, gets or lists a personal_access_tokens resource.

Overview

Namepersonal_access_tokens
TypeResource
Idaws.workmail.personal_access_tokens

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
date_createdstring (date-time)The date when the Personal Access Token was created.
date_last_usedstring (date-time)The date when the Personal Access Token was last used.
expires_timestring (date-time)The date when the Personal Access Token will expire.
namestringThe name of the Personal Access Token. (pattern: <code>[^\x00-\x1F\x7F\x3C\x3E\x5C]+</code>)
personal_access_token_idstringThe ID of the Personal Access Token. (pattern: <code>[a-zA-Z0-9_-]+</code>)
scopesarrayLists all the Personal Access Token permissions for a mailbox.
user_idstringThe user ID of the WorkMail user associated with the Personal Access Token.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_personal_access_tokensselectregionReturns a summary of your Personal Access Tokens.
delete_personal_access_tokendeleteregionDeletes the Personal Access Token from the provided WorkMail Organization.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Returns a summary of your Personal Access Tokens.

SELECT
date_created,
date_last_used,
expires_time,
name,
personal_access_token_id,
scopes,
user_id
FROM aws.workmail.personal_access_tokens
WHERE region = '{{ region }}' -- required
;

DELETE examples

Deletes the Personal Access Token from the provided WorkMail Organization.

DELETE FROM aws.workmail.personal_access_tokens
WHERE region = '{{ region }}' --required
;