Loading...
Loading...
Check service status, rename services, change service icons, link services, or create services with Docker images. For creating services with local code, prefer railway-new skill. For GitHub repo sources, use railway-new skill to create empty service then railway-environment skill to configure source.
npx skill4agent add davila7/claude-code-templates railway-servicerailway status --jsonproject.idenvironment.idmutation serviceCreate($input: ServiceCreateInput!) {
serviceCreate(input: $input) {
id
name
}
}| Field | Type | Description |
|---|---|---|
| String! | Project ID (required) |
| String | Service name (auto-generated if omitted) |
| String | Docker image (e.g., |
| String | GitHub repo (e.g., |
| String | Git branch for repo source |
| String | If set and is a fork, only creates in that env |
bash <<'SCRIPT'
${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \
'mutation createService($input: ServiceCreateInput!) {
serviceCreate(input: $input) { id name }
}' \
'{"input": {"projectId": "PROJECT_ID"}}'
SCRIPTbash <<'SCRIPT'
${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \
'mutation createService($input: ServiceCreateInput!) {
serviceCreate(input: $input) { id name }
}' \
'{"input": {"projectId": "PROJECT_ID", "name": "my-service", "source": {"image": "nginx:latest"}}}'
SCRIPTserviceCreate(input: {projectId: "...", name: "my-service"}){
"services": {
"<serviceId>": {
"isCreated": true,
"source": { "image": "nginx:latest" },
"variables": {
"PORT": { "value": "8080" }
}
}
}
}isCreated: truerailway service status --jsonrailway deployment list --json --limit 5| Status | Meaning |
|---|---|
| SUCCESS | Deployed and running |
| FAILED | Build or deploy failed |
| DEPLOYING | Currently deploying |
| BUILDING | Build in progress |
| CRASHED | Runtime crash |
| REMOVED | Deployment removed |
railway status --jsonservice.idbash <<'SCRIPT'
${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \
'mutation updateService($id: String!, $input: ServiceUpdateInput!) {
serviceUpdate(id: $id, input: $input) { id name }
}' \
'{"id": "SERVICE_ID", "input": {"name": "new-name"}}'
SCRIPT| Type | Example |
|---|---|
| Image URL | |
| Animated GIF | |
| Devicons | |
https://devicons.railway.app/{query}githubpostgresredisnodejsbash <<'SCRIPT'
${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \
'mutation updateService($id: String!, $input: ServiceUpdateInput!) {
serviceUpdate(id: $id, input: $input) { id icon }
}' \
'{"id": "SERVICE_ID", "input": {"icon": "https://devicons.railway.app/github"}}'
SCRIPT| Field | Type | Description |
|---|---|---|
| String | Service name |
| String | Emoji or image URL (including animated GIFs) |
railway service linkrailway service link <service-name>isDeleted: trueNo service linked. Run `railway service link` to link a service.Service exists but has no deployments yet. Deploy with `railway up`.Service "foo" not found. Check available services with `railway status`.railway status