Skip to main content
New Participant
Dec 27, 2023 6:51 AM UTC

JWT token not generated

Hi Team,

We are constantly getting below error when our automated jenkins jobs trying to upload files on box folder:
access_token = response.json()[‘access_token’]
KeyError: ‘access_token’

The same jobs are working fine on staging server with same configurations means files are being uploaded to box folders using the same app config on our staging server.

The issue we are facing is in production jenkins jobs, it was working fine till 24th dec but now continue to fails generating access token.

We are currently using JWT without SDK approach.

Looking forward for some help.

Thanks,
Shailendra J

3 replies

rbarbosa Box
Developer Advocate
Dec 27, 2023 12:47 PM UTC

Hi @shailendraj

Assuming you’re making a request to get an access token, and using the JWT in the authorization header, it seems you’re getting back an error.

What error is it? What message is coming back from the API?

Let us know.

Cheers

Translate
New Participant
Dec 27, 2023 12:54 PM UTC

Hi @rbarbosa

We are getting below error:

access_token = response.json()[‘access_token’]
KeyError: ‘access_token’

Translate
rbarbosa Box
Developer Advocate
Dec 27, 2023 12:58 PM UTC

🙂

Please send the actual response.json() content

The error you’re gettin is because ‘access_token’ is not present on the response. but what is the actual response?

Translate