Admin API - Global Users POST /api/admin/users ignores OrgId if supplied

Hi all,

I am trying to use the admin API to create a new user using POST /api/admin/users. The documentation here ( ) says " Note that OrgId is an optional parameter that can be used to assign a new user to a different organization when auto_assign_org is set to true ."

I have auto_assign_org set to true, but whenever I specify an OrgId in a post request Grafana ignores it and the new user is added to Main Org (Id = 1).

Any idea what I could be doing wrong?

Hi, and welcome to the Grafana forums!

This sounds like a potential bug. I’d suggest that you create an issue on GitHub for this.