Cannot access Event API
AnsweredReceiving Forbidden error on calling Event API using AppToken as authorization
https://api.box.com/2.0/events
{"type":"error","status":403,"code":"forbidden","help_url":"http:\/\/developers.box.com\/docs\/#errors","message":"Forbidden","request_id":"1bqnjcgjq1bum4nw"}
How to give access to my app with app token to use events API,?
-
Official comment
It looks like you've selected AppToken Authorization. This type of authentication is only for use with our preview services and has limited API capabilities. The accessible endpoints can be found here: https://developer.box.com/guides/authentication/app-token/endpoints/
In order to interact with the events API you will need to select a different authentication type.
Comment actions -
Thanks!
Hope I'm not hijacking the post, but maybe others will find my question related to this helpful;
I get the same 403 forbidden error while using JWT auth with my application (authenticating as the service account of my app via the .json file) on the events endpoint. But using other endpoints with my app goes fine. Then, when I use the developer token (and authenticate as my current user) the events endpoint returns successfully.Are you sure about the JWT support? Or are there any prereqs. for this auth method combined with this endpoint?
-
When you generate a developer token it will be associated with whatever user is logged into the developer console when you click the generate button. The events endpoint can only be used by admins or co-admins with proper permissions, so if this user does not have those privileges you'll receive a 403. This is noted here: https://developer.box.com/reference/get-events/.
Hope that helps!
Please sign in to leave a comment.
Comments
6 comments