I apologize if this has been answered multiple times, but I am upgrading from the old version of the SDK to the new one.
In the old one, I could authenticate with an API Key (no oauth)…but it seems that I can’t use that key now? I am asking if I need to implement OAUTH before I can start using the new SDK? I am able to use the SDK to pull payments, locations, and catalogs…but it does not seem to like me doing order searches.
Any insight would be fantastic.
"detail": "You have insufficient permissions to perform that action.",
If your using the personal access token you definitely have all the permissions for the Orders API. Only OAuth access token that don’t have
ORDERS_WRITE will throw this error. Is this integration for one Square seller or for many Square sellers?
I am not using a personal token, it’s the token for the production account that we have used for a long time. Could I be setting something up wrong?
That would be the personal access token for the application. Thats what it’s called when you look at the credentials in the Developer Dashboard. What’s your application ID?
I found the “issue”. There is a location that, when I tried to query it, it throw the unautorized error.
Is there anyway I can either trap which Location causes the problem when I do a “batch” query for orders or do I have to do each location one by one for an application?
Glad to hear you figured it out. If you want to know all the locations you can pull data from with the token you can call ListLocations. This will give you all the locations that token has access too.