We are getting the below mentioned error while trying to access data from the Orders collection
{
“error” : {
“name” : “Error” ,
“errorGroup” : “User” ,
“code” : “WD_PERMISSION_DENIED”
}
}
Is there security related configuration that we need to take care to access data from Orders collection?
Hello. Are you using this ID for the orders collection: “Stores/Orders”
You can query the orders collection but there is a data limit which can cause errors as well. You can read more about working with that collection in this article.
The read permissions are admin so you should be able to use the suppressAuth in options in a backend file if you need to manipulate the query but you cannot change the default permissions of this collection.
While I have shared the code above here is our use case :
We want to access Orders (Stores/Orders) periodically from a back-end server application with no UI. We want to do additional processing for our internal downstream application. Our current approach is to expose Stores/Orders collection using http-functions, which can be consumed by our back-end server to pull the Orders data. Please suggest if this is the right approach or is there any alternative approach.