# List teams

From **GitHub v3 REST API**.

`GET /orgs/{org}/teams`

Lists all teams in an organization that are visible to the authenticated user.

## Parameters

### `org`

- Location: path
- Required: true
- Type: `string`

### `per_page`

- Location: query
- Required: false
- Type: `integer`
- Default: `30`

Results per page (max 100)

### `page`

- Location: query
- Required: false
- Type: `integer`
- Default: `1`

Page number of the results to fetch.

## Responses

### `200`

Response

#### Headers

##### `Link`

- Type: `string`

- Example: `<https://api.github.com/resource?page=2>; rel="next", <https://api.github.com/resource?page=5>; rel="last"`

### `application/json`

- Type: `array`

```json
[
  {
    "description": "A great team.",
    "html_url": "https://github.com/orgs/github/teams/justice-league",
    "id": 1,
    "members_url": "https://api.github.com/teams/1/members{/member}",
    "name": "Justice League",
    "node_id": "MDQ6VGVhbTE=",
    "parent": null,
    "permission": "admin",
    "privacy": "closed",
    "repositories_url": "https://api.github.com/teams/1/repos",
    "slug": "justice-league",
    "url": "https://api.github.com/teams/1"
  }
]
```

```json
{"items":{"$ref":"#/components/schemas/team"},"type":"array"}
```

### `403`

Forbidden

### `application/json`

- Type: `object`

Basic Error

```json
{"description":"Basic Error","properties":{"documentation_url":{"type":"string"},"message":{"type":"string"},"status":{"type":"string"},"url":{"type":"string"}},"title":"Basic Error","type":"object"}
```

## Request examples

### cURL

```shell
curl --request GET \
  --url {protocol}://{hostname}/api/v3/orgs/{org}/teams
```
