Refresh token request doesn't include custom query parameters by default. #514
Labels
bug report
This issue reports a suspect bug or issue with the SDK itself
bug
This points to a verified bug in the code
Describe the problem
If you happen to have refresh tokens enabled and come back after token expiry the initial request will be missing the custom query parameters you specified within your client initialization, thereby breaking any rule that relies on them.
What was the expected behavior?
Silent auth requests involving refresh tokens should probably include any custom parameters you've specified by default. This includes both manually calling
getTokenSilently
and the initialcheckSession
call invoked bycreateAuth0Client
.Reproduction
createAuth0Client
options, saytenant_id: 'test'
tenant_id
field as it isn't being sent.Workaround
I'm aware I can work around this by calling
checkSession
manually and passing in the custom options, but I'd argue this is a poor development experience, as you'd expect the custom query params set on theAuth0Client
to be sent to your rule regardless of if refresh tokens are enabled or not.Environment
auth0-spa-js
used: 1.10The text was updated successfully, but these errors were encountered: