---
canonical_url: "https://docs.composio.dev/toolkits/railway_mcp"
markdown_url: "https://docs.composio.dev/toolkits/railway_mcp.md"
product: "platform"
version: null
last_updated: null
---

# Railway MCP

Create, inspect, deploy, and manage Railway projects, services, environments, variables, and deployments through Railway's hosted MCP server.

- **Category:** developer tools
- **Auth:** OAUTH2
- **Composio-managed OAuth available?** No
- **Tools:** 46
- **Triggers:** 0
- **Slug:** `RAILWAY_MCP`
- **Version:** 20260910_00

## Tools

### Accept-deploy

**Slug:** `RAILWAY_MCP_ACCEPT_DEPLOY`

DESTRUCTIVE: Commits all staged changes in a Railway environment and triggers a deploy. Only use this when the user has explicitly confirmed they want to deploy.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `commitMessage` | string | No | Optional commit message for the deploy |
| `environmentId` | string | Yes | The environment ID to commit staged changes for |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `project` | object | No |  |
| `committed` | boolean | Yes | True when staged changes were committed and a deploy was triggered; false when the environment had nothing staged |
| `workflowId` | string | No | Deployment workflow ID, present only when committed |
| `environment` | object | No |  |
| `deploymentStatus` | string ("triggered" | "nothing_staged") | Yes | Whether a deployment workflow was started |

### Connect-service-source

**Slug:** `RAILWAY_MCP_CONNECT_SERVICE_SOURCE`

Attach a source to an existing service: a GitHub repository (deploys on push, builds immediately) or a Docker image. This is how a service that has never deployed gets its first deployment, and how an existing service's source is switched. Provide exactly one of repo or image. By default it applies to the service in all environments; pass staged: true with an environmentId to stage the source in that one environment's pending changes instead, in which case nothing builds until the staged changes are committed with accept-deploy.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `repo` | string | No | GitHub repository as owner/repo, e.g. railwayapp/starters. The user's GitHub account must have access to it. |
| `image` | string | No | Docker image to deploy, e.g. ghcr.io/org/app:latest |
| `branch` | string | No | Branch to deploy from. Only valid with repo; defaults to the repository's default branch. |
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID to attach the source to |
| `environmentId` | string | No | Environment to scope a staged source change to. Only valid with staged: true, and required by it — a live connect always applies to every environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `source` | object | Yes |  |
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `service` | object | Yes |  |

### Create-bucket

**Slug:** `RAILWAY_MCP_CREATE_BUCKET`

Create an S3-compatible object storage bucket in a project and provision it in an environment. Default region is sjc. Pass staged: true to stage the bucket in the environment's pending changes instead of provisioning it live — it then only becomes real when the staged changes are committed with accept-deploy.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | No | Name for the bucket. If omitted, a name is generated. |
| `region` | string ("sjc" | "iad" | "ams" | "sin") | No | Region to provision the bucket in (default: sjc) |
| `staged` | boolean | No | Stage the bucket in the environment's pending changes instead of provisioning it live. It becomes real only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `environmentId` | string | No | Environment to provision the bucket in. Defaults to the production environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `bucket` | object | Yes |  |
| `region` | string | Yes |  |
| `staged` | string | Yes | Present when the bucket was staged instead of applied. The bucket exists but is not provisioned until the staged changes are committed with accept-deploy. |
| `environment` | object | Yes |  |

### Create-deployment

**Slug:** `RAILWAY_MCP_CREATE_DEPLOYMENT`

Create a new service from a GitHub repository and trigger its first deployment. The repo must be one the authenticated user has connected via GitHub. Returns the new service; use get-status or list-deployments to follow the deploy.

Before calling this tool you MUST have a GitHub repo to deploy. If the user has not provided one, do not guess — first ask them which GitHub repo to deploy (in 'owner/name' form). If they don't have a repo yet, offer to help create one: if you have tools available to create a GitHub repository (e.g. a GitHub MCP server or `gh` CLI), offer to scaffold and push one for them; otherwise point them to create a repo on GitHub and share its 'owner/name'. Only call this tool once a concrete repo has been confirmed.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | No | Name for the new service. If omitted, a name is derived from the repo. |
| `repo` | string | Yes | The full name of the GitHub repo to deploy. e.g. 'railwayapp/starters' |
| `branch` | string | No | The branch to deploy. Defaults to 'main'. A branch is required to trigger the first deploy. |
| `projectId` | string | Yes | The project ID to deploy into |
| `environmentId` | string | No | Environment ID to deploy into. If omitted, the service is created in all non-fork environments. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `source` | object | Yes |  |
| `project` | object | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |
| `deploymentStatus` | string | Yes | Initial deployment was triggered asynchronously |

### Create-project

**Slug:** `RAILWAY_MCP_CREATE_PROJECT`

Create a new Railway project

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | Yes | Name for the new project |
| `isPublic` | boolean | No | Whether the project should be public (default: false) |
| `description` | string | No | Optional project description |
| `workspaceId` | string | No | Workspace ID to create the project in. If omitted, uses the first available workspace. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `project` | object | Yes |  |
| `environment` | object | Yes |  |
| `workspaceId` | string | Yes | Workspace containing the new project |

### Create-service

**Slug:** `RAILWAY_MCP_CREATE_SERVICE`

Create a new service in a project from a Docker image, or an empty service to configure later (e.g. before setting variables and attaching a source). Pass staged: true to stage the service in one environment instead of applying it live — it then only becomes real when the staged changes are committed with accept-deploy. To create a service from a GitHub repository, use create-deployment instead.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | No | Name for the new service. If omitted, a name is derived from the image or generated. |
| `image` | string | No | Docker image to deploy, e.g. 'redis' or 'ghcr.io/org/app:latest'. Omit to create an empty service. |
| `staged` | boolean | No | Stage the service in the environment's pending changes instead of applying it live. The service shows up on the canvas immediately but gets no instance until accept-deploy commits the staged changes (or the user applies them in the dashboard). Requires environmentId. |
| `projectId` | string | Yes | The project ID to create the service in |
| `environmentId` | string | No | Environment ID to create the service in. If omitted, the service is created in all non-fork environments. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `source` | string | Yes | Docker image source, or null for an empty service |
| `staged` | string | Yes | Present when the service was staged instead of applied. The service exists but has no instance until the staged changes are committed with accept-deploy. |
| `project` | object | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |

### Create-tcp-proxy

**Slug:** `RAILWAY_MCP_CREATE_TCP_PROXY`

Expose a service on the public internet over a raw TCP port (e.g. make a database reachable externally). Creates a TCP proxy forwarding a public endpoint to the given application port, applied through the environment config so the service redeploys with it active. Pass staged: true to stage the proxy in the environment's pending changes instead — it is only provisioned, and only gets a public endpoint, once the staged changes are committed with accept-deploy. A service can have at most one TCP proxy.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to the production environment. |
| `applicationPort` | integer | Yes | The port the service listens on, e.g. 5432 for Postgres |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `proxy` | string | Yes |  |
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `committed` | boolean | Yes |  |

### Create-volume

**Slug:** `RAILWAY_MCP_CREATE_VOLUME`

Create a persistent volume in a project and optionally attach it to a service at a mount path. The attach and redeploy are committed together so the service comes up with the mount applied. Pass staged: true to stage the volume in one environment instead of provisioning it live.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | No | Name for the volume. If omitted, a name is derived from the service or generated. |
| `staged` | boolean | No | Stage the volume in the environment's pending changes instead of provisioning it live. It becomes real only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). Requires environmentId. |
| `mountPath` | string | Yes | Path in the container to mount the volume at, e.g. /data |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | No | Service to attach the volume to. Omit to create an unattached volume. |
| `environmentId` | string | No | Environment to provision the volume in. If omitted, the volume is provisioned in all environments. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the volume was staged instead of applied. The volume exists but is not provisioned until the staged changes are committed with accept-deploy. |
| `volume` | object | Yes |  |
| `mountPath` | string | Yes |  |
| `serviceId` | string | Yes |  |
| `environment` | object | Yes |  |

### Delete-bucket

**Slug:** `RAILWAY_MCP_DELETE_BUCKET`

Permanently delete an object storage bucket and its contents. By default it is removed from every environment it is provisioned in; pass an environmentId to remove it from that one environment only. Pass staged: true to stage the removal in one environment instead of applying it live. Deleting from every environment is irreversible.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `bucketId` | string | Yes | The bucket ID to delete |
| `projectId` | string | Yes | The project ID the bucket belongs to |
| `environmentId` | string | No | Environment to remove the bucket from. If omitted, it is removed from every environment it is provisioned in. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `bucket` | object | Yes |  |
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `environmentIds` | array | Yes | Environments the bucket was removed from, or — when staged — the single environment the removal is staged in |

### Delete-feature-flag

**Slug:** `RAILWAY_MCP_DELETE_FEATURE_FLAG`

Delete a project-scoped feature flag. Workspace-scoped flags cannot be deleted from project context.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | Yes | Feature flag name to delete |
| `projectId` | string | Yes | The project ID |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | Yes | Deleted feature flag name |
| `scope` | string | Yes | Deleted feature flag scope |
| `deleted` | boolean | Yes | The feature flag was deleted |
| `projectId` | string | Yes | Project from which the flag was deleted |

### Delete-service

**Slug:** `RAILWAY_MCP_DELETE_SERVICE`

