Projects & Environments — MCP Tools
Projects and their environments. This page documents the Projects & Environments group of the Routebase MCP server, with the scope and the parameters of each tool.
The group is part of the core set, so every session advertises it from the start.
create_environment
Create a new environment in a project. Type must be one of: development, test, staging, production, custom. Requires organization context (call set_context first).
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
name |
string | Yes | Display name for the environment |
type |
string | Yes | Environment type: development, test, staging, production, or custom |
baseUrl |
string | No | Optional base URL for the environment |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
create_project
Create a new project in the active organization. Without environmentsJson the backend creates its standard set of environments. Requires organization context (call set_context first). The new project does NOT become the active context — call set_context with the returned id.
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
name |
string | Yes | Display name for the project |
description |
string | No | Optional project description |
environmentsJson |
string | No | Optional JSON array of environments to create instead of the defaults. Each item: { "type": "development"|"test"|"staging"|"production"|"custom", "name"?: string, "baseUrl"?: string }. Name is required for type 'custom'. |
includeMockServer |
boolean | No (default false) |
Create a mock server for the project right away. Default false. |
sampleDataSet |
string | No (default "none") |
Sample test data to seed: 'none' (default), 'hello_world' (3 fixtures + a /health seed) or 'pet_store' (5 fixtures + 2 seeds, the full demo). |
delete_environment
Delete an environment and ALL of its variables. This is destructive and cannot be undone. Requires organization context (call set_context first).
Required scope: projects:delete
| Parameter | Type | Required | Description |
|---|---|---|---|
environmentId |
string | Yes | Public ID (GUID) of the environment to delete |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
delete_project
Delete a project with everything in it — specs, tests, mocks, documentation and environments. This is destructive and cannot be undone. Use this to remove the whole project; for a single environment use delete_environment. Requires organization context.
Required scope: projects:delete
| Parameter | Type | Required | Description |
|---|---|---|---|
projectId |
string | No | Public ID (GUID) of the project to delete. If omitted, uses the active project context. |
get_environment_variables
Get resolved variables for a specific environment. Secret values are always masked for security. Use this to read resolved values; to change them use set_environment_variables. Requires organization context.
Required scope: projects:read
| Parameter | Type | Required | Description |
|---|---|---|---|
environmentId |
string | Yes | Public ID (GUID) of the environment |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
get_project
Get detailed information about a project, including its environments. Use this when you already have the project id; to browse the organization's projects use list_projects. Requires organization context (call set_context first). If no projectId is given, uses the active project context.
Required scope: projects:read
| Parameter | Type | Required | Description |
|---|---|---|---|
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
get_project_settings
Get a project's settings: default environment, which modules are enabled, default response format and request timeout. Use this to read the settings; to change them use update_project_settings. Requires organization context.
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
list_environments
List all environments of a project with variable counts. Use this to browse a project's environments; for the variables of one use get_environment_variables. Requires organization context. If no projectId is given, uses the active project context.
Required scope: projects:read
| Parameter | Type | Required | Description |
|---|---|---|---|
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
set_environment_readonly
Protect an environment against writes, or lift that protection. While read-only, only GET/HEAD/OPTIONS requests reach the environment — used to keep production safe from test runs. Requires the org:manage-governance permission and organization context. Use this to protect or unprotect an environment; to change its name or URL use update_environment.
Required scope: org:manage-governance
| Parameter | Type | Required | Description |
|---|---|---|---|
environmentId |
string | Yes | Public ID (GUID) of the environment |
isReadOnly |
boolean | Yes | true to protect the environment, false to lift the protection |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
set_environment_variables
Set/update environment variables in batch. WARNING — FULL REPLACE: this replaces the ENTIRE variable set of the environment. Any variable whose key is NOT in the provided array will be DELETED. To add or change a single variable without losing the others, first call 'get_environment_variables', then send back the complete desired list. Secret values are encrypted server-side; secret values in the response are masked. Requires organization context (call set_context first).
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
environmentId |
string | Yes | Public ID (GUID) of the environment |
variablesJson |
string | Yes | JSON array of variables to set. Each item: { "key": string, "value": string, "isSecret"?: bool, "description"?: string }. This is the COMPLETE desired set — omitted keys are deleted. |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
update_environment
Update an environment's name, type, and base URL. Type (if provided) must be one of: development, test, staging, production, custom. Requires organization context (call set_context first).
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
environmentId |
string | Yes | Public ID (GUID) of the environment to update |
name |
string | Yes | New display name for the environment |
type |
string | No | New environment type: development, test, staging, production, or custom. If omitted, the type is unchanged. |
baseUrl |
string | No | New base URL for the environment |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
update_project
Rename a project and/or change its description. Omit a field to keep its current value; pass an empty string for description to clear it. Use this for name and description; for modules and defaults use update_project_settings. Requires organization context.
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
name |
string | No | New display name. If omitted, the current name is kept. |
description |
string | No | New description. Pass an empty string to clear it. If omitted, the current description is kept. |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |
update_project_settings
Update a project's settings. Omit a field to keep its current value — the tool reads the current settings first. Pass clearDefaultEnvironment to unset the default environment. Use this for the settings; to rename the project use update_project. Requires organization context.
Required scope: projects:write
| Parameter | Type | Required | Description |
|---|---|---|---|
defaultEnvironmentId |
string | No | Public ID (GUID) of the environment to use as default. Get it from list_environments. |
clearDefaultEnvironment |
boolean | No (default false) |
Set to true to remove the default environment. Ignored when defaultEnvironmentId is given. |
enableMockServer |
boolean | No | Enable or disable the mock server module for this project |
enableApiTesting |
boolean | No | Enable or disable the API testing module for this project |
enableAutoDocumentation |
boolean | No | Enable or disable automatic documentation for this project |
defaultResponseFormat |
string | No | Default response format: 'json' or 'xml' |
requestTimeoutSeconds |
integer | No | Request timeout in seconds |
projectId |
string | No | Public ID (GUID) of the project. If omitted, uses the active project context. |