Hi,
While doing device registration for push notification i am getting this error..
{"error":"unauthorized","timestamp":1470035549951,"duration":0,"error_description":"Subject does not have permission to access this resource","exception":"org.apache.usergrid.rest.exceptions.SecurityException"}
I am using
ApigeeClientResponse *response = [dataClient setDevicePushToken: deviceToken forNotifier: notifier];
Base Url is - https://amer-apibaas-prod.apigee.net/appservices/{org}/{app}/device
Please do let me know how to fix this issue.
Thanks
Solved! Go to Solution.
@Partha Sarathi Barik , Welcome to Apigee Community.
Looks like a permission issue for me. Make sure user role has permissions set for /devices or /device collection you are trying to access. You can set permissions to user role by navigating to BaaS UI, Users -> Roles in left side menu navigation bar. See example screenshot below,
Also, make sure user trying to access API is also added to above userrole. Keep us posted if any. For more details refer Apigee BaaS Docs.