Permanently delete a service: its deployments stop and are removed, along with its domains, variables and deployment triggers. Any volume attached to it is detached and kept — delete-volume removes a volume and its data. By default the service is deleted in every environment that is not a fork; pass an environmentId to delete it in that one environment only. Pass staged: true to stage the removal in one environment instead of applying it live. A service whose creation is itself still staged is taken back out of the pending changes instead. This cannot be undone.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID the service belongs to |
| `serviceId` | string | Yes | The service ID to delete |
| `environmentId` | string | No | Environment to delete the service in. If omitted, it is deleted in every environment that is not a fork. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `service` | object | Yes |  |
| `environmentId` | string | Yes | Environment the service was removed from, or null for all |
| `detachedVolumes` | array | Yes | Volumes detached from the service and kept — on commit, when the removal is staged. Their data outlives the service; delete-volume is what removes it. |

### Delete-tcp-proxy

**Slug:** `RAILWAY_MCP_DELETE_TCP_PROXY`

Remove a service's TCP proxy, taking its public endpoint offline. Anything connecting through that endpoint (e.g. external database clients) loses access. Pass staged: true to stage the removal in the environment's pending changes instead — that is also how a proxy that is itself only staged gets dropped again.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to the production environment. |
| `applicationPort` | integer | Yes | The application port of the proxy to remove |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `proxy` | string | Yes | The proxy that was removed, or null when it was only staged and so never had a public endpoint. |
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |

### Delete-volume

**Slug:** `RAILWAY_MCP_DELETE_VOLUME`

Permanently delete a volume and its data. The volume is unmounted from any service it is attached to (redeploying that service). By default it is removed from every environment; pass an environmentId to remove it from that one environment only. Pass staged: true to stage the removal in one environment instead of applying it live. Deleting from every environment is irreversible.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `volumeId` | string | Yes | The volume ID to delete |
| `projectId` | string | Yes | The project ID the volume belongs to |
| `environmentId` | string | No | Environment to remove the volume from. If omitted, it is removed from every environment. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `volume` | object | Yes |  |

### Describe-environment

**Slug:** `RAILWAY_MCP_DESCRIBE_ENVIRONMENT`

Inventory of everything in a Railway environment — services, volumes, buckets, shared variable names — with staged changes applied. Each resource carries a `state`: live, staged-create (exists only in the pending patch), staged-delete, or live-with-staged-changes. Includes each service's source, regions, replicas, cron, volume mounts and latest deployment, and a `staged` summary of the pending patch. Pass `region` to keep only resources in that region. For per-field staged diffs use get-staged-changes; for one service's full config use describe-service; for runtime health use environment-status. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `region` | string | No | Only return services deploying to, and volumes/buckets provisioned in, this region (e.g. us-west2, sjc). |
| `projectId` | string | Yes | The project ID |
| `environmentId` | string | No | Environment to describe. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `region` | string | Yes | The region filter that was applied, if any |
| `staged` | string | Yes | The environment's pending patch, or null when nothing is staged |
| `buckets` | array | Yes |  |
| `project` | object | Yes |  |
| `volumes` | array | Yes |  |
| `services` | array | Yes |  |
| `environment` | object | Yes |  |
| `sharedVariableNames` | array | Yes |  |

### Describe-service

**Slug:** `RAILWAY_MCP_DESCRIBE_SERVICE`

Everything about one service in an environment: its config with staged changes applied (source, build, deploy, networking, volume mounts), the per-field staged changes pending on it, mounted volumes, live domains and TCP proxies, and the latest deployment. `state` says whether the service is live, staged-create, staged-delete, or live-with-staged-changes. Variable names are listed but values are not — use list-variables for values. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `config` | object | Yes | The service's config in this environment with staged changes applied: source, build, deploy, networking, volume mounts. Variable values and registry credentials are omitted. |
| `staged` | string | Yes | The environment's pending patch, or null when nothing is staged |
| `domains` | string | Yes | Live domains; null when the service is not live yet or the lookup failed |
| `service` | object | Yes |  |
| `volumes` | array | Yes |  |
| `tcpProxies` | string | Yes | Live TCP proxies; null when the service is not live yet or the lookup failed |
| `environment` | object | Yes |  |
| `stagedChanges` | array | Yes | Pending changes to this service, per field |
| `variableNames` | array | Yes |  |
| `latestDeployment` | string | Yes |  |

### Domain-status

**Slug:** `RAILWAY_MCP_DOMAIN_STATUS`

Get detailed status for one domain on a service, by hostname, URL, or domain ID: required DNS records and whether they currently match, ownership verification, certificate status, and any certificate error. Use list-domains first if you do not know which domains exist. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `domain` | string | Yes | Hostname, full URL, or domain ID. For example api.example.com, https://api.example.com, or the id from list-domains. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `domain` | object | Yes |  |
| `service` | object | Yes |  |
| `verified` | string | Yes | Whether ownership is verified. Null for a Railway domain. |
| `dnsRecords` | array | Yes | Empty for a Railway domain, which needs no DNS setup. |
| `certificate` | string | Yes | Null for a Railway domain, which has no separate certificate. |
| `environment` | object | Yes |  |
| `railwayManaged` | boolean | Yes | True for a Railway-generated domain: Railway owns its DNS and certificate, so there is nothing to verify or configure. |

