Menu
Documentation
Grafana Cloud
Developer resources
API reference
Grafana HTTP API reference
Team Sync HTTP API
Grafana Cloud
Team Sync API
Team Sync is only available in Grafana Enterprise. Read more about Grafana Enterprise.
If you are running Grafana Enterprise, for some endpoints you’ll need to have specific permissions. Refer to Role-based access control permissions for more information.
Get External Groups
GET /api/teams/:teamId/groups
Required permissions
See note in the introduction for an explanation.
Action | Scope |
---|---|
teams.permissions:read | teams:* |
Example Request:
http
GET /api/teams/1/groups HTTP/1.1
Accept: application/json
Content-Type: application/json
Authorization: Basic YWRtaW46YWRtaW4=
Example Response:
http
HTTP/1.1 200
Content-Type: application/json
[
{
"orgId": 1,
"teamId": 1,
"groupId": "cn=editors,ou=groups,dc=grafana,dc=org"
}
]
Status Codes:
- 200 - Ok
- 401 - Unauthorized
- 403 - Permission denied
Add External Group
POST /api/teams/:teamId/groups
Required permissions
See note in the introduction for an explanation.
Action | Scope |
---|---|
teams.permissions:write | teams:* |
Example Request:
http
POST /api/teams/1/groups HTTP/1.1
Accept: application/json
Content-Type: application/json
Authorization: Basic YWRtaW46YWRtaW4=
{
"groupId": "cn=editors,ou=groups,dc=grafana,dc=org"
}
Example Response:
http
HTTP/1.1 200
Content-Type: application/json
{"message":"Group added to Team"}
Status Codes:
- 200 - Ok
- 400 - Group is already added to this team
- 401 - Unauthorized
- 403 - Permission denied
- 404 - Team not found
Remove External Group
DELETE /api/teams/:teamId/groups?groupId=external-group-id
Required permissions
See note in the introduction for an explanation.
Action | Scope |
---|---|
teams.permissions:write | teams:* |
Example Request:
http
DELETE /api/teams/1/groups?groupId=cn%3Deditors%2Cou%3Dgroups%2Cdc%3Dgrafana%2Cdc%3Dorg HTTP/1.1
Accept: application/json
Content-Type: application/json
Authorization: Basic YWRtaW46YWRtaW4=
Example Response:
http
HTTP/1.1 200
Content-Type: application/json
{"message":"Team Group removed"}
Status Codes:
- 200 - Ok
- 401 - Unauthorized
- 403 - Permission denied
- 404 - Team not found/Group not found
Was this page helpful?
Related resources from Grafana Labs
Additional helpful documentation, links, and articles:
![Getting started with the Grafana LGTM Stack](/static/assets/featured/getting-started-with-grafana-lgtm-stack-amer_featured.png?w=200 200w, /static/assets/featured/getting-started-with-grafana-lgtm-stack-amer_featured.png?w=400 400w)
Getting started with the Grafana LGTM Stack
In this webinar, we’ll demo how to get started using the LGTM Stack: Loki for logs, Grafana for visualization, Tempo for traces, and Mimir for metrics.
![Intro to Kubernetes monitoring in Grafana Cloud](/media/webinar/Screenshot-2024-02-12-at-4.09.30-PM.png?w=200 200w, /media/webinar/Screenshot-2024-02-12-at-4.09.30-PM.png?w=400 400w)
Intro to Kubernetes monitoring in Grafana Cloud
In this webinar you’ll learn how Grafana offers developers and SREs a simple and quick-to-value solution for monitoring their Kubernetes infrastructure.
![Building advanced Grafana dashboards](/media/webinar/AMER_buildadv_notxt.png?w=200 200w, /media/webinar/AMER_buildadv_notxt.png?w=400 400w)
Building advanced Grafana dashboards
In this webinar, we’ll demo how to build and format Grafana dashboards.