Claude-code-templates railway-templates
Search and deploy services from Railway's template marketplace. Use when user wants to add a service from a template, find templates for a specific use case, or deploy tools like Ghost, Strapi, n8n, Minio, Uptime Kuma, etc. For databases (Postgres, Redis, MySQL, MongoDB), prefer the railway-database skill.
install
source · Clone the upstream repo
git clone https://github.com/davila7/claude-code-templates
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/davila7/claude-code-templates "$T" && mkdir -p ~/.claude/skills && cp -r "$T/cli-tool/components/skills/railway/templates" ~/.claude/skills/davila7-claude-code-templates-railway-templates && rm -rf "$T"
manifest:
cli-tool/components/skills/railway/templates/SKILL.mdsource content
Railway Templates
Search and deploy services from Railway's template marketplace.
When to Use
- User asks to "add Postgres", "add Redis", "add a database"
- User asks to "add Ghost", "add Strapi", "add n8n", or any other service
- User wants to find templates for a use case (e.g., "CMS", "storage", "monitoring")
- User asks "what templates are available?"
- User wants to deploy a pre-configured service
Common Template Codes
| Category | Template | Code |
|---|---|---|
| Databases | PostgreSQL | |
| Redis | | |
| MySQL | | |
| MongoDB | | |
| CMS | Ghost | |
| Strapi | | |
| Storage | Minio | |
| Automation | n8n | |
| Monitoring | Uptime Kuma | |
For other templates, use the search query below.
Prerequisites
Get project context:
railway status --json
Extract:
- project IDid
- environment IDenvironments.edges[0].node.id
Get workspace ID:
bash <<'SCRIPT' ${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \ 'query getWorkspace($projectId: String!) { project(id: $projectId) { workspaceId } }' \ '{"projectId": "PROJECT_ID"}' SCRIPT
Search Templates
List available templates with optional filters:
bash <<'SCRIPT' ${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \ 'query templates($first: Int, $verified: Boolean) { templates(first: $first, verified: $verified) { edges { node { name code description category } } } }' \ '{"first": 20, "verified": true}' SCRIPT
Arguments
| Argument | Type | Description |
|---|---|---|
| Int | Number of results (max ~100) |
| Boolean | Only verified templates |
| Boolean | Only recommended templates |
Rate Limit
10 requests per minute. Don't spam searches.
Get Template Details
Fetch a specific template by code:
bash <<'SCRIPT' ${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \ 'query template($code: String!) { template(code: $code) { id name description serializedConfig } }' \ '{"code": "postgres"}' SCRIPT
Returns:
- template ID (needed for deployment)id
- service configuration (needed for deployment)serializedConfig
Deploy Template
Step 1: Fetch Template
bash <<'SCRIPT' ${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \ 'query template($code: String!) { template(code: $code) { id serializedConfig } }' \ '{"code": "postgres"}' SCRIPT
Step 2: Deploy to Project
bash <<'SCRIPT' ${CLAUDE_PLUGIN_ROOT}/skills/lib/railway-api.sh \ 'mutation deployTemplate($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }' \ '{ "input": { "templateId": "TEMPLATE_ID_FROM_STEP_1", "serializedConfig": SERIALIZED_CONFIG_FROM_STEP_1, "projectId": "PROJECT_ID", "environmentId": "ENVIRONMENT_ID", "workspaceId": "WORKSPACE_ID" } }' SCRIPT
Important:
serializedConfig is the exact JSON object from the template query, not a string.
Composability
- Connect services: Use railway-environment skill to add variable references
- View deployed service: Use railway-service skill
- Check logs: Use railway-deployment skill
- Add domains: Use railway-domain skill