List the usable tokens of the organization whose lifetime exceeds the given longest lifetimes, and when each would stop working if the limits applied to existing tokens: at its creation time plus the limit, or at once when that moment has passed. The console shows it before an administrator turns on cap_existing or lowers a limit while it is on. Needs security:read. At most 1000 tokens are examined. The summary is returned to every caller. The list of tokens with their names and owners only to a caller who may also read tokens (tokens:read), otherwise items is empty and details_hidden is true.
Shows tokens stopped by a proposed max lifetime. Callers without tokens:read get summary only (items: [], details_hidden: true).
Parameters
Longest lifetime of a token, in days
Longest lifetime of a token that may make security changes, in days
Responses
OK
APITokenCapPreviewResponse · 4 fields
The affected tokens. Empty when details_hidden is true.
8 fields
personalorganization2 fields
Identity ID. Null when the identity was deleted.
When the token stops working under the given limits, its creation time plus the limit.
True when that moment has passed, so the token stops at once.
True when more than 1000 tokens exceed the limits and the list shows the first 1000 by creation time.
How many of the examined tokens stop working under the given limits, and when the first one stops.
5 fields
Tokens whose stop moment has already passed, so they stop as soon as the limits are saved.
The earliest stop among the tokens that do not stop at once. Null when there is none.
True when the caller can't read tokens (tokens:read), so the response has the summary only.
Bad Request: a limit is missing or out of range
Unauthorized: no console session or API token
Forbidden: the role does not allow reading security settings
Common errors: 429 504. They mean the same for every operation, see Errors.