{
  "manifest_version": "1.0.0",
  "template": {
    "id": "69bf46cb-d444-46c8-86a1-4722c39a285e",
    "slug": "millionsend",
    "name": "MillionSend",
    "description": "Open source email API and broadcasts on your own AWS SES, Resend compatible",
    "url": "https://railway.com/deploy/millionsend",
    "upstream": {
      "image": "ghcr.io/millionsend/millionsend:latest"
    }
  },
  "services": [
    {
      "name": "Postgres",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:17"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "tcp_ports": [
        5432
      ],
      "http": false
    },
    {
      "name": "MillionSend Worker",
      "source": {
        "image": "ghcr.io/millionsend/millionsend:latest"
      },
      "needs_volume": false,
      "http": false
    },
    {
      "name": "MillionSend",
      "source": {
        "image": "ghcr.io/millionsend/millionsend:latest"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "MillionSend API",
      "source": {
        "image": "ghcr.io/millionsend/millionsend:latest"
      },
      "needs_volume": false,
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "PGDATA",
      "service": "Postgres",
      "description": "Location where the database will be initialized",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "PGHOST",
      "service": "Postgres",
      "description": "Railway private domain name",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "Postgres",
      "description": "Port to connect to Postgres",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "PGUSER",
      "service": "Postgres",
      "description": "Required variable for the Data panel",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "Postgres",
      "description": "Required variable for the Data panel",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "Postgres",
      "description": "Required variable for the Data panel",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres",
      "description": "Default database created when the image starts",
      "secret": false,
      "strategy": "default",
      "default": "railway"
    },
    {
      "key": "DATABASE_URL",
      "service": "Postgres",
      "description": "URL to connect to Postgres over the private network",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres",
      "description": "User to connect to Postgres",
      "secret": false,
      "strategy": "default",
      "default": "postgres"
    },
    {
      "key": "SSL_CERT_DAYS",
      "service": "Postgres",
      "description": "SSL certificate expiry in days",
      "secret": false,
      "strategy": "default",
      "default": "820"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres",
      "description": "Password to connect to Postgres",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "DATABASE_PUBLIC_URL",
      "service": "Postgres",
      "description": "Public URL to connect to Postgres, used by the Data panel",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "Postgres",
      "description": "Allow Postgres to cleanly shut down",
      "secret": false,
      "strategy": "default",
      "default": "60"
    },
    {
      "key": "PROCESS",
      "service": "MillionSend Worker",
      "description": "Which MillionSend process this container runs: the worker (sending, broadcasts, SES events, scheduled jobs)",
      "secret": false,
      "strategy": "default",
      "default": "worker"
    },
    {
      "key": "AWS_REGION",
      "service": "MillionSend Worker",
      "description": "Same as AWS_REGION on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "ALLOW_SIGNUP",
      "service": "MillionSend Worker",
      "description": "Same as ALLOW_SIGNUP on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "APP_BASE_URL",
      "service": "MillionSend Worker",
      "description": "Same as APP_BASE_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "MillionSend Worker",
      "description": "PostgreSQL connection string, over the private network",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SQS_QUEUE_URL",
      "service": "MillionSend Worker",
      "description": "Same as SQS_QUEUE_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PUBLIC_API_URL",
      "service": "MillionSend Worker",
      "description": "Same as PUBLIC_API_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SNS_TOPIC_ARNS",
      "service": "MillionSend Worker",
      "description": "Same as SNS_TOPIC_ARNS on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AUTH_EMAIL_FROM",
      "service": "MillionSend Worker",
      "description": "Same as AUTH_EMAIL_FROM on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AWS_ACCESS_KEY_ID",
      "service": "MillionSend Worker",
      "description": "Same as AWS_ACCESS_KEY_ID on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "BETTER_AUTH_SECRET",
      "service": "MillionSend Worker",
      "description": "Same as BETTER_AUTH_SECRET on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AWS_SECRET_ACCESS_KEY",
      "service": "MillionSend Worker",
      "description": "Same as AWS_SECRET_ACCESS_KEY on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MASTER_ENCRYPTION_KEY",
      "service": "MillionSend Worker",
      "description": "Same as MASTER_ENCRYPTION_KEY on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SES_CONFIGURATION_SET",
      "service": "MillionSend Worker",
      "description": "Same as SES_CONFIGURATION_SET on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "MillionSend Worker",
      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
      "secret": false,
      "strategy": "default",
      "default": "45"
    },
    {
      "key": "PORT",
      "service": "MillionSend",
      "description": "Port the dashboard listens on; Railway's health check and domain use it",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "PROCESS",
      "service": "MillionSend",
      "description": "Which MillionSend process this container runs: the dashboard",
      "secret": false,
      "strategy": "default",
      "default": "web"
    },
    {
      "key": "AWS_REGION",
      "service": "MillionSend",
      "description": "AWS region of your SES account (also used for SQS)",
      "secret": false,
      "strategy": "default",
      "default": "us-east-1"
    },
    {
      "key": "ALLOW_SIGNUP",
      "service": "MillionSend",
      "description": "The first account can always sign up and becomes the operator. Keep false so nobody else can create accounts that send through your SES",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "APP_BASE_URL",
      "service": "MillionSend",
      "description": "Public origin of the dashboard. Sign-in is only accepted from this exact origin; update it if you add a custom domain",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "DATABASE_URL",
      "service": "MillionSend",
      "description": "PostgreSQL connection string, over the private network",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PUBLIC_API_URL",
      "service": "MillionSend",
      "description": "Public origin of the API, shown in the dashboard as the SDK base URL",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "BETTER_AUTH_SECRET",
      "service": "MillionSend",
      "description": "Signs dashboard sessions. Generated at deploy time",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "MASTER_ENCRYPTION_KEY",
      "service": "MillionSend",
      "description": "Encrypts email bodies at rest (32 bytes, base64). Generated once; back it up with the database and never change it, or stored bodies become unreadable",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "MillionSend",
      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
      "secret": false,
      "strategy": "default",
      "default": "45"
    },
    {
      "key": "PORT",
      "service": "MillionSend API",
      "description": "Port the API listens on; Railway's health check and domain use it",
      "secret": false,
      "strategy": "default",
      "default": "3001"
    },
    {
      "key": "PROCESS",
      "service": "MillionSend API",
      "description": "Which MillionSend process this container runs: the REST API",
      "secret": false,
      "strategy": "default",
      "default": "api"
    },
    {
      "key": "AWS_REGION",
      "service": "MillionSend API",
      "description": "Same as AWS_REGION on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "ALLOW_SIGNUP",
      "service": "MillionSend API",
      "description": "Same as ALLOW_SIGNUP on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "APP_BASE_URL",
      "service": "MillionSend API",
      "description": "Same as APP_BASE_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "MillionSend API",
      "description": "PostgreSQL connection string, over the private network",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SQS_QUEUE_URL",
      "service": "MillionSend API",
      "description": "Same as SQS_QUEUE_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PUBLIC_API_URL",
      "service": "MillionSend API",
      "description": "Same as PUBLIC_API_URL on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SNS_TOPIC_ARNS",
      "service": "MillionSend API",
      "description": "Same as SNS_TOPIC_ARNS on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AUTH_EMAIL_FROM",
      "service": "MillionSend API",
      "description": "Same as AUTH_EMAIL_FROM on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AWS_ACCESS_KEY_ID",
      "service": "MillionSend API",
      "description": "Same as AWS_ACCESS_KEY_ID on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "BETTER_AUTH_SECRET",
      "service": "MillionSend API",
      "description": "Same as BETTER_AUTH_SECRET on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "AWS_SECRET_ACCESS_KEY",
      "service": "MillionSend API",
      "description": "Same as AWS_SECRET_ACCESS_KEY on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MASTER_ENCRYPTION_KEY",
      "service": "MillionSend API",
      "description": "Same as MASTER_ENCRYPTION_KEY on the MillionSend service",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SES_CONFIGURATION_SET",
      "service": "MillionSend API",
      "description": "Same as SES_CONFIGURATION_SET on the MillionSend service",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "MillionSend API",
      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
      "secret": false,
      "strategy": "default",
      "default": "45"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "millionsend"
      }
    },
    "cli": "railway deploy --template millionsend",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "69bf46cb-d444-46c8-86a1-4722c39a285e",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "09cef1fc-a842-4804-bd8b-41ae1dadc495": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "Postgres",
                  "deploy": {
                    "startCommand": "wrapper.sh postgres --port=5432 -c max_connections=200 -c max_parallel_workers_per_gather=0",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:17"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Location where the database will be initialized",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "Railway private domain name",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "Port to connect to Postgres",
                      "defaultValue": "5432"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "Required variable for the Data panel",
                      "defaultValue": "${{POSTGRES_USER}}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "Required variable for the Data panel",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "Required variable for the Data panel",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Default database created when the image starts",
                      "defaultValue": "railway"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "URL to connect to Postgres over the private network",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{PGDATABASE}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "User to connect to Postgres",
                      "defaultValue": "postgres"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": true,
                      "description": "SSL certificate expiry in days",
                      "defaultValue": "820"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Password to connect to Postgres",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "DATABASE_PUBLIC_URL": {
                      "isOptional": false,
                      "description": "Public URL to connect to Postgres, used by the Data panel",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_TCP_PROXY_DOMAIN}}:${{RAILWAY_TCP_PROXY_PORT}}/${{PGDATABASE}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Allow Postgres to cleanly shut down",
                      "defaultValue": "60"
                    }
                  },
                  "networking": {
                    "tcpProxies": {
                      "5432": {}
                    }
                  },
                  "volumeMounts": {
                    "09cef1fc-a842-4804-bd8b-41ae1dadc495": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "3243dda4-d43d-4d7c-aaca-25188f5ca129": {
                  "icon": "https://cdn.jsdelivr.net/gh/ThallesP/railway-templates@main/assets/millionsend-icon.svg",
                  "name": "MillionSend Worker",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/millionsend/millionsend:latest"
                  },
                  "variables": {
                    "PROCESS": {
                      "isOptional": false,
                      "description": "Which MillionSend process this container runs: the worker (sending, broadcasts, SES events, scheduled jobs)",
                      "defaultValue": "worker"
                    },
                    "AWS_REGION": {
                      "isOptional": false,
                      "description": "Same as AWS_REGION on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_REGION}}"
                    },
                    "ALLOW_SIGNUP": {
                      "isOptional": false,
                      "description": "Same as ALLOW_SIGNUP on the MillionSend service",
                      "defaultValue": "${{MillionSend.ALLOW_SIGNUP}}"
                    },
                    "APP_BASE_URL": {
                      "isOptional": false,
                      "description": "Same as APP_BASE_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.APP_BASE_URL}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection string, over the private network",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "SQS_QUEUE_URL": {
                      "isOptional": false,
                      "description": "Same as SQS_QUEUE_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.SQS_QUEUE_URL}}"
                    },
                    "PUBLIC_API_URL": {
                      "isOptional": false,
                      "description": "Same as PUBLIC_API_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.PUBLIC_API_URL}}"
                    },
                    "SNS_TOPIC_ARNS": {
                      "isOptional": false,
                      "description": "Same as SNS_TOPIC_ARNS on the MillionSend service",
                      "defaultValue": "${{MillionSend.SNS_TOPIC_ARNS}}"
                    },
                    "AUTH_EMAIL_FROM": {
                      "isOptional": false,
                      "description": "Same as AUTH_EMAIL_FROM on the MillionSend service",
                      "defaultValue": "${{MillionSend.AUTH_EMAIL_FROM}}"
                    },
                    "AWS_ACCESS_KEY_ID": {
                      "isOptional": false,
                      "description": "Same as AWS_ACCESS_KEY_ID on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_ACCESS_KEY_ID}}"
                    },
                    "BETTER_AUTH_SECRET": {
                      "isOptional": false,
                      "description": "Same as BETTER_AUTH_SECRET on the MillionSend service",
                      "defaultValue": "${{MillionSend.BETTER_AUTH_SECRET}}"
                    },
                    "AWS_SECRET_ACCESS_KEY": {
                      "isOptional": false,
                      "description": "Same as AWS_SECRET_ACCESS_KEY on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_SECRET_ACCESS_KEY}}"
                    },
                    "MASTER_ENCRYPTION_KEY": {
                      "isOptional": false,
                      "description": "Same as MASTER_ENCRYPTION_KEY on the MillionSend service",
                      "defaultValue": "${{MillionSend.MASTER_ENCRYPTION_KEY}}"
                    },
                    "SES_CONFIGURATION_SET": {
                      "isOptional": false,
                      "description": "Same as SES_CONFIGURATION_SET on the MillionSend service",
                      "defaultValue": "${{MillionSend.SES_CONFIGURATION_SET}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
                      "defaultValue": "45"
                    }
                  }
                },
                "ba4f64bf-12c0-402e-87f4-1daf7bbe2ce4": {
                  "icon": "https://cdn.jsdelivr.net/gh/ThallesP/railway-templates@main/assets/millionsend-icon.svg",
                  "name": "MillionSend",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/login",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/millionsend/millionsend:latest"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port the dashboard listens on; Railway's health check and domain use it",
                      "defaultValue": "3000"
                    },
                    "PROCESS": {
                      "isOptional": false,
                      "description": "Which MillionSend process this container runs: the dashboard",
                      "defaultValue": "web"
                    },
                    "AWS_REGION": {
                      "isOptional": false,
                      "description": "AWS region of your SES account (also used for SQS)",
                      "defaultValue": "us-east-1"
                    },
                    "ALLOW_SIGNUP": {
                      "isOptional": false,
                      "description": "The first account can always sign up and becomes the operator. Keep false so nobody else can create accounts that send through your SES",
                      "defaultValue": "false"
                    },
                    "APP_BASE_URL": {
                      "isOptional": false,
                      "description": "Public origin of the dashboard. Sign-in is only accepted from this exact origin; update it if you add a custom domain",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection string, over the private network",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "SQS_QUEUE_URL": {
                      "isOptional": true,
                      "description": "SQS queue the worker polls for bounces, complaints and deliveries, from `npx @millionsend/setup`",
                      "defaultValue": ""
                    },
                    "PUBLIC_API_URL": {
                      "isOptional": false,
                      "description": "Public origin of the API, shown in the dashboard as the SDK base URL",
                      "defaultValue": "https://${{MillionSend API.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "SNS_TOPIC_ARNS": {
                      "isOptional": true,
                      "description": "SNS topic ARN(s) allowed to deliver SES events, comma-separated, from `npx @millionsend/setup`",
                      "defaultValue": ""
                    },
                    "AUTH_EMAIL_FROM": {
                      "isOptional": true,
                      "description": "Sender for password reset and email verification, e.g. MillionSend <no-reply@example.com>, on a domain verified in SES. Empty: both features are off",
                      "defaultValue": ""
                    },
                    "AWS_ACCESS_KEY_ID": {
                      "isOptional": true,
                      "description": "IAM access key with SES send rights. Get it from `npx @millionsend/setup`; sending is off until it is set",
                      "defaultValue": ""
                    },
                    "BETTER_AUTH_SECRET": {
                      "isOptional": false,
                      "description": "Signs dashboard sessions. Generated at deploy time",
                      "defaultValue": "{{BETTER_AUTH_SECRET}}"
                    },
                    "AWS_SECRET_ACCESS_KEY": {
                      "isOptional": true,
                      "description": "Secret for AWS_ACCESS_KEY_ID, from `npx @millionsend/setup`",
                      "defaultValue": ""
                    },
                    "MASTER_ENCRYPTION_KEY": {
                      "isOptional": false,
                      "description": "Encrypts email bodies at rest (32 bytes, base64). Generated once; back it up with the database and never change it, or stored bodies become unreadable",
                      "defaultValue": "{{MASTER_ENCRYPTION_KEY}}"
                    },
                    "SES_CONFIGURATION_SET": {
                      "isOptional": true,
                      "description": "SES configuration set that publishes delivery events, from `npx @millionsend/setup`",
                      "defaultValue": ""
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
                      "defaultValue": "45"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:3000": {
                        "port": 3000
                      }
                    }
                  }
                },
                "c900451e-5be2-41bc-8af9-99d499f78c16": {
                  "icon": "https://cdn.jsdelivr.net/gh/ThallesP/railway-templates@main/assets/millionsend-icon.svg",
                  "name": "MillionSend API",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/millionsend/millionsend:latest"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port the API listens on; Railway's health check and domain use it",
                      "defaultValue": "3001"
                    },
                    "PROCESS": {
                      "isOptional": false,
                      "description": "Which MillionSend process this container runs: the REST API",
                      "defaultValue": "api"
                    },
                    "AWS_REGION": {
                      "isOptional": false,
                      "description": "Same as AWS_REGION on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_REGION}}"
                    },
                    "ALLOW_SIGNUP": {
                      "isOptional": false,
                      "description": "Same as ALLOW_SIGNUP on the MillionSend service",
                      "defaultValue": "${{MillionSend.ALLOW_SIGNUP}}"
                    },
                    "APP_BASE_URL": {
                      "isOptional": false,
                      "description": "Same as APP_BASE_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.APP_BASE_URL}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection string, over the private network",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "SQS_QUEUE_URL": {
                      "isOptional": false,
                      "description": "Same as SQS_QUEUE_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.SQS_QUEUE_URL}}"
                    },
                    "PUBLIC_API_URL": {
                      "isOptional": false,
                      "description": "Same as PUBLIC_API_URL on the MillionSend service",
                      "defaultValue": "${{MillionSend.PUBLIC_API_URL}}"
                    },
                    "SNS_TOPIC_ARNS": {
                      "isOptional": false,
                      "description": "Same as SNS_TOPIC_ARNS on the MillionSend service",
                      "defaultValue": "${{MillionSend.SNS_TOPIC_ARNS}}"
                    },
                    "AUTH_EMAIL_FROM": {
                      "isOptional": false,
                      "description": "Same as AUTH_EMAIL_FROM on the MillionSend service",
                      "defaultValue": "${{MillionSend.AUTH_EMAIL_FROM}}"
                    },
                    "AWS_ACCESS_KEY_ID": {
                      "isOptional": false,
                      "description": "Same as AWS_ACCESS_KEY_ID on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_ACCESS_KEY_ID}}"
                    },
                    "BETTER_AUTH_SECRET": {
                      "isOptional": false,
                      "description": "Same as BETTER_AUTH_SECRET on the MillionSend service",
                      "defaultValue": "${{MillionSend.BETTER_AUTH_SECRET}}"
                    },
                    "AWS_SECRET_ACCESS_KEY": {
                      "isOptional": false,
                      "description": "Same as AWS_SECRET_ACCESS_KEY on the MillionSend service",
                      "defaultValue": "${{MillionSend.AWS_SECRET_ACCESS_KEY}}"
                    },
                    "MASTER_ENCRYPTION_KEY": {
                      "isOptional": false,
                      "description": "Same as MASTER_ENCRYPTION_KEY on the MillionSend service",
                      "defaultValue": "${{MillionSend.MASTER_ENCRYPTION_KEY}}"
                    },
                    "SES_CONFIGURATION_SET": {
                      "isOptional": false,
                      "description": "Same as SES_CONFIGURATION_SET on the MillionSend service",
                      "defaultValue": "${{MillionSend.SES_CONFIGURATION_SET}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Seconds to finish in-flight work before shutdown; the worker drains sends for up to 30 s",
                      "defaultValue": "45"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:3001": {
                        "port": 3001
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "MillionSend",
      "method": "GET",
      "path": "/login",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 4,
    "needs_volume": true
  },
  "generated_at": "2026-10-07T04:14:35.316Z",
  "generator_version": "0.1.0",
  "status": "degraded",
  "validated_at": "2026-10-07T02:48:15.875Z",
  "success_rate_30d": 0,
  "validation": {
    "last_run_id": "run_f84774a19b5248d995fb",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": false,
        "detail": "SUCCESS,DEPLOYING,FAILED,DEPLOYING"
      }
    ]
  }
}
