You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For my issue allowExtendedTokenAttributes seems to be the correct option. But a remaining question is how to specify the custom fields when the allowExtendedTokenAttributes option is set to true?
I found that in lib\models\token-model.js of the underline library oauth2-server some fields are filtered out and cannot be consider as custom fields.
If options.allowExtendedTokenAttributes is true any additional properties set on the object returned from Model#saveToken() are copied to the token response sent to the client.
After a long debugging session I found following configuration options:
For my issue
allowExtendedTokenAttributes
seems to be the correct option. But a remaining question is how to specify the custom fields when theallowExtendedTokenAttributes
option is set totrue
?I found that in
lib\models\token-model.js
of the underline libraryoauth2-server
some fields are filtered out and cannot be consider as custom fields.Now my responses look like this when I hit
POST /oauth/token
:How should I proceed if I want to add a new field
user_id
in the above response?Here my source code: https://github.com/nanachimi/oauthserverjs
Thanks
The text was updated successfully, but these errors were encountered: