Skip to content

Commit

Permalink
fix: document ability to update expires_at on patch /tokens endpoint (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
amkera authored Jan 23, 2023
1 parent 1d19691 commit acdfe8a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions docs/api/tokens/tokens.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ func main() {
| `search_indexes` | false | _array_ | `null` | Array of [expressions](/docs/expressions/search-indexes) used to generate indexes to be able to search against. |
| `fingerprint_expression` | false | _string_ | <code>{{ data &#124; stringify }}</code> | [Expressions](/docs/expressions/fingerprints) used to fingerprint your token. |
| `deduplicate_token` | false | _bool_ | `null` | Whether the token is deduplicated on creation. |
| `expires_at` | false | _string_ | `null` | ISO8601 compatible Token expiration DateTime. See [Token Expiration](#token-expiration) for more details. |
| `expires_at` | false | _string_ | `null` | ISO8601 compatible Token expiration DateTime. See [Token Expiration](/docs/api/tokens/#token-expiration) for more details. |

<Alert type={Alerts.WARNING}>
Never reveal sensitive information in the <code>id</code> of your token. See
Expand Down Expand Up @@ -732,6 +732,7 @@ func main() {
| `search_indexes` | false | _array_ | Replace | Array of [expressions](/docs/expressions/search-indexes) used to generate indexes to be able to search against. |
| `fingerprint_expression` | false | _string_ | Replace | [Expressions](/docs/expressions/fingerprints) used to fingerprint your token. |
| `deduplicate_token` | false | _bool_ | Replace | Whether the token is deduplicated on creation. |
| `expires_at` | false | _string_ | Replace | ISO8601 compatible Token expiration DateTime. See [Token Expiration](/docs/api/tokens/#token-expiration) for more details. |

### Response

Expand Down Expand Up @@ -901,7 +902,7 @@ Returns [an error](/docs/api/errors) if the token failed to delete.
| `modified_at` | _date_ | (Optional) Last modified date of the token in ISO 8601 format |
| `search_indexes` | _array_ | (Optional) Array of search index [expressions](/docs/expressions/search-indexes) used when creating the token. |
| `fingerprint_expression` | _string_ | (Optional) An [expression](/docs/expressions/fingerprints) defining the value to fingerprint when creating the token. |
| `expires_at` | _string_ | (Optional) The [token expiration](#token-expiration) date. |
| `expires_at` | _string_ | (Optional) The [token expiration](/docs/api/tokens/#token-expiration) date. |

### Token Data Validations

Expand All @@ -924,7 +925,7 @@ Returns [an error](/docs/api/errors) if the token failed to delete.
### Token Expiration

By default a created token will not expire, however, users can optionally set the `expires_at` property with an ISO8601 `DateTime` when creating a token to determine its expiration date.
An expired token is **deleted** from the tenant up to **1 hour** after it's expiration time.
An expired token is **deleted** from the tenant up to **1 hour** after its expiration time.

### Expiration Date Formats

Expand Down

1 comment on commit acdfe8a

@vercel
Copy link

@vercel vercel bot commented on acdfe8a Jan 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.