Authorization
回答済みHi team!
Is the enterprise authorization required in order to obtain permissions to use the API in a script? I'm trying to connect to the app, but I received a unauthorized message:
from boxsdk import DevelopmentClient
client = DevelopmentClient()
user = client.user().get()
GET https://api.box.com/2.0/users/me {'headers': {'Authorization': '---NJvy',
'User-Agent': 'box-python-sdk-2.12.0',
'X-Box-UA': 'agent=box-python-sdk/2.12.0; env=python/3.9.4'},
'params': None}
"GET https://api.box.com/2.0/users/me" 401 201
{'Date': 'Tue, 18 May 2021 18:50:06 GMT', 'Content-Type': 'application/json', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Strict-Transport-Security': 'max-age=31536000', 'Cache-Control': 'no-cache, no-store', 'WWW-Authenticate': 'Bearer realm="Service"', 'BOX-REQUEST-ID': '08886928f6d10b8eac61877c89601f647'}
{'code': '---ized',
'help_url': 'http://developers.box.com/docs/#errors',
'message': 'Unauthorized - Cannot authorize with this service',
'request_id': 'gkntfegqn5sye67o',
'status': 401,
'type': 'error'}
How long do I have to wait for that approval?
Thanks,
Hernan M
-
正式なコメント
Hi Hernan,
Yes, you are correct. A Box admin or co-admin(with the appropriate user permissions) in your enterprise will need to authorize the application. I'm not sure of your company's specific application approval process. I would reach out to someone internally.
Thanks,
Alex, Box Developer Advocate
コメントアクション
投稿コメントは受け付けていません。
コメント
3件のコメント