Environments
Set up
Section titled “Set up”npm install @reminix/sdkimport { createClient } from "@reminix/sdk";
const reminix = createClient(); // reads REMINIX_API_KEYpip install reminixfrom reminix import Reminix
reminix = Reminix() # reads REMINIX_API_KEYnpm install -g @reminix/clireminix loginexport REMINIX_API_KEY="<your API key>"List environments
Section titled “List environments”GET /v1/environments
The workspace’s environments, oldest first, with which is the default.
await reminix.environments.list();reminix.environments.list()reminix environments listcurl -X GET "https://api.reminix.com/v1/environments" \ -H "Authorization: Bearer $REMINIX_API_KEY"More about this endpoint
Name one with the X-Environment header to act in it.
Add an environment
Section titled “Add an environment”POST /v1/environments
Adds an environment with no secret values yet — save them with X-Environment set to it.
await reminix.environments.create({ name: "staging",});reminix.environments.create(name="staging")reminix environments create --name stagingcurl -X POST "https://api.reminix.com/v1/environments" \ -H "Authorization: Bearer $REMINIX_API_KEY" \ -H "Content-Type: application/json" \ -d '{"name":"staging"}'| Field | Description |
|---|---|
name | Its name, unique in the workspace. |
approvalPolicy | Which runs here wait for a person's approval: none, agents (runs an agent starts) or always. A run uses the stricter of this and its script's policy. Default: none. |
agentsAllowed | Whether agents (MCP) may run scripts here, or schedule them to. Default: true. |
More about this endpoint
Lowercase letters, digits and dashes. Owners and admins, or a workspace API key.
Get an environment
Section titled “Get an environment”GET /v1/environments/{environment}
One environment, with what uses it: the secret values deleting it would delete, and the schedules and triggers that keep it from being deleted.
await reminix.environments.get("staging");reminix.environments.get("staging")reminix environments get stagingcurl -X GET "https://api.reminix.com/v1/environments/staging" \ -H "Authorization: Bearer $REMINIX_API_KEY"| Field | Description |
|---|---|
environment |
Change an environment
Section titled “Change an environment”PATCH /v1/environments/{environment}
Renames it, changes its rules, or makes it the workspace’s default (isDefault: true).
await reminix.environments.update("staging");reminix.environments.update("staging")reminix environments update stagingcurl -X PATCH "https://api.reminix.com/v1/environments/staging" \ -H "Authorization: Bearer $REMINIX_API_KEY" \ -H "Content-Type: application/json" \ -d '{}'| Field | Description |
|---|---|
environment | |
name | Its name, unique in the workspace. |
approvalPolicy | Which runs here wait for a person's approval: none, agents (runs an agent starts) or always. A run uses the stricter of this and its script's policy. |
agentsAllowed | Whether agents (MCP) may run scripts here, or schedule them to. |
isDefault | Make it the default. To change the default, make another one the default. |
More about this endpoint
Runs keep the name they ran under. Owners and admins, or a workspace API key.
Delete an environment
Section titled “Delete an environment”DELETE /v1/environments/{environment}
Deletes it and every secret value it holds (GET it first to see how many).
await reminix.environments.delete("staging");reminix.environments.delete("staging")reminix environments delete staging --yescurl -X DELETE "https://api.reminix.com/v1/environments/staging" \ -H "Authorization: Bearer $REMINIX_API_KEY"| Field | Description |
|---|---|
environment |
More about this endpoint
Refused for the only environment, the default, and one a schedule or trigger runs in. Owners and admins, or a workspace API key.