{
  "manifest_version": "1.0.0",
  "template": {
    "id": "a9d7cdd2-baf8-4db0-aa7b-d51557f1d350",
    "slug": "9router-5",
    "name": "9Router",
    "description": "AI gateway with provider routing, API keys and persistent SQLite.",
    "url": "https://railway.com/deploy/9router-5",
    "upstream": {
      "repo_url": "https://github.com/Timboslice212/9router-railway"
    }
  },
  "services": [
    {
      "name": "9Router",
      "source": {
        "repo": "https://github.com/Timboslice212/9router-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/app/data",
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "9Router",
      "description": "Listening port for the dashboard and AI gateway; matches the public domain target port.",
      "secret": false,
      "strategy": "default",
      "default": "20128"
    },
    {
      "key": "BASE_URL",
      "service": "9Router",
      "description": "Instance URL generated from this deployment's Railway public domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "DATA_DIR",
      "service": "9Router",
      "description": "Persistent SQLite, settings, credentials and backup directory; must match the /app/data volume mount.",
      "secret": false,
      "strategy": "default",
      "default": "/app/data"
    },
    {
      "key": "HOSTNAME",
      "service": "9Router",
      "description": "Bind to all container interfaces so Railway can route requests.",
      "secret": false,
      "strategy": "default",
      "default": "0.0.0.0"
    },
    {
      "key": "NODE_ENV",
      "service": "9Router",
      "description": "Use the production application runtime.",
      "secret": false,
      "strategy": "default",
      "default": "production"
    },
    {
      "key": "JWT_SECRET",
      "service": "9Router",
      "description": "Generated signing secret for dashboard sessions. Keep private and stable across restarts.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "API_KEY_SECRET",
      "service": "9Router",
      "description": "Generated HMAC secret for gateway API keys. Keep private and stable across restarts.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "MACHINE_ID_SALT",
      "service": "9Router",
      "description": "Generated per-instance salt for consistent machine identity.",
      "secret": false,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "INITIAL_PASSWORD",
      "service": "9Router",
      "description": "Initial dashboard password: 123456. On first login, choose a new password before accessing the dashboard. Complete setup immediately.",
      "secret": true,
      "strategy": "default",
      "default": "123456"
    },
    {
      "key": "AUTH_COOKIE_SECURE",
      "service": "9Router",
      "description": "Send dashboard session cookies only over HTTPS.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "ENABLE_REQUEST_LOGS",
      "service": "9Router",
      "description": "Disable request payload logging to reduce sensitive prompt storage.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "OBSERVABILITY_ENABLED",
      "service": "9Router",
      "description": "Disable optional detailed observability storage by default.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "NEXT_TELEMETRY_DISABLED",
      "service": "9Router",
      "description": "Disable Next.js telemetry.",
      "secret": false,
      "strategy": "default",
      "default": "1"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "9router-5"
      }
    },
    "cli": "railway deploy --template 9router-5",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "a9d7cdd2-baf8-4db0-aa7b-d51557f1d350",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "77f08fd9-5d26-44c7-8f78-f491a48b353e": {
                  "icon": "https://raw.githubusercontent.com/decolua/9router/ce4460ef79382bfddb4aa5fc0ff9f3cb0d5f95a8/public/favicon.svg",
                  "name": "9Router",
                  "deploy": {
                    "startCommand": "node custom-server.js",
                    "healthcheckPath": "/api/health",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/Timboslice212/9router-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Listening port for the dashboard and AI gateway; matches the public domain target port.",
                      "defaultValue": "20128"
                    },
                    "BASE_URL": {
                      "isOptional": false,
                      "description": "Instance URL generated from this deployment's Railway public domain.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "DATA_DIR": {
                      "isOptional": false,
                      "description": "Persistent SQLite, settings, credentials and backup directory; must match the /app/data volume mount.",
                      "defaultValue": "/app/data"
                    },
                    "HOSTNAME": {
                      "isOptional": false,
                      "description": "Bind to all container interfaces so Railway can route requests.",
                      "defaultValue": "0.0.0.0"
                    },
                    "NODE_ENV": {
                      "isOptional": false,
                      "description": "Use the production application runtime.",
                      "defaultValue": "production"
                    },
                    "JWT_SECRET": {
                      "isOptional": false,
                      "description": "Generated signing secret for dashboard sessions. Keep private and stable across restarts.",
                      "defaultValue": "{{JWT_SECRET}}"
                    },
                    "API_KEY_SECRET": {
                      "isOptional": false,
                      "description": "Generated HMAC secret for gateway API keys. Keep private and stable across restarts.",
                      "defaultValue": "{{API_KEY_SECRET}}"
                    },
                    "MACHINE_ID_SALT": {
                      "isOptional": false,
                      "description": "Generated per-instance salt for consistent machine identity.",
                      "defaultValue": "{{MACHINE_ID_SALT}}"
                    },
                    "INITIAL_PASSWORD": {
                      "isOptional": false,
                      "description": "Initial dashboard password: 123456. On first login, choose a new password before accessing the dashboard. Complete setup immediately.",
                      "defaultValue": "123456"
                    },
                    "AUTH_COOKIE_SECURE": {
                      "isOptional": false,
                      "description": "Send dashboard session cookies only over HTTPS.",
                      "defaultValue": "true"
                    },
                    "ENABLE_REQUEST_LOGS": {
                      "isOptional": false,
                      "description": "Disable request payload logging to reduce sensitive prompt storage.",
                      "defaultValue": "false"
                    },
                    "OBSERVABILITY_ENABLED": {
                      "isOptional": false,
                      "description": "Disable optional detailed observability storage by default.",
                      "defaultValue": "false"
                    },
                    "NEXT_TELEMETRY_DISABLED": {
                      "isOptional": false,
                      "description": "Disable Next.js telemetry.",
                      "defaultValue": "1"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:20128": {
                        "port": 20128
                      }
                    }
                  },
                  "volumeMounts": {
                    "77f08fd9-5d26-44c7-8f78-f491a48b353e": {
                      "mountPath": "/app/data"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "9Router",
      "method": "GET",
      "path": "/api/health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 1,
    "needs_volume": true
  },
  "generated_at": "2026-10-12T22:14:42.224Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-10-12T22:21:14.708Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_bb7040007959407ab2c5",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 245,
    "typical_build_seconds": 197,
    "typical_start_seconds": 0,
    "slowest_service": "9Router"
  }
}
