1

I'm trying to make some GET calls through Postman to the following endpoint: https://api.xero.com/api.xro/2.0/Reports/BalanceSheet

getting this error:

{"title":"Unauthorized","status":401,"detail":"AuthorizationUnsuccessful","instance":"674c99d2-0ae3-4940-b23b-aec74cef79ea"}

The docs say this is a user roles issue, and suggests "view reports" access is off, but I'm pretty sure that's all set up correctly: screenshot of user role options

It works fine through the API previewer, so I can't see what I'm missing.

Any help?

If it makes a difference, I'm using Oauth2.0 route.

HarryDev
  • 13
  • 3

1 Answers1

3

You'll likely be missing the accounting.reports.read scope.

During the authorisation process, when you direct your user to the https://login.xero.com/identity/connect/authorize... url, try including accounting.reports.read in scope query parameter (along with your existing scopes, of course).

rustyskates
  • 856
  • 4
  • 10