### Environment-status

**Slug:** `RAILWAY_MCP_ENVIRONMENT_STATUS`

Health overview of every service in an environment in one call: current LIVE (settled) deployment state, replica status, recent failures, unresolved warnings/criticals, and cron execution results. Does not include uncommitted staged patch work. By default only services with issues are returned — pass includeSuccessful to see everything. For error details, follow up with get-logs on the deployment IDs returned here.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `limit` | integer | No | Maximum services to return (default 10) |
| `hoursBack` | integer | No | How many hours back to count failures (default 8) |
| `projectId` | string | Yes | The project ID |
| `environmentId` | string | No | Environment to check. Defaults to the production environment. |
| `serviceFilter` | string | No | Minimatch pattern to filter services by name — NOT fuzzy; wrap in wildcards for substring matching, e.g. "*api*". Omit for all services. |
| `includeSuccessful` | boolean | No | Include healthy services too (default false: only services with issues) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `summary` | object | Yes |  |
| `services` | array | Yes |  |
| `environment` | object | Yes |  |

### Fetch-docs

**Slug:** `RAILWAY_MCP_FETCH_DOCS`

Fetch the full markdown content of a Railway documentation page by URL or slug (e.g. 'https://docs.railway.com/quick-start' or 'reference/variables'). Use search-docs first to find the right page.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `url` | string | Yes | Documentation page URL or slug from search-docs results |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `size` | number | Yes | Full size of the page in bytes |
| `content` | string | Yes | The markdown content of the page |
| `pageFound` | boolean | Yes | False when the requested page does not exist and `content` holds search suggestions instead |
| `truncated` | boolean | Yes | Whether the content was truncated for size |
| `suggestions` | array | No | Candidate pages, present only when pageFound is false |

### Generate-domain

**Slug:** `RAILWAY_MCP_GENERATE_DOMAIN`

Expose a service publicly. Without `domain`, generates a Railway *.up.railway.app service domain (if the service already has domains, they are returned instead of creating another). With `domain`, attaches a custom domain you own and returns the DNS records the user must create for it to verify. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `domain` | string | No | A custom domain you own (e.g. app.example.com). Omit to generate a Railway domain. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `targetPort` | integer | No | Container port the domain routes to. Usually only needed when the service listens on multiple ports. |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `domain` | string | Yes |  |
| `created` | boolean | Yes | Whether a domain was created (false when existing domains were returned instead) |
| `dnsRecords` | array | Yes | For custom domains: the DNS records the user must create, with required vs current values |
| `domainType` | string | Yes |  |
| `existingDomains` | array | Yes |  |
| `certificateStatus` | string | Yes |  |

### Get-deployment-diagnosis

**Slug:** `RAILWAY_MCP_GET_DEPLOYMENT_DIAGNOSIS`

Get the AI-generated diagnosis for a failed deployment: root cause category, analysis, and suggested fixes, along with deployment context (service config, source repo, branch, commit, PR, failure stage and error). Diagnoses run automatically when a deployment fails — if one isn't available yet, fall back to get-logs to inspect the failure directly.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `deploymentId` | string | Yes | The deployment ID to get the diagnosis for |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `context` | string | Yes | Deployment context: service config, source repo/branch/commit, PR info, and failure details |
| `diagnosis` | string | Yes | The completed diagnosis, or null when none is available |
| `deploymentId` | string | Yes |  |
| `deploymentStatus` | string | Yes |  |

### Get-feature-flag

**Slug:** `RAILWAY_MCP_GET_FEATURE_FLAG`

Get a Railway feature flag (Signal) by name for a project or its parent workspace scope.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | Yes | Feature flag name |
| `scope` | string ("project" | "workspace") | No | Owner scope to read from (default "project") |
| `projectId` | string | Yes | The project ID |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `scope` | string ("project" | "workspace") | Yes | Scope from which the feature flag was read |
| `signal` | object | Yes |  |

### Get-logs

**Slug:** `RAILWAY_MCP_GET_LOGS`

