Rotates the secret API key for your account, generating a new key immediately. The previous key remains valid until expire_after_in_seconds has elapsed, giving you time to update your integrations. Once the expiry period passes, the old key is revoked and any requests using it will return 401 Unauthorized.
Security
JWT
POST
curl -i -X POST \
https://api.glomopay.com/api/v1/api-keys/rotate \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"expire_after_in_seconds": 3600
}'API key rotated successfully
Response
{ "secret_key": "<NEW_JWT>", "previous_key_expires_at": "2026-05-13T12:10:57Z" }