'Invalid token' when using JWT
I've gone through the JWT OAuth process. I'm trying to use the 'File Upload' widget that Box.com provides.
I created a new 'App User' using my Enterprise JWT. This user shows up in my admin panel. I gave the user access to upload to a folder.
I then generate an access token by building a JWT that has a 'box_sub_type' of 'user' and a 'sub' of the user ID created.
Finally I have this code on my page:
I've tried using '0' as the folder ID, as well as a custom folder. In the console of Firefox, I get this when I try to upload:
Bearer realm="Service", error="invalid_token", error_description="The access token provided is invalid."
I've gone through everything I can think of, and I'm not able to figure out what's wrong. Do I need to do something to the permissions of this 'App User' to make this work?
-
As these things usually go, I got this working by fiddling with the permissions a few minutes after posting this. However, now it seems to stick at 0% upload before finally failing, even though all the HTTP requests being made have a 200 code. I don't actually see the file being uploaded in a request though.
-
,
You'll probably have better luck getting this answered on the Box Developer Forum. It's mostly end users and admins on this forum.
Best of luck,
Bob
サインインしてコメントを残してください。
コメント
2件のコメント