Get logs from Railway for a deployment — covers deploy (runtime), build, and http (proxy request) contexts. Pass a specific deploymentId, or pass serviceId + environmentId to resolve the latest deployment. Use `types` to choose which streams to return (default: ['deploy']).

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `limit` | integer | No | Max log entries per stream (default 100, max 500) |
| `types` | array | No | Array of log stream names. Example: ["build", "deploy"]. Omit to fetch only deploy logs. |
| `filter` | string | No | Optional log filter expression (Loki-style, same syntax as the Railway dashboard). Applies to build and deploy streams. |
| `endDate` | string | No | ISO 8601 timestamp with an explicit timezone, at minute precision or finer. Example: "2026-07-27T15:30:00.000Z". Fractional seconds are optional; defaults to now. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | No | Service ID (used together with environmentId when deploymentId is not given) |
| `startDate` | string | No | ISO 8601 timestamp with an explicit timezone, at minute precision or finer. Example: "2026-07-27T14:30:00.000Z". Fractional seconds are optional. |
| `deploymentId` | string | No | A specific deployment ID. If omitted, serviceId and environmentId must be provided to resolve the most recent deployment. |
| `environmentId` | string | No | Environment ID to read logs from. Optional — when omitted with a serviceId, the project's production environment is used (or its oldest, if there is no production). |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `http` | array | No |  |
| `build` | array | No |  |
| `deploy` | array | No |  |
| `status` | string | Yes |  |
| `serviceId` | string | Yes |  |
| `deploymentId` | string | Yes |  |
| `environmentId` | string | Yes |  |

### Get-service-config

**Slug:** `RAILWAY_MCP_GET_SERVICE_CONFIG`

Prefer describe-service: it applies the staged diff onto the live config for you and adds mounted volumes, domains, TCP proxies and the latest deployment. Get a service's configuration in an environment: source (repo/image), build settings, deploy settings (start command, healthcheck, replicas, cron, restart policy), networking, and volume mounts. `config` is what is live; `staged` holds the not-yet-deployed changes as a diff against it, or null when nothing is staged. A service created with `staged: true` has an empty `config` until accept-deploy commits it. Variable names are listed but values are not included — use list-variables for values. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `config` | object | Yes | The service's live serialized config for this environment (source, build, deploy, networking, volume mounts). Variable values are omitted. Empty when the service exists only as a staged change. |
| `staged` | string | Yes | Changes staged in this environment but not deployed yet, or null when nothing is staged for this service. Commit them with accept-deploy. |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |
| `variableNames` | array | Yes | Names of variables defined directly on the service |

### Get-service-metrics

**Slug:** `RAILWAY_MCP_GET_SERVICE_METRICS`

Get resource usage metrics (CPU, memory, disk, network) for a service, summarized as current/average/min/max over a time window. Defaults to CPU_USAGE and MEMORY_USAGE_GB over the last hour. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `hoursBack` | integer | No | Time window in hours, up to 168 (7 days). Defaults to 1. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `measurements` | array | No | Array of measurement names. Example: ["CPU_USAGE", "MEMORY_USAGE_GB"]. Omit to use those defaults. |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |
| `sampleRateSeconds` | integer | No | Sampling rate in seconds |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `metrics` | array | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |

### Get-staged-changes

**Slug:** `RAILWAY_MCP_GET_STAGED_CHANGES`

Show the changes staged in a Railway environment that accept-deploy would commit: per resource (service, volume, bucket, group) the action — create, delete, update — and each changed field with its live and staged value. Variable values and registry credentials are redacted to names. Also reports whether the patch is destructive and whether a commit is already applying. Review this before calling accept-deploy. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `environmentId` | string | No | Environment to inspect. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | The environment's pending patch, or null when nothing is staged |
| `project` | object | Yes |  |
| `resources` | array | Yes | Staged changes grouped by the service, volume, bucket or group they touch |
| `destructive` | boolean | Yes | True when committing would delete a service, volume or bucket, or otherwise destroy data. accept-deploy may refuse such commits; the user can apply them from the dashboard. |
| `environment` | object | Yes |  |
| `sharedVariables` | array | Yes | Staged shared-variable changes, names only |
| `privateNetworkDisabled` | string | Yes | Staged private-networking toggle, if any |

### Get-status

**Slug:** `RAILWAY_MCP_GET_STATUS`

Prefer describe-environment: it also lists services that exist only in the staged patch, unattached volumes, and each resource's staged state. Get the deployment status of a Railway project environment. Returns project + environment metadata, whether the environment has undeployed staged changes, the environment's buckets, and for each live service its latest deployment status, replica count, cron schedule, and attached volumes. If environmentId is omitted, the project's `production` environment is used when present, otherwise the oldest environment.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `environmentId` | string | No | Environment to report on. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `buckets` | array | Yes |  |
| `project` | object | Yes |  |
| `services` | array | Yes |  |
| `environment` | object | Yes |  |

### Http-error-rate

**Slug:** `RAILWAY_MCP_HTTP_ERROR_RATE`

Get the HTTP error rate for a service over time — the share of requests answered with a 5xx. Use this for reliability and to locate error spikes. 4xx responses are reported separately and are not counted in the rate, since a 404 or a rejected payload is usually the caller's doing. Defaults to the last hour. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `path` | string | No | Restrict to one request path. |
| `method` | string | No | Restrict to one HTTP method, e.g. GET. |
| `hoursBack` | integer | No | Time window in hours, up to 168 (7 days). Defaults to 1. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |
| `maxDataPoints` | integer | No | Target number of buckets across the window. Defaults to 30, max 60 — the same cap the chat agent uses. Buckets are never finer than one minute, so a short window returns fewer than requested. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `window` | object | Yes |  |
| `overall` | object | Yes |  |
| `samples` | array | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |
| `worstBucket` | string | Yes | Bucket with the highest error rate, if any traffic |

