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
The sample code passes a JSON object to axios which expects a string.
The solution is to correctly encode the parameters.
This problem should apply to all Node.js examples on the documentation page.
I tested this only at the device authorization endpoint and token endpoint.
The request sent to the device authorization endpoint using the sample code looks as follows.
Note, the data is a stringified JSON and not correctly encoded.
Description
Device Authorization Flow Node.js sample code is not encoding data correctly.
The sample code passes a JSON object to axios which expects a string.
The solution is to correctly encode the parameters.
This problem should apply to all Node.js examples on the documentation page.
I tested this only at the device authorization endpoint and token endpoint.
Here is one sample code of the documentation:
The request sent to the device authorization endpoint using the sample code looks as follows.
Note, the data is a stringified JSON and not correctly encoded.
The error repsonse form the device authorization endpoint
Here is an example from the axios documentation to correctly encode the body:
Reproduction
Create a Native Application and follow the tutorial for Device Authorization Flow.
Environment
The text was updated successfully, but these errors were encountered: