Loading…
Revokes one of the caller's own sessions. Passing the id of the session making the request is allowed and has the same effect as POST /api/v1/auth/logout.
auth:sanctum)| Name | Type | Required | Description |
|---|---|---|---|
token | integer | Yes | Session id, from GET /api/v1/auth/sessions data[].id |
{
"message": "Session revoked successfully."
}
The revoked token is deleted; any further request with it returns 401.
| Status | Description | Reference |
|---|---|---|
| 401 | Not authenticated | Authentication error |
| 404 | No such session, or it belongs to another user — the two are indistinguishable | Not found error |