### Http-requests

**Slug:** `RAILWAY_MCP_HTTP_REQUESTS`

Get HTTP request counts for a service, bucketed over time and split by response status class (2xx/3xx/4xx/5xx). Use this for traffic volume and the mix of successful versus failing responses. Defaults to the last hour. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `path` | string | No | Restrict to one request path. |
| `method` | string | No | Restrict to one HTTP method, e.g. GET. |
| `hoursBack` | integer | No | Time window in hours, up to 168 (7 days). Defaults to 1. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |
| `maxDataPoints` | integer | No | Target number of buckets across the window. Defaults to 30, max 60 — the same cap the chat agent uses. Buckets are never finer than one minute, so a short window returns fewer than requested. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `totals` | object | Yes |  |
| `window` | object | Yes |  |
| `samples` | array | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |

### Http-response-time

**Slug:** `RAILWAY_MCP_HTTP_RESPONSE_TIME`

Get HTTP latency percentiles (p50, p90, p95, p99) for a service, bucketed over time, in milliseconds. Use this for performance and to find slow requests. Defaults to the last hour. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `path` | string | No | Restrict to one request path. |
| `method` | string | No | Restrict to one HTTP method, e.g. GET. |
| `hoursBack` | integer | No | Time window in hours, up to 168 (7 days). Defaults to 1. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `statusCode` | integer | No | Restrict to one exact response status code, e.g. 200. |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |
| `maxDataPoints` | integer | No | Target number of buckets across the window. Defaults to 30, max 60 — the same cap the chat agent uses. Buckets are never finer than one minute, so a short window returns fewer than requested. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `window` | object | Yes |  |
| `samples` | array | Yes |  |
| `service` | object | Yes |  |
| `environment` | object | Yes |  |
| `slowestBucket` | string | Yes | Bucket with the highest p95, if any traffic |

### List-deployments

**Slug:** `RAILWAY_MCP_LIST_DEPLOYMENTS`

List recent deployments for a Railway project, optionally filtered by environment, service, or status. Returns the most recent first.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `limit` | integer | No | Max deployments to return (default 10, max 50) |
| `status` | string ("WAITING" | "NEEDS_APPROVAL" | "QUEUED" | "INITIALIZING" | "SKIPPED" | "BUILDING" | "DEPLOYING" | "SUCCESS" | "FAILED" | "REMOVED" | "CRASHED" | "REMOVING" | "SLEEPING") | No | Filter to deployments with this status (e.g. SUCCESS, FAILED, CRASHED, BUILDING, DEPLOYING) |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | No | Filter to a specific service |
| `environmentId` | string | No | Filter to a specific environment |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `deployments` | array | Yes |  |

### List-domains

**Slug:** `RAILWAY_MCP_LIST_DOMAINS`

List all domains (Railway-generated service domains and custom domains) for a service in an environment. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `service` | object | Yes |  |
| `environment` | object | Yes |  |
| `customDomains` | array | Yes | User-owned custom domains |
| `serviceDomains` | array | Yes | Railway-generated *.up.railway.app domains |

### List-feature-flags

**Slug:** `RAILWAY_MCP_LIST_FEATURE_FLAGS`

List Railway feature flags (Signals) for a project and optionally the parent workspace. Project flags are editable with admin access; workspace flags are read-only from project context.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `includeWorkspace` | boolean | No | Include workspace-scoped flags inherited by the project (default true) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `project` | object | Yes |  |
| `projectFlags` | array | Yes | Feature flags owned by the project |
| `workspaceFlags` | array | Yes | Feature flags inherited from the parent workspace |
| `includeWorkspace` | boolean | Yes | Whether inherited workspace-scoped flags were requested |

### List-projects

**Slug:** `RAILWAY_MCP_LIST_PROJECTS`

