Pass a dynamic encoded value as a state parameter to upstream IdP

Problem statement

I am connecting to an IdP that requires passing encoded data in the state parameter dynamically. Is this supported?

Solution

We cannot support providing a customized state to upstream IdPs, as the state value needs to be created and consumed by the Auth0 authentication server on callback.

The state should be considered an opaque value to the IdP as per the specification:

“An opaque value used by the client to maintain state between the request and callback”