The error message suggests a problem logging in to Single Signon, not so much the API? See for example https://learn.microsoft.com/en-us/troubleshoot/azure/entra/entra-id/app-integration/error-code-aadsts50105-user-not-assigned-role It does not look like a message from the API, as far as I know they do not have such numbers.