Admin no access to API Docs

Hi,

I’m running on Dreamfactory 1.6.10, when I access to Api Doc section with a admin user and I try out any resource I get this error message:
“Access to application ‘admin’ is not provisioned for this user’s role.”

It’s like admin user belongs to a role that can’t get access to dreamfactory resources.

Have a look:

You’ll need to check the box within the config page giving this user access to that application. Also, make sure CORS is enabled within your config.

I like to run the DSP with a debugger so that if I do have an issue it pops up right there on the browser. The benefit of it is that you can simply take the error code (in this case 403) that it displays, perform a quick search on this forum or even google with some keywords (403 access forbidden dreamfactory), and the majority of the time it leads you right to the solution.

If you come across any other issues, let us know!

Thanks,

  • Mark

Thank you for you help but,

I’m trying to find out why a System Admin user can not get access to any Api Doc resource. There is no ‘admin’ application, I just try to access to database resource from Api Doc and i get “Access to application ‘admin’ is not provisioned for this user’s role.” message.
CORS is enabled and the User Config Says “System Administrators have access to all services and applications and cannot be assigned a role.”

I created another Sys admin user but I get the same result.

Few days ago I can request from Api Docs as an admin user without problems but not now.

Please recreate your DSP.

I just tested and works okay - if re-creating doesn’t work, then go ahead and perform a /web/logout after upgrading in the config tab.

Thanks,
Mark

Your session timed out and you have guest users enabled most likely. So the request to API docs is using a guest role.

1 Like

Hi, sorry for not update the situation before,

I hate say this but now is working ok again and I don’t know why. I couldn’t reproduce this issue these last days. My dreamfactory is still on 1.6.10. I hope upgrade it soon to 1.7.6.

Thank you!

Its definitely a session related issue. The calls in the API docs use a different XHR object, therefore they do not follow the session and error handling of the admin application itself. When your admin session timed out, it put you back as guest and tried making requests on its own with the guest account.

1 Like

I’ve been thinking about it and I restarted the Virtual Machine where was my Dreamfactory server before the Api Docs started to work right again.

Jason is right.

Thanks folks!