Method RotateSecret(string)
Rotates the client_secret of a confidential OAuth application. Returns the
new plaintext secret once in the response body; subsequent reads will not
expose it (only BCrypt hash is stored). The previous secret is invalidated
immediately — any client_credentials/refresh flow holding the old value will get
401 from the next call onward.
Declared before so that the literal rotate-secret
segment cannot be swallowed by the {id} template (the id would
otherwise contain the slash). ControllerRegistry also prefers literal
over template during resolution; the ordering is belt-and-braces protection.
[HttpPost("{id}/rotate-secret")]
public Task<object?> RotateSecret(string id)