You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looking the documentation on pan.dev, I notice there is no endpoint to get precises permissions of the current user (using the API).
However the openapi file available in the web interface contains a lot of endpoint.
But as described in pan.dev cwpp documentation about endpoints: « In the OpenAPI spec, supported endpoints are tagged as supported ».
I notice /current/role is not tag as it, but only with :
tags:
-Current
Describe the solution you'd like
I like to be sure this endpoint is marked as supported, since the functionality is really useful and pretty straight forward.
Describe alternatives you've considered
Currently I'm requesting directly endpoints (/hosts, /images, whatever), and handle HTTP error and/or JSON error message.
Additional context
Using the API, i'm trying to check if the current permissions are enough to perform future operations. Currently i'm trying to access directory the required endpoint, if the current profile doesn't have the right to do so, i handle using the HTTP error and/or json error message.
However using the alternative, to generate a nice message with explains what specific permission is missing is like playing try & error. We need to try all endpoints in order to check actual permissions...
However using one request (targeting /current/role), we can check the required permissions and avoid useless requests. Moreover we can nicely return what permissions is missing..
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem?
Looking the documentation on pan.dev, I notice there is no endpoint to get precises permissions of the current user (using the API).
However the openapi file available in the web interface contains a lot of endpoint.
But as described in pan.dev cwpp documentation about endpoints: « In the OpenAPI spec, supported endpoints are tagged as supported ».
I notice
/current/role
is not tag as it, but only with :Describe the solution you'd like
I like to be sure this endpoint is marked as supported, since the functionality is really useful and pretty straight forward.
Describe alternatives you've considered
Currently I'm requesting directly endpoints (/hosts, /images, whatever), and handle HTTP error and/or JSON error message.
Additional context
Using the API, i'm trying to check if the current permissions are enough to perform future operations. Currently i'm trying to access directory the required endpoint, if the current profile doesn't have the right to do so, i handle using the HTTP error and/or json error message.
However using the alternative, to generate a nice message with explains what specific permission is missing is like playing try & error. We need to try all endpoints in order to check actual permissions...
However using one request (targeting
/current/role
), we can check the required permissions and avoid useless requests. Moreover we can nicely return what permissions is missing..The text was updated successfully, but these errors were encountered: