Rotate Application Secret
A 2-step recipe with Microsoft Entra. We can help you get access.
Recipe · 2 steps
Rotate Application Secret
with Microsoft Entra · Identity & Access Management
Add a new client secret then revoke the prior secret by keyId.
- Add a new password credential to the application and capture the one-time secretText from the response.
- Remove the prior password credential by keyId now that the replacement is in place.
What you'll need to have ready
- accessToken: OAuth 2.0 bearer token with Application.ReadWrite.All.
- applicationId: Object id of the application (not the appId).
- newSecretDisplayName: Friendly name for the new password credential.
- endDateTime: Expiry timestamp for the new secret (ISO 8601 date-time).
- oldKeyId: keyId of the existing password credential to remove.
For your developer
Arazzo workflow microsoft-entra:rotate-application-secret, 2 operations: addApplicationPassword → removeApplicationPassword. Specs on APIs.io.