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

# Adicionar/atualizar variáveis

> Altera as chaves enviadas e mantém as demais.

```bash cURL theme={null}
curl -X POST 'https://api.sondercloud.app/v1/apps/{id}/envs' \
  -H 'Authorization: Bearer seu_token' \
  -H 'Content-Type: application/json' \
  --data '{"envs":{"NODE_ENV":"production","API_KEY":"seu-segredo"}}'
```

```json Success theme={null}
{
  "success": true,
  "response": {
    "NODE_ENV": "production",
    "API_KEY": "seu-segredo"
  },
  "message": "Environment variables saved. Restart the app to apply changes."
}
```

> [!NOTE]
>
> `PATCH` faz a mesma mesclagem. Reinicie a aplicação para aplicar as alterações. Não é possível alterar variáveis durante um `BUILDING`.


## API Specification

The full API specification for this endpoint is available in the [documentation index](https://docs.sondercloud.app/llms.txt).


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