# Create a team

URL: https://heaven.dev/docs/reference/teams/create
Updated: 2026-11-21

Create a team in an organization. Initial members must already belong to the organization. By default, team members have SSH and website access to Computers the team owns.

`POST /v1/organization/team/create`

## Parameters

- `name` (string, required): Team name, 1 to 100 bytes on one line without `@`. It must be unique within the organization regardless of case.
- `users` (string[]): An organization member to add to the team, by email address or user ID.
- `organization` (string): Organization name or ID. A credential, named resource or sole membership can select the organization for you.

## Returns

- `data` (object, always present): An organization team, its members, owned Computers and shared access.
  - `computers` (string[] | null, always present): Computers owned by the team.
  - `full_name` (string, always present): Team name qualified by its organization.
  - `id` (string, always present): Team ID.
  - `member_access` (string, always present): Access team members receive to Computers the team owns.
  - `members` (object[] | null, always present): Team's members and their team roles.
    - `items` (object): A person's membership in an organization team.
      - `email` (string | null, always present): Their email address, or null without one.
      - `name` (string): Their display name, when set. May be omitted.
      - `picture` (string): Their profile picture URL. May be omitted.
      - `role` (string, always present): Their role within this team.
      - `user_id` (string, always present): Person's user ID.
  - `name` (string, always present): Team's name within its organization.
  - `pools` (object[] | null, always present): Pools shared with the team by other accounts.
    - `items` (object): A pool another account shares with the team.
      - `account` (string, always present): Account providing the pool.
      - `commands` (string[]): Additional commands the share grants. May be omitted.
      - `pool` (string, always present): Shared pool's name.
      - `pool_id` (string, always present): Shared pool's ID.
      - `role` (string, always present): Pool share's role.
  - `shares` (object[] | null, always present): Computer access granted to the team.
    - `items` (object): Access to a Computer shared with a team.
      - `commands` (string[]): Additional commands granted to the team. May be omitted.
      - `computer` (string, always present): Shared Computer's name.
      - `role` (string, always present): Share's access role.

## Errors

Each code is explained in full at https://heaven.dev/docs/reference/errors.

| Code | Status | What happened |
|---|---:|---|
| `invalid` | 400 | An input is missing or invalid. |
| `unauthenticated` | 401 | The credential is missing, invalid, expired or revoked. |
| `denied` | 403 | The caller lacks permission for this action. |
| `not_found` | 404 | The resource is absent or inaccessible to this caller. |
| `conflict` | 409 | The request conflicts with the current resource state or an earlier request. |
| `over_capacity` | 409 | The request exceeds a resource or credential allowance. |
| `access_list_full` | 409 | The change would exceed the access-list allowance. |
| `payment_required` | 402 | Payment or credit is required. |
| `rate_limited` | 429 | The caller's request rate exceeds its limit. |
| `busy` | 429 | Too much work is in progress to accept this request. |
| `unknown` | 503 | The outcome is unconfirmed; a change may have happened. |
| `unavailable` | 503 | The service or requested feature is unavailable. |

## Notes

- CLI: `heaven login` with `HEAVEN_API_KEY` unset. MCP: Heaven sign-in. cURL: `HEAVEN_SIGN_IN_KEY` from approved device sign-in (`POST /v1/auth/create`).
- A key limited to a command list cannot run this command.

## Examples

```sh tab="heaven CLI"
heaven organization team create NAME
  [--user USER ...]
  [--organization ORGANIZATION]
```

```sh tab="SSH"
ssh cli@heaven.dev organization team create NAME
  [--user USER ...]
  [--organization ORGANIZATION]
```

```sh tab="cURL"
curl https://heaven.dev/v1/organization/team/create \
  -H "Authorization: Bearer $HEAVEN_SIGN_IN_KEY" \
  --json '{"name": "web", "organization": "acme"}'
```

```json tab="MCP"
{ "tool": "organization_team_create",
  "arguments": { "name": "web", "organization": "acme" } }
```

Response:

```json title="Response excerpt"
{
  "version": 1,
  "data": {
    "computers": [],
    "full_name": "acme@web",
    "id": "c3fbb51a-4eda-4ba4-ac73-21972e1c8489",
    "member_access": "root",
    "members": [],
    "name": "web",
    "pools": [],
    "shares": []
  }
}
```
