> ## Documentation Index
> Fetch the complete documentation index at: https://docs.blinkops.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List All Teams

Get a list of all teams.

**Note:** For regular users, this will return open teams only. To get all the teams `manage_system` permission is required.

<Note>
  External Documentation

  To learn more, visit the [Mattermost documentation](https://developers.mattermost.com/api-documentation/#/operations/GetAllTeams).
</Note>

## Parameters

<div className="integrations-table">
  | Parameter                  | Description                                                                                                             |
  | -------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
  | Exclude Policy Constrained | Select to exclude teams that are part of a data retention policy. Requires the `sysconsole_read_compliance` permission. |
  | Page                       | The page number to retrieve, starting at `0`.                                                                           |
  | Per Page                   | The maximum number of items to retrieve per page.                                                                       |
  | Return All Pages           | Automatically fetch all resources, page by page.                                                                        |
</div>

## Example Output

```json theme={"dark"}
{
	"teams": [
		{
			"id": "string",
			"create_at": 0,
			"update_at": 0,
			"delete_at": 0,
			"display_name": "string",
			"name": "string",
			"description": "string",
			"email": "string",
			"type": "string",
			"company_name": "string",
			"allowed_domains": "string",
			"invite_id": "string",
			"allow_open_invite": true,
			"scheme_id": "string",
			"group_constrained": true,
			"policy_id": "string",
			"cloud_limits_archived": true
		}
	],
	"total_count": 0
}
```

## Workflow Library Example

[List All Teams with Mattermost and Send Results Via Email](https://library.blinkops.com/workflows/list-all-teams-with-mattermost-and-send-results-via-email)

<div className="iframe-wrapper">
  <div className="iframe-media">
    <img src="https://mintcdn.com/blinkops-2/ojHYuDeYX5FWuN8a/img/Icons/play-box.svg?fit=max&auto=format&n=ojHYuDeYX5FWuN8a&q=85&s=b8af968e71438a9499c3223c9bd29fb2" alt="Workflow Library" width="16" height="16" data-path="img/Icons/play-box.svg" />

    Preview this Workflow on desktop
  </div>

  <iframe className="iframe" src="https://library.blinkops.com/workflows/list-all-teams-with-mattermost-and-send-results-via-email/canvas" />
</div>
