*Cloud*

# The environment object

An environment is one copy of a project's services, variables and volumes: production (made with the project, never deleted), staging or any other name.

## Attributes

- `env` (string): The environment's id.
- `name` (string): Its name, unique in the project.
- `is_production` (boolean): True for the production environment.
- `service_count` (number): Services in it.
- `status` (string): ok, needs_attention, deploying, stopped or empty.
- `created_at` (timestamp): When it was created, Unix seconds.

## Example

```json
{
  "data": {
    "env": "env_01jdk3m9x5h2p8r4t6y1u3i0oa",
    "name": "production",
    "is_production": true,
    "service_count": 3,
    "status": "ok",
    "created_at": 1764324999
  }
}
```

## Endpoints

- `POST` [Apply a config file](https://docs.dispralabs.com/api/apply-a-config-file.md)
- `POST` [Change variables in bulk](https://docs.dispralabs.com/api/change-variables-in-bulk.md)
- `POST` [Create a service](https://docs.dispralabs.com/api/create-a-service.md)
- `POST` [Create a service group](https://docs.dispralabs.com/api/create-a-service-group.md)
- `POST` [Create a volume](https://docs.dispralabs.com/api/create-a-volume.md)
- `POST` [Create an environment](https://docs.dispralabs.com/api/create-an-environment.md)
- `DELETE` [Delete a project variable](https://docs.dispralabs.com/api/delete-a-project-variable.md)
- `DELETE` [Delete a service group](https://docs.dispralabs.com/api/delete-a-service-group.md)
- `DELETE` [Delete an environment](https://docs.dispralabs.com/api/delete-an-environment.md)
- `GET` [Export the environment](https://docs.dispralabs.com/api/export-the-environment.md)
- `GET` [Get the variables graph](https://docs.dispralabs.com/api/get-the-variables-graph.md)
- `GET` [List environments](https://docs.dispralabs.com/api/list-environments.md)
- `GET` [List project activity](https://docs.dispralabs.com/api/list-project-activity.md)
- `GET` [List project variables](https://docs.dispralabs.com/api/list-project-variables.md)
- `GET` [List service groups](https://docs.dispralabs.com/api/list-service-groups.md)
- `GET` [List services](https://docs.dispralabs.com/api/list-services.md)
- `GET` [List volumes](https://docs.dispralabs.com/api/list-volumes.md)
- `POST` [Plan a config file](https://docs.dispralabs.com/api/plan-a-config-file.md)
- `POST` [Reveal a project variable](https://docs.dispralabs.com/api/reveal-a-project-variable.md)
- `POST` [Reveal all project variables](https://docs.dispralabs.com/api/reveal-all-project-variables.md)
- `PUT` [Set a project variable](https://docs.dispralabs.com/api/set-a-project-variable.md)
- `PATCH` [Update a service group](https://docs.dispralabs.com/api/update-a-service-group.md)
- `POST` [Validate variables text](https://docs.dispralabs.com/api/validate-variables-text.md)
