Skip to main content
Question

Reauthorizing app doesn't fix enterprise configuration

  • May 22, 2025
  • 3 replies
  • 24 views

Forum|alt.badge.img

I've downloaded the Json Config file and tried to use the client ID and secret to authorize the app instead of the developer token. The line that I'm getting the error is 

BoxDeveloperEditionAPIConnection client = BoxDeveloperEditionAPIConnection.getAppUserConnection("FakeUserID",boxConfig, accessTokenCache);

and the error that I'm getting is {"error":"invalid_request","error_description":"Cannot obtain token based on the enterprise configuration for your app"}. 

The program reads the config file correctly, but I can't get past the invalid request error. 
 

3 replies

Forum|alt.badge.img

to use User Access Tokens you will need to enable "Generate User Access Tokens" in your app config on https://cloud.app.box.com/developers/console/

 

BOX_dfjk9tj7oj7qsyo10883naypvziy72mc.png


Forum|alt.badge.img

Those are already enabled. Not sure what else it could be.


Forum|alt.badge.img

Please open a support case at a support.box.com so we can further assist! Ensure you provide: 

 

  • Client ID (aka API key) of the application producing the error
  • Full body response of the error 
  • Date/time/timezone you receive the error