Rotates the authentication token for a paired device. After rotation, the device will need to re-authenticate with the new token. You can optionally update the device scope during rotation.
This endpoint uses deviceId in the URL path (not requestId). This is the identifier of an already-paired device.
The unique identifier of the paired device whose token should be rotated.
The role to assign to the device. Valid values: agent, user, admin.
Optional scope restrictions for the device token.
curl -X POST https://alfred.black/api/v1/devices/dev_a1b2c3d4e5/rotate \
-H "Authorization: Bearer alf_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"role": "agent",
"scope": "vault:read vault:write"
}'
{
"message": "Token rotated"
}
A status message confirming the token was rotated.