List teams
A workspace's teams that you can see, yours first, then by name.
/workspaces/{workspace}/teamsA team is a group of the workspace’s members, given roles on repositories together, mentioned as @workspace/team and asked to review together. A secret team is seen only by its own people and the workspace’s owners. Each team has its slug, name, description, visibility (visible or secret), parent, whether its people are notified when it is mentioned (notify), its review_assignment, how many people, repositories and child teams it has (members_count, repos_count, child_teams_count), your own viewer_role in it, and whether you may change it (can_manage). query narrows them by name or slug. Members of the workspace only.
Teams you are in come first, then the rest by name. A secret team is listed only for its own people and the workspace’s owners. review_assignment is what happens when the team is asked to review: see set_team_review_assignment. 403 for anyone who is not a member of the workspace. See Teams.
- Authentication: Required. Send an access token as
Authorization: Bearer. - MCP tool:
teamwithactionlist, and the same inputs - Scope: An access token needs
workspace:read.
Path parameters
Section titled “Path parameters”| Name | Type | Required | Description |
|---|---|---|---|
workspace |
string | Yes | The workspace’s slug, e.g. “flagon-io”. |
Query parameters
Section titled “Query parameters”| Name | Type | Required | Description |
|---|---|---|---|
q |
string | No | Only teams whose name or slug has these letters. |
Example request
Section titled “Example request”curl "https://api.g1t.sh/workspaces/flagon-io/teams?q=back" \ -H "Authorization: Bearer $G1T_TOKEN"Example response
Section titled “Example response”A successful request answers 200 with:
[ { "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", "workspace": "flagon-io", "slug": "backend", "name": "Backend", "description": "The API and the services behind it.", "visibility": "visible", "parent": { "slug": "engineering", "name": "Engineering" }, "notify": true, "review_assignment": { "enabled": false, "algorithm": "round_robin", "count": 1, "skip_busy": false, "busy_at": 5, "include_child_teams": false, "excluded": [], "notify_team": false }, "members_count": 4, "repos_count": 2, "child_teams_count": 1, "viewer_role": "maintainer", "can_manage": true, "created_at": "2026-10-06T15:02:11.480Z", "updated_at": "2026-10-06T15:02:11.480Z" }]Errors
Section titled “Errors”A failed request answers with one of these statuses and a body like {"error": {"code": "not_found", "message": "Repository not found."}}. See errors.
| Status | Code | When |
|---|---|---|
| 401 | unauthenticated |
A token is required, or the one sent is not valid. |
| 403 | forbidden |
The token is valid but not allowed to do this, such as a member-only change or an agent token outside its repository. |
| 404 | not_found |
It does not exist, or you cannot see it. |
| 422 | invalid |
The input is not valid. message says which field and why. |