GrafanaJsonDatasource icon indicating copy to clipboard operation
GrafanaJsonDatasource copied to clipboard

get userinfo from `/query`

Open cybercall opened this issue 1 year ago • 4 comments

Can I get the user's login name from the /query request? Its value is the built-in Grafana variable ${__user.login}. I need this information to perform some permission control, which will determine the results returned.

cybercall avatar Sep 26 '24 09:09 cybercall

Grafana does not include it in the query. You can definitely send the variable's value within payload.

simPod avatar Sep 26 '24 10:09 simPod

Grafana does not include it in the query. You can definitely send the variable's value within payload.

sure, I can do it like that, but I would need to modify each panel, which is quite troublesome.

cybercall avatar Sep 26 '24 10:09 cybercall

What do you propose then

On Thu, Sep 26, 2024, 12:24 cybercall @.***> wrote:

Grafana does not include it in the query. You can definitely send the variable's value within payload.

sure, I can do it like that, but I would need to modify each panel, which is quite troublesome.

— Reply to this email directly, view it on GitHub https://github.com/simPod/GrafanaJsonDatasource/issues/637#issuecomment-2376551820, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACQAJPCJJXFV6MMDOS6SCLZYPOGFAVCNFSM6AAAAABO4TM5OSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNZWGU2TCOBSGA . You are receiving this because you commented.Message ID: @.***>

simPod avatar Sep 26 '24 10:09 simPod

I'm not sure how to achieve this with Grafana plugins, I just hope to be able to get the user info in the HTTP request ~~

cybercall avatar Oct 09 '24 08:10 cybercall

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

github-actions[bot] avatar Nov 09 '24 02:11 github-actions[bot]

This issue has not seen any activity since it was marked stale. Closing.

github-actions[bot] avatar Nov 16 '24 02:11 github-actions[bot]

https://github.com/simPod/GrafanaJsonDatasource/issues/660

simPod avatar Dec 18 '24 11:12 simPod