can't able to open folder using access token

新規投稿

コメント

3件のコメント

  • Peter Christensen

    HI Akanksha

    Most likely you are getting a token for a user that does not have access to the folder in question. An access token always belongs to a user and if you have used the API you probably have a server side app like a JWT or Client Credentials Grant app. When you generate a token for these you will get a token for the service account or automation user generated with the app. You can check this by running this API and check the details of the user returned. https://developer.box.com/reference/get-users-me/

    If the folder is owned by your 'standard' box user you can either generate a token for that user, use the 'as-user' header or collaborate the automation user onto the folder. You can see the loginID of the automation user in the general settings of your app in the developer console.. It will look like 'AutomationUser_123456_abcdef@boxdevedition.com 

    Hope this helps

    Peter Christensen, Platform Solutions Engineer, Box

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

    Hi Peter ,
    can you let me know how can we generate access token using client credentials grant app ? 
    i tried using this approach. but how can we get auth code to pass in the header?

     

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

    Hi

    With client credentials grant you don't need the auth code as it is a server side authentication.

    See this guide: https://developer.box.com/guides/authentication/client-credentials/ which has some examples

    Rgds,

    Peter

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

投稿コメントは受け付けていません。