XeroAPI / xero-ruby

Xero Ruby SDK for OAuth 2.0 generated from XeroAPI/Xero-OpenAPI
http://developer.xero.com/
MIT License
58 stars 91 forks source link

Update example scopes in README #236

Closed dimasusername closed 2 years ago

dimasusername commented 2 years ago

Array notation suggests these are supposed to be passed as an array. But in fact scopes should be passed as a string.

URI.encode_www_form transforms that into a repeating scopes parameter, e.g. [...]&scopes=marketplace.billing&scopes=openid[...], which ends up passing incorrect scopes to the API.

Passing a string results in the following scopes format: [...]&scopes=marketplace.billing+openid[...] which is correctly interpreted by the API.