List all Railway projects accessible to the authenticated user

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projects` | array | Yes |  |

### List-services

**Slug:** `RAILWAY_MCP_LIST_SERVICES`

List the ids and names of all services and environments in a Railway project. Prefer describe-environment for what is actually in an environment: it includes volumes, buckets, deployments and staged changes.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID to list services for |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `project` | object | Yes |  |
| `services` | array | Yes |  |
| `environments` | array | Yes |  |

### List-tcp-proxies

**Slug:** `RAILWAY_MCP_LIST_TCP_PROXIES`

List the TCP proxies exposing a service over the public internet on a raw TCP port (e.g. a database's public endpoint). Returns the public endpoint (host:port) and the application port each proxy forwards to.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to the production environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `proxies` | array | Yes |  |

### List-variables

**Slug:** `RAILWAY_MCP_LIST_VARIABLES`

List all environment variables for a service, fully rendered (reference variables like ${{Postgres.DATABASE_URL}} are resolved). With a Railway session or API token, values are returned in plaintext and may contain secrets. Connected OAuth apps receive variable names only. Sealed variables are always listed by name with no value — they are set, but nobody can read them back, so never recreate one. If environmentId is omitted, the production environment is used.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `service` | object | Yes |  |
| `variables` | object | No | Readable variables as a name → value map. Never includes sealed variables. Omitted for OAuth-authenticated clients, which receive names only. |
| `environment` | object | Yes |  |
| `variableNames` | array | Yes | All variable names, sorted, including sealed ones |
| `valuesRedacted` | boolean | Yes | True when values were withheld and only names are returned |
| `sealedVariableNames` | array | Yes | Names of the sealed variables, sorted. These are already set on the service; their values cannot be read back by anyone, including the user. Do not treat them as missing and do not recreate them. |

### List-workspaces

**Slug:** `RAILWAY_MCP_LIST_WORKSPACES`

List the Railway workspaces the current user belongs to. Use a workspace ID with create-project to choose where a project is created.

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `workspaces` | array | Yes |  |

### Railway-agent

**Slug:** `RAILWAY_MCP_RAILWAY_AGENT`

Send a message to Railway's AI agent for complex infrastructure operations. The agent can inspect services, diagnose issues, and take actions on your behalf.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `message` | string | Yes | The message to send to the agent |
| `threadId` | string | No | Thread ID to continue an existing conversation. Omit to start a new one. |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | No | Optional service ID to scope the agent's context |
| `environmentId` | string | Yes | The environment ID |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `response` | string | Yes | Railway Agent's final response text |
| `threadId` | string | Yes | Thread ID for continuing the agent conversation |
| `toolCalls` | array | Yes | Sub-tools used while producing the response |

### Redeploy

**Slug:** `RAILWAY_MCP_REDEPLOY`

Re-run the most recent deployment of a service in a given environment, reusing that deployment's existing build. Only works on a service that has already deployed in that environment — check with list-deployments if you are unsure. This does NOT give a service its first deployment: if it has never deployed, nothing here can deploy it — use the Railway CLI (`railway up --project <id> --environment <id> --service <id>`), or attach a GitHub repo to the service in the dashboard. create-deployment would build a separate new service from a GitHub repo rather than deploying this one.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID to redeploy |
| `environmentId` | string | Yes | The environment ID to redeploy in |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `deployment` | object | Yes |  |

### Restart-service

**Slug:** `RAILWAY_MCP_RESTART_SERVICE`

Restart a service's running deployment in place — the containers restart without rebuilding the image, and no new deployment is created (use redeploy for a fresh build copy). Restarting causes brief downtime; do NOT restart database services (Postgres, MySQL, Redis, MongoDB) or services with attached volumes unless the user explicitly asked, as it can interrupt in-flight queries and transactions.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID to restart |
| `deploymentId` | string | No | Specific deployment to restart. If omitted, the latest running or crashed deployment is restarted. |
| `environmentId` | string | No | Environment whose deployment to restart. Defaults to the production environment. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `service` | object | Yes |  |
| `deploymentId` | string | Yes | The deployment that was restarted |
| `environmentId` | string | Yes |  |

### Search-docs

**Slug:** `RAILWAY_MCP_SEARCH_DOCS`

Search the Railway documentation (docs.railway.com) for features, configuration, guides, and tutorials. Returns matching sections with URLs — use fetch-docs to read a full page.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `query` | string | Yes | The search query (e.g. 'environment variables', 'deploy docker', 'postgres connection') |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `results` | array | Yes |  |

### Set-feature-flag

**Slug:** `RAILWAY_MCP_SET_FEATURE_FLAG`

Create a project-scoped feature flag or update its default value. Use list-feature-flags and get-feature-flag to inspect existing flags first.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | Yes | Feature flag name (letters, numbers, dots, dashes, underscores) |
| `type` | string ("bool" | "string" | "number" | "json") | No | Flag type (required when creating a new flag) |
| `projectId` | string | Yes | The project ID |
| `defaultValue` | string | Yes | Default value as text: "true"/"false", a raw string, a number, or JSON |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `signal` | object | Yes |  |
| `operation` | string ("created" | "updated") | Yes | Whether the feature flag was created or its default was updated |

### Set-variables

**Slug:** `RAILWAY_MCP_SET_VARIABLES`

Set one or more environment variables on a service (or environment-wide shared variables when serviceId is omitted). Existing variables with the same name are overwritten; others are left unchanged. Reference syntax like ${{Postgres.DATABASE_URL}} is supported. Affected services are redeployed unless skipDeploys is true. Pass staged: true to stage the variables in the environment's pending changes instead of setting them live — nothing is written or redeployed until the staged changes are committed with accept-deploy.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | No | The service to set variables on. Omit to set environment-level shared variables. |
| `variables` | object | Yes | Object mapping variable names to string values. Example: {"NODE_ENV":"production","PORT":"3000"}. |
| `skipDeploys` | boolean | No | Skip redeploying the affected services. Implied by staged: true, which deploys nothing until the patch is committed. |
| `environmentId` | string | No | Environment ID. Defaults to `production` if present, otherwise the project's oldest environment. That default applies to staged: true as well — unlike the other staging tools this one never refuses an omitted environmentId, so pass one explicitly unless you mean to stage onto production. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `serviceId` | string | Yes | Service the variables were set on, or null for shared |
| `environment` | object | Yes |  |
| `variableNames` | array | Yes |  |
| `skippedDeploys` | boolean | Yes |  |

### Update-service

**Slug:** `RAILWAY_MCP_UPDATE_SERVICE`

Update a service's configuration: build/start/pre-deploy commands, healthcheck, sleep mode, root directory, cron schedule, Dockerfile path, restart policy, config file path, and watch patterns. Only the fields you pass are changed. Changes apply on the service's next deployment (use redeploy to apply immediately). Pass staged: true to stage the update in one environment's pending changes instead of writing it to the service — it then applies when the staged changes are committed with accept-deploy. Scaling (replicas/regions) and source changes are not handled by this tool.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `projectId` | string | Yes | The project ID |
| `serviceId` | string | Yes | The service ID |
| `buildCommand` | string | No | Custom build command |
| `cronSchedule` | string | No | Cron schedule, e.g. '0 * * * *'. Minimum interval is 5 minutes. Pass null to remove the schedule and run the service continuously. |
| `startCommand` | string | No | Custom start command |
| `environmentId` | string | No | Environment to update. If omitted, the service is updated in all environments. Required when staged is true. |
| `rootDirectory` | string | No | Root directory for builds, e.g. /packages/api. With staged: true this counts as a source change: committing it recreates the service's deployment triggers and re-resolves its GitHub authorization from whoever commits. Stage it on its own if that matters. |
| `watchPatterns` | array | No | File patterns that trigger automatic redeploys |
| `dockerfilePath` | string | No | Path to a custom Dockerfile |
| `healthcheckPath` | string | No | HTTP healthcheck path, e.g. /health |
| `preDeployCommand` | array | No | Commands run before each deploy |
| `sleepApplication` | boolean | No | Enable/disable app sleeping (serverless mode) |
| `railwayConfigFile` | string | No | Path to a railway config file, e.g. railway.toml |
| `restartPolicyType` | string ("ALWAYS" | "NEVER" | "ON_FAILURE") | No | Restart policy for crashed deployments |
| `healthcheckTimeout` | string | No | Healthcheck timeout in seconds (0-3600). Pass null to reset. |
| `restartPolicyMaxRetries` | integer | No | Max restart retries for ON_FAILURE policy |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `service` | object | Yes |  |
| `environmentId` | string | Yes | Environment updated, or null when all environments were |
| `updatedFields` | array | Yes |  |

### Update-volume

**Slug:** `RAILWAY_MCP_UPDATE_VOLUME`

Update a volume's name and/or mount path. A mount path change redeploys the affected service so the new mount takes effect. Only the fields you pass are changed. Pass staged: true with an environmentId to stage the mount change in that environment's pending changes instead of applying it live; the volume's name is not environment-scoped and cannot be staged.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | string | No | New name for the volume |
| `staged` | boolean | No | Stage the change in the environment's pending changes instead of applying it live. It takes effect only when the staged changes are committed with accept-deploy (or the user applies them in the dashboard). |
| `volumeId` | string | Yes | The volume ID to update |
| `mountPath` | string | No | New mount path, e.g. /data. Redeploys the mounted service. |
| `projectId` | string | Yes | The project ID the volume belongs to |
| `serviceId` | string | No | Service to attach/move the volume to when changing the mount. If omitted, the volume stays on the service it is already attached to. |
| `environmentId` | string | No | Environment whose volume instance to update. If omitted, the mount change applies in every environment the volume is provisioned in. Required when staged is true. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `staged` | string | Yes | Present when the change was staged instead of applied. It takes effect only when the staged changes are committed with accept-deploy. |
| `volume` | object | Yes |  |
| `updatedFields` | array | Yes |  |

### Whoami

**Slug:** `RAILWAY_MCP_WHOAMI`

Get the current authenticated Railway user's profile information

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes |  |
| `name` | string | Yes |  |
| `email` | string | Yes |  |
| `username` | string | Yes |  |
| `createdAt` | string | Yes |  |
| `workspace` | string | Yes |  |
| `registrationStatus` | string | Yes |  |
