Hello everyone, kind people. Please help me figure out how to manage users in Grafana Cloud via the API. Everywhere I’ve read at least some documentation says that in order to manage users, you need to log in via user:pass, but we have SSO enabled and login only through it. Since users are currently managed via grafana cloud, I created Access Policies and added a token with the set: cloud-admin role.
When I try to make requests through curl using this token, I can output information about the organization using this query.
curl -H “Authorization: Bearer glc_ey****” "https://grafana.com/api/orgs /{org_name}"if I’m trying to withdraw users via endpoint "https://grafana.com/api/users ", I get the error
{
“code”: “Forbidden”,
“message”: “You do not have permission to perform the requested action.”,
“requestId”: “606bb46b-1e9d-441f-aba6-43cda0549779”
}
But i can use this query /api/orgs/{org_name}/members, and /api/users/{user_id or name}, but when i use -X DELETE with needed user, i get the error like upper.
Please help me figure out what I’m doing wrong, and is it even possible now to delete a user from grafana cloud via the api?
Grafana instance version: “12.0.0-86517”