Access token accepted but search API not returning file that is there

新規投稿

コメント

2件のコメント

  • JohannesMaria

    Hi dh33,

     

    the result you are seeing is the content of the service account, which is currently empty, so everything is fine. With JWT each app is acting as an API user, and this account we call service account. You can read all about it here:

     

    https://developer.box.com/v2.0/docs/service-account

     

    Now to to access your own account, the account has to be part of your enterprise and you do this by casting a as-user call with your user id (from the documentation above)

     

    • Access to Any User - you can generate access tokens for both Managed Users and App Users or to make server-side calls using the As-User header to impersonate a user.

    In order to be able to do these calls you have to grant the app this  ability, which you do on the configuration site of your app in the dev console.

     

    I hope this helps.

     

    0
    コメントアクション パーマリンク
  • dh33

    Thank you for the reply. It was helpful to know that I am at least generating the User Access token properly and should expect to see the results I am getting.

     

    What confuses me is using the User Access Token to access another Box.com account. If I have a Box.com user who has authorized my app (via Box.com App Authorization) does that mean this user is now part of my Enterprise? What do I need to do to be able to call the Search API endpoint to search the account of someone who has authorized my app to access their account? Do you have an example?

    0
    コメントアクション パーマリンク

サインインしてコメントを残してください。