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

# Create Environment

> Creates a user environment (e.g

Creates a user environment (e.g. Staging) in a Google Tag Manager container for previewing and publishing versions outside Live.

| | |
| - | - |
| **App** | Google Tag Manager |
| **Operation ID** | `gtm_create_environment` |
| **Type** | Action |
| **Connection** | `gtm` (required) |
| **Credits per run** | 1 |
| **Agent / MCP tool** | Yes |
| **Requires approval** | Yes (write operation) |

## Inputs

| Field | Type | Required | Default | Description |
| - | - | - | - | - |
| `account` | DynamicAccount | Yes | - | Select the Google Tag Manager account. |
| `container` | DynamicAccount | Yes | - | Select the container to create the environment in. |
| `name` | string | Yes | - | Name for the new environment, e.g. Staging. |
| `description` | string | No | - | Optional description of the environment. |
| `url` | string | No | - | Default preview page URL for the environment. |
| `enable_debug` | boolean | No | - | Whether debug mode is enabled by default for the environment. |

## Output

**Type**: `Dict`

Returns the created environment as provided by the Tag Manager API, including its environmentId and authorizationCode.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.