Skip to main content

Update Token

This endpoint allows you to update the expiration date of an active API Token.

Endpoint

PATCH /user/v1/users/{user}/access/{access}/tokens/{token}

Parameters

NameLocationRequiredTypeDefault valueDescription
userURLYesStringThe user identifier
accessURLYesIntegerThe access identifier
tokenURLYesIntegerThe token identifier
expires_atBodyNoDatetimeThe token expiration datetime

Response

Updated Token information.

Example Request

PATCH /user/v1/users/c0b48140-34cb-4187-acd7-aaa830dc97f9/access/127/tokens/10
Body
{
"expires_at": "2024-01-01 00:00:00"
}

Example Response

{
"message": "OK",
"data": {
"id": 1,
"token": "ec21a22e-d2e9-49d0-bbff-50eeef5e36b5",
"expires_at": "2024-01-01T00:00:00+00:00",
"created_at": "2023-09-16T01:20:27+00:00",
"updated_at": "2023-10-16T15:40:35+00:00"
}
}