---
title: "POST /team/environments"
method: POST
path: "/team/environments"
tags: ["team"]
---

# POST /team/environments

`POST /team/environments`

## Request

- Base URL: `https://api.scalar.com/core`
- URL: `https://api.scalar.com/core/team/environments`
- Auth: HTTP bearer

Add an environment to the team

## Request body

- object
  - `slug` string, required
  - `name` string

## Response `200`

Default Response

- TeamEnvironment[]
  - `slug` string, required
  - `name` string, required
  - `branches` string[], required

## Other responses

- `400`: Bad request
- `401`: No auth
- `403`: Forbidden
- `404`: Not found
- `422`: Invalid payload
- `500`: Uncaught error

## Changes

- **2026-10-13** `31d9832a717b`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/scalar/apis/core/changes/team/environments/post.md)

---

[API](https://skmtc.dev/scalar/apis/core.md) - [All operations](https://skmtc.dev/scalar/apis/core/llms.txt) - [OpenAPI document](https://skmtc.dev/scalar/apis/core/revisions/b3aa8493faa8?raw)
