{
  "manifest_version": "1.0.0",
  "template": {
    "id": "aad04550-f6d2-450b-b5bd-09818b1a39de",
    "slug": "lead-rescue-ai-by--1",
    "name": "Lead Rescue AI by Dev101Labs",
    "description": "Lead dashboard with optional AI, consent-based email, Postgres and Redis.",
    "url": "https://railway.com/deploy/lead-rescue-ai-by--1",
    "upstream": {
      "image": "ghcr.io/dev101labshq/lead-rescue-web@sha256:48f13757a40c5756c497ad4b0907db4f4a8da9b146f1e5c2e5d2fa1b8dbff005"
    }
  },
  "status": "unvalidated",
  "validated_at": null,
  "success_rate_30d": null,
  "services": [
    {
      "name": "Redis",
      "source": {
        "image": "redis:7-bookworm"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    },
    {
      "name": "Postgres",
      "source": {
        "image": "postgres:17-bookworm"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "lead-rescue-web",
      "source": {
        "image": "ghcr.io/dev101labshq/lead-rescue-web@sha256:48f13757a40c5756c497ad4b0907db4f4a8da9b146f1e5c2e5d2fa1b8dbff005"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "lead-rescue-worker",
      "source": {
        "image": "ghcr.io/dev101labshq/lead-rescue-worker@sha256:5421f954ce3ba482aecb001be5aa2cd1b3773cec36a33566e11f861ddeb18d29"
      },
      "needs_volume": false,
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "REDIS_URL",
      "service": "Redis",
      "description": "Private Redis queue connection reference. Keep database and queue services private.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "REDIS_PASSWORD",
      "service": "Redis",
      "description": "Generated private Redis password used by the authenticated start command.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "PGDATA",
      "service": "Postgres",
      "description": "Postgres 17 data directory beneath the persistent volume.",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres",
      "description": "Application database name for this installation.",
      "secret": false,
      "strategy": "default",
      "default": "leadrescue"
    },
    {
      "key": "DATABASE_URL",
      "service": "Postgres",
      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres",
      "description": "Application database username for this installation.",
      "secret": false,
      "strategy": "default",
      "default": "leadrescue"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres",
      "description": "Generated private Postgres password. Do not copy a password from another deployment.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "PORT",
      "service": "lead-rescue-web",
      "description": "Web application listen port. Match the HTTP proxy port 8080.",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "APP_URL",
      "service": "lead-rescue-web",
      "description": "Generated HTTPS application origin. Update if you use a custom domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "NODE_ENV",
      "service": "lead-rescue-web",
      "description": "Production runtime with HTTPS administrator authentication.",
      "secret": false,
      "strategy": "default",
      "default": "production"
    },
    {
      "key": "REDIS_URL",
      "service": "lead-rescue-web",
      "description": "Private Redis queue connection reference. Keep database and queue services private.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "GROQ_MODEL",
      "service": "lead-rescue-web",
      "description": "Groq structured-output model. Verify availability before enabling AI.",
      "secret": false,
      "strategy": "default",
      "default": "openai/gpt-oss-20b"
    },
    {
      "key": "ADMIN_EMAIL",
      "service": "lead-rescue-web",
      "description": "Your own administrator email. Required for first login and owner email tests.",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "AI_PROVIDER",
      "service": "lead-rescue-web",
      "description": "Optional AI provider. Groq is the initial supported beta choice; credentials are supplied separately.",
      "secret": false,
      "strategy": "default",
      "default": "groq"
    },
    {
      "key": "BETA_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "DATABASE_URL",
      "service": "lead-rescue-web",
      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "GEMINI_MODEL",
      "service": "lead-rescue-web",
      "description": "Gemini model for the optional provider; verify availability and quota before use.",
      "secret": false,
      "strategy": "default",
      "default": "gemini-3.5-flash-lite"
    },
    {
      "key": "ADMIN_PASSWORD",
      "service": "lead-rescue-web",
      "description": "Generated bootstrap password. Change it at /account after first login, then remove this variable.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "SESSION_SECRET",
      "service": "lead-rescue-web",
      "description": "Generated private session signing secret. Keep stable; changing it signs out sessions.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "AI_LIVE_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "AI_TEST_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "BETA_AI_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "BETA_EMAIL_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "BETA_TESTER_EMAILS",
      "service": "lead-rescue-web",
      "description": "Comma-separated approved tester addresses. Defaults to your administrator; no customer recipients.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "EMAIL_REPLY_SECRET",
      "service": "lead-rescue-web",
      "description": "Generated shared secret for signed email reply addresses. Web and worker must use the same value.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "ALLOW_LIVE_DELIVERY",
      "service": "lead-rescue-web",
      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "EMAIL_BETA_TEST_ENABLED",
      "service": "lead-rescue-web",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "REDIS_URL",
      "service": "lead-rescue-worker",
      "description": "Private Redis queue connection reference. Keep database and queue services private.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "ADMIN_EMAIL",
      "service": "lead-rescue-worker",
      "description": "Your own administrator email. Required for first login and owner email tests.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "BETA_ENABLED",
      "service": "lead-rescue-worker",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "lead-rescue-worker",
      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "BETA_EMAIL_ENABLED",
      "service": "lead-rescue-worker",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "BETA_TESTER_EMAILS",
      "service": "lead-rescue-worker",
      "description": "Comma-separated approved tester addresses. Defaults to your administrator; no customer recipients.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "EMAIL_REPLY_SECRET",
      "service": "lead-rescue-worker",
      "description": "Generated shared secret for signed email reply addresses. Web and worker must use the same value.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "ALLOW_LIVE_DELIVERY",
      "service": "lead-rescue-worker",
      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "INBOUND_EMAIL_DOMAIN",
      "service": "lead-rescue-worker",
      "description": "Your receiving subdomain verified in Resend. Separate from existing mailbox DNS.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "EMAIL_BETA_TEST_ENABLED",
      "service": "lead-rescue-worker",
      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "lead-rescue-ai-by--1"
      }
    },
    "cli": "railway deploy --template lead-rescue-ai-by--1",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "aad04550-f6d2-450b-b5bd-09818b1a39de",
            "serializedConfig": {
              "services": {
                "4b522f35-56a9-48b0-b2f5-d673f0fb2896": {
                  "icon": "https://gist.githubusercontent.com/BitCoinKing/1119297d792ed52e6096f72f4c153627/raw/db0794efdad1d06b9b2781f5ad5b4d8406ed8a15/redis.svg",
                  "name": "Redis",
                  "deploy": {
                    "startCommand": "sh -c 'exec redis-server --appendonly yes --requirepass \"$REDIS_PASSWORD\"'"
                  },
                  "source": {
                    "image": "redis:7-bookworm"
                  },
                  "variables": {
                    "REDIS_URL": {
                      "description": "Private Redis queue connection reference. Keep database and queue services private.",
                      "defaultValue": "redis://default:${{REDIS_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:6379"
                    },
                    "REDIS_PASSWORD": {
                      "description": "Generated private Redis password used by the authenticated start command.",
                      "defaultValue": "{{REDIS_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "4b522f35-56a9-48b0-b2f5-d673f0fb2896": {
                      "mountPath": "/data"
                    }
                  }
                },
                "639279ad-4743-43fc-a0f9-fc781ec58f5c": {
                  "icon": "https://gist.githubusercontent.com/BitCoinKing/1119297d792ed52e6096f72f4c153627/raw/4b7980eba1add0f0179e6455f2596962f48b69b4/postgres.svg",
                  "name": "Postgres",
                  "source": {
                    "image": "postgres:17-bookworm"
                  },
                  "variables": {
                    "PGDATA": {
                      "description": "Postgres 17 data directory beneath the persistent volume.",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "POSTGRES_DB": {
                      "description": "Application database name for this installation.",
                      "defaultValue": "leadrescue"
                    },
                    "DATABASE_URL": {
                      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
                      "defaultValue": "postgresql://${{POSTGRES_USER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{POSTGRES_DB}}"
                    },
                    "POSTGRES_USER": {
                      "description": "Application database username for this installation.",
                      "defaultValue": "leadrescue"
                    },
                    "POSTGRES_PASSWORD": {
                      "description": "Generated private Postgres password. Do not copy a password from another deployment.",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "639279ad-4743-43fc-a0f9-fc781ec58f5c": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "a14d29eb-c7b8-4bfa-b3ce-34fe52232422": {
                  "icon": "https://gist.githubusercontent.com/BitCoinKing/1119297d792ed52e6096f72f4c153627/raw/93d635f16d7f79b36c5326d4b4dfa1c66f2fb9f0/lead-rescue-icon.svg",
                  "name": "lead-rescue-web",
                  "deploy": {
                    "healthcheckPath": "/api/health"
                  },
                  "source": {
                    "image": "ghcr.io/dev101labshq/lead-rescue-web@sha256:48f13757a40c5756c497ad4b0907db4f4a8da9b146f1e5c2e5d2fa1b8dbff005",
                    "hasHiddenRegistryCredentials": true
                  },
                  "variables": {
                    "PORT": {
                      "description": "Web application listen port. Match the HTTP proxy port 8080.",
                      "defaultValue": "8080"
                    },
                    "APP_URL": {
                      "description": "Generated HTTPS application origin. Update if you use a custom domain.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "NODE_ENV": {
                      "description": "Production runtime with HTTPS administrator authentication.",
                      "defaultValue": "production"
                    },
                    "REDIS_URL": {
                      "description": "Private Redis queue connection reference. Keep database and queue services private.",
                      "defaultValue": "${{Redis.REDIS_URL}}"
                    },
                    "GROQ_MODEL": {
                      "description": "Groq structured-output model. Verify availability before enabling AI.",
                      "defaultValue": "openai/gpt-oss-20b"
                    },
                    "ADMIN_EMAIL": {
                      "description": "Your own administrator email. Required for first login and owner email tests.",
                      "defaultValue": "{{ADMIN_EMAIL}}"
                    },
                    "AI_PROVIDER": {
                      "description": "Optional AI provider. Groq is the initial supported beta choice; credentials are supplied separately.",
                      "defaultValue": "groq"
                    },
                    "BETA_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "false"
                    },
                    "DATABASE_URL": {
                      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "GEMINI_MODEL": {
                      "description": "Gemini model for the optional provider; verify availability and quota before use.",
                      "defaultValue": "gemini-3.5-flash-lite"
                    },
                    "GROQ_API_KEY": {
                      "isOptional": true,
                      "description": "Optional buyer-owned Groq key. Leave blank for simulation; web service only.",
                      "defaultValue": ""
                    },
                    "OPENAI_MODEL": {
                      "isOptional": true,
                      "description": "Explicit supported OpenAI Responses API model, required only if using OpenAI.",
                      "defaultValue": ""
                    },
                    "ADMIN_PASSWORD": {
                      "description": "Generated bootstrap password. Change it at /account after first login, then remove this variable.",
                      "defaultValue": "{{ADMIN_PASSWORD}}"
                    },
                    "GEMINI_API_KEY": {
                      "isOptional": true,
                      "description": "Optional buyer-owned Gemini key. Leave blank unless using this provider.",
                      "defaultValue": ""
                    },
                    "OPENAI_API_KEY": {
                      "isOptional": true,
                      "description": "Optional buyer-owned OpenAI API key. Separate API billing applies.",
                      "defaultValue": ""
                    },
                    "SESSION_SECRET": {
                      "description": "Generated private session signing secret. Keep stable; changing it signs out sessions.",
                      "defaultValue": "{{SESSION_SECRET}}"
                    },
                    "AI_LIVE_ENABLED": {
                      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
                      "defaultValue": "false"
                    },
                    "AI_TEST_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "false"
                    },
                    "BETA_AI_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "false"
                    },
                    "BETA_EMAIL_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "false"
                    },
                    "BETA_TESTER_EMAILS": {
                      "description": "Comma-separated approved tester addresses. Defaults to your administrator; no customer recipients.",
                      "defaultValue": "${{ADMIN_EMAIL}}"
                    },
                    "EMAIL_REPLY_SECRET": {
                      "description": "Generated shared secret for signed email reply addresses. Web and worker must use the same value.",
                      "defaultValue": "{{EMAIL_REPLY_SECRET}}"
                    },
                    "ALLOW_LIVE_DELIVERY": {
                      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
                      "defaultValue": "false"
                    },
                    "INBOUND_EMAIL_DOMAIN": {
                      "isOptional": true,
                      "description": "Your receiving subdomain verified in Resend. Separate from existing mailbox DNS.",
                      "defaultValue": ""
                    },
                    "RESEND_WEBHOOK_SECRET": {
                      "isOptional": true,
                      "description": "Signing secret for your Resend webhook at /api/webhooks/resend.",
                      "defaultValue": ""
                    },
                    "EMAIL_BETA_TEST_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "false"
                    },
                    "RESEND_RECEIVING_API_KEY": {
                      "isOptional": true,
                      "description": "Optional receiving key from a dedicated Resend account. Web only; never a shared team key.",
                      "defaultValue": ""
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                },
                "dce9b8ad-b9f8-41eb-875a-143390fb536d": {
                  "icon": "https://gist.githubusercontent.com/BitCoinKing/1119297d792ed52e6096f72f4c153627/raw/93d635f16d7f79b36c5326d4b4dfa1c66f2fb9f0/lead-rescue-icon.svg",
                  "name": "lead-rescue-worker",
                  "source": {
                    "image": "ghcr.io/dev101labshq/lead-rescue-worker@sha256:5421f954ce3ba482aecb001be5aa2cd1b3773cec36a33566e11f861ddeb18d29",
                    "hasHiddenRegistryCredentials": true
                  },
                  "variables": {
                    "REDIS_URL": {
                      "description": "Private Redis queue connection reference. Keep database and queue services private.",
                      "defaultValue": "${{Redis.REDIS_URL}}"
                    },
                    "EMAIL_FROM": {
                      "isOptional": true,
                      "description": "Optional verified sender on your own domain. Configure before owner email tests.",
                      "defaultValue": ""
                    },
                    "ADMIN_EMAIL": {
                      "description": "Your own administrator email. Required for first login and owner email tests.",
                      "defaultValue": "${{lead-rescue-web.ADMIN_EMAIL}}"
                    },
                    "BETA_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "${{lead-rescue-web.BETA_ENABLED}}"
                    },
                    "DATABASE_URL": {
                      "description": "Private Postgres connection reference. Do not substitute a public proxy URL.",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "RESEND_API_KEY": {
                      "isOptional": true,
                      "description": "Optional domain-scoped Resend Sending key. Worker only.",
                      "defaultValue": ""
                    },
                    "BETA_EMAIL_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "${{lead-rescue-web.BETA_EMAIL_ENABLED}}"
                    },
                    "BETA_TESTER_EMAILS": {
                      "description": "Comma-separated approved tester addresses. Defaults to your administrator; no customer recipients.",
                      "defaultValue": "${{lead-rescue-web.BETA_TESTER_EMAILS}}"
                    },
                    "EMAIL_REPLY_SECRET": {
                      "description": "Generated shared secret for signed email reply addresses. Web and worker must use the same value.",
                      "defaultValue": "${{lead-rescue-web.EMAIL_REPLY_SECRET}}"
                    },
                    "ALLOW_LIVE_DELIVERY": {
                      "description": "Keep false for this beta template. General live activation requires a separate production rollout with global budget and sending controls.",
                      "defaultValue": "false"
                    },
                    "INBOUND_EMAIL_DOMAIN": {
                      "isOptional": true,
                      "description": "Your receiving subdomain verified in Resend. Separate from existing mailbox DNS.",
                      "defaultValue": "${{lead-rescue-web.INBOUND_EMAIL_DOMAIN}}"
                    },
                    "EMAIL_BETA_TEST_ENABLED": {
                      "description": "Keep false initially. Enable only the documented controlled test workflow after configuring your own providers.",
                      "defaultValue": "${{lead-rescue-web.EMAIL_BETA_TEST_ENABLED}}"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "lead-rescue-web",
      "method": "GET",
      "path": "/api/health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 4,
    "needs_volume": true
  },
  "generated_at": "2026-11-04T10:15:10.377Z",
  "generator_version": "0.1.0"
}
