{
  "manifest_version": "1.0.0",
  "template": {
    "id": "92ec75f4-084b-403d-8010-80dc44dec88c",
    "slug": "ai-customer-service-agent",
    "name": "Ai-Customer-Service-Agent",
    "description": "Ai customer support with intelligent escalation and real time analytics",
    "url": "https://railway.com/deploy/ai-customer-service-agent",
    "upstream": {
      "repo_url": "https://github.com/Jeah84/ai-customer-service-agent"
    }
  },
  "status": "unvalidated",
  "validated_at": null,
  "success_rate_30d": null,
  "services": [
    {
      "name": "Postgres",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "ai-customer-service-agent",
      "source": {
        "repo": "https://github.com/Jeah84/ai-customer-service-agent"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "Redis",
      "source": {
        "image": "redis:8.2.1"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PGDATA",
      "service": "Postgres",
      "description": "Internal PostgreSQL data directory path (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "PGHOST",
      "service": "Postgres",
      "description": "PostgreSQL username (mirrors POSTGRES_USER)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "Postgres",
      "description": "PostgreSQL server port (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "PGUSER",
      "service": "Postgres",
      "description": "PostgreSQL database name (mirrors POSTGRES_DB)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "Postgres",
      "description": "PostgreSQL password (mirrors POSTGRES_PASSWORD)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "Postgres",
      "description": "PostgreSQL connection URL (private network)",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres",
      "description": "PostgreSQL database name (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "DATABASE_URL",
      "service": "Postgres",
      "description": "PostgreSQL database password (auto-generated)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres",
      "description": "PostgreSQL username (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "SSL_CERT_DAYS",
      "service": "Postgres",
      "description": "PostgreSQL SSL certificate validity period in days (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres",
      "description": "PostgreSQL connection URL (public network)",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "DATABASE_PUBLIC_URL",
      "service": "Postgres",
      "description": "PostgreSQL connection URL (public network)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "Postgres",
      "description": "Graceful shutdown timeout in seconds (auto-configured by Railway)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "PORT",
      "service": "ai-customer-service-agent",
      "description": "Redis connection URL (auto-set from Redis)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "REDIS_URL",
      "service": "ai-customer-service-agent",
      "description": "PostgreSQL connection URL (auto-set from Postgres)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "ai-customer-service-agent",
      "description": "Your Anthropic API key for Claude AI",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "ANTHROPIC_API_KEY",
      "service": "ai-customer-service-agent",
      "description": "Your Anthropic API key for Claude AI",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "REDISHOST",
      "service": "Redis",
      "description": "Redis port number",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "REDISPORT",
      "service": "Redis",
      "description": "Redis username",
      "secret": false,
      "strategy": "default",
      "default": "default"
    },
    {
      "key": "REDISUSER",
      "service": "Redis",
      "description": "Full Redis connection URL (private network)",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "REDIS_URL",
      "service": "Redis",
      "description": "Redis password (auto-generated)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDISPASSWORD",
      "service": "Redis",
      "description": "Redis password (alias for REDISPASSWORD)",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDIS_PASSWORD",
      "service": "Redis",
      "description": "Full Redis connection URL (public network)",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "REDIS_PUBLIC_URL",
      "service": "Redis",
      "description": "Full Redis connection URL (public network)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "ai-customer-service-agent"
      }
    },
    "cli": "railway deploy --template ai-customer-service-agent",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "92ec75f4-084b-403d-8010-80dc44dec88c",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "b67e5158-f548-4ff6-bbae-734eafbade89": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "Postgres",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Internal PostgreSQL data directory path (auto-configured by Railway)",
                      "defaultValue": "{{PGDATA}}"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "PostgreSQL username (mirrors POSTGRES_USER)",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "PostgreSQL server port (auto-configured by Railway)",
                      "defaultValue": "{{PGPORT}}"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "PostgreSQL database name (mirrors POSTGRES_DB)",
                      "defaultValue": "${{POSTGRES_USER}}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "PostgreSQL password (mirrors POSTGRES_PASSWORD)",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "PostgreSQL connection URL (private network)",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "PostgreSQL database name (auto-configured by Railway)",
                      "defaultValue": "{{POSTGRES_DB}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL database password (auto-generated)",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{PGDATABASE}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "PostgreSQL username (auto-configured by Railway)",
                      "defaultValue": "{{POSTGRES_USER}}"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": false,
                      "description": "PostgreSQL SSL certificate validity period in days (auto-configured by Railway)",
                      "defaultValue": "{{SSL_CERT_DAYS}}"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "PostgreSQL connection URL (public network)",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "DATABASE_PUBLIC_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection URL (public network)",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_TCP_PROXY_DOMAIN}}:${{RAILWAY_TCP_PROXY_PORT}}/${{PGDATABASE}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Graceful shutdown timeout in seconds (auto-configured by Railway)",
                      "defaultValue": "{{RAILWAY_DEPLOYMENT_DRAINING_SECONDS}}"
                    }
                  },
                  "volumeMounts": {
                    "b67e5158-f548-4ff6-bbae-734eafbade89": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  },
                  "haTemplateCode": "postgres-ha",
                  "haConversionConfig": {
                    "edge": {
                      "label": "Reverse Proxy",
                      "options": [
                        2,
                        3,
                        4,
                        5
                      ],
                      "nodeLabel": "HAProxy",
                      "description": "Routes traffic to the primary",
                      "defaultValue": 3
                    },
                    "replica": {
                      "label": "Replicas",
                      "options": [
                        2,
                        3,
                        4,
                        5,
                        6,
                        7
                      ],
                      "nodeLabel": "Postgres",
                      "description": "Streaming replicas for automatic failover",
                      "defaultValue": 2
                    },
                    "internal": {
                      "label": "Coordinator Nodes",
                      "options": [
                        3,
                        5,
                        7,
                        9
                      ],
                      "nodeLabel": "etcd",
                      "defaultValue": 3
                    },
                    "description": "This will convert your Postgres database to an HA cluster with Patroni failover and etcd consensus."
                  }
                },
                "be6a553f-2aab-44c0-a5df-1a94ee1f8fbb": {
                  "icon": "https://devicons.railway.app/i/fastapi.svg",
                  "name": "ai-customer-service-agent",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/Jeah84/ai-customer-service-agent",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Redis connection URL (auto-set from Redis)",
                      "defaultValue": "{{PORT}}"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection URL (auto-set from Postgres)",
                      "defaultValue": "${{Redis.REDIS_URL}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Your Anthropic API key for Claude AI",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "ANTHROPIC_API_KEY": {
                      "isOptional": false,
                      "description": "Your Anthropic API key for Claude AI",
                      "defaultValue": "{{ANTHROPIC_API_KEY}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>": {}
                    }
                  }
                },
                "c3fc0871-eca1-4811-bff4-978b73ec8323": {
                  "icon": "https://cdn.sanity.io/images/sy1jschh/production/0ce0bfdcfbdbf69662b1116671f97c2dd788b655-157x157.svg",
                  "name": "Redis",
                  "deploy": {
                    "startCommand": "/bin/sh -c \"rm -rf $RAILWAY_VOLUME_MOUNT_PATH/lost+found/ && exec docker-entrypoint.sh redis-server --requirepass $REDIS_PASSWORD --save 60 1 --dir $RAILWAY_VOLUME_MOUNT_PATH\"",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "redis:8.2.1"
                  },
                  "variables": {
                    "REDISHOST": {
                      "isOptional": false,
                      "description": "Redis port number",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "REDISPORT": {
                      "isOptional": false,
                      "description": "Redis username",
                      "defaultValue": "default"
                    },
                    "REDISUSER": {
                      "isOptional": false,
                      "description": "Full Redis connection URL (private network)",
                      "defaultValue": "{{REDISUSER}}"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Redis password (auto-generated)",
                      "defaultValue": "redis://${{REDISUSER}}:${{REDIS_PASSWORD}}@${{REDISHOST}}:${{REDISPORT}}"
                    },
                    "REDISPASSWORD": {
                      "isOptional": false,
                      "description": "Redis password (alias for REDISPASSWORD)",
                      "defaultValue": "${{REDIS_PASSWORD}}"
                    },
                    "REDIS_PASSWORD": {
                      "isOptional": false,
                      "description": "Full Redis connection URL (public network)",
                      "defaultValue": "{{REDIS_PASSWORD}}"
                    },
                    "REDIS_PUBLIC_URL": {
                      "isOptional": false,
                      "description": "Full Redis connection URL (public network)",
                      "defaultValue": "redis://default:${{REDIS_PASSWORD}}@${{RAILWAY_TCP_PROXY_DOMAIN}}:${{RAILWAY_TCP_PROXY_PORT}}"
                    }
                  },
                  "volumeMounts": {
                    "c3fc0871-eca1-4811-bff4-978b73ec8323": {
                      "mountPath": "/data"
                    }
                  },
                  "haTemplateCode": "redis-ha",
                  "haConversionConfig": {
                    "edge": {
                      "label": "Reverse Proxies",
                      "options": [
                        1,
                        2
                      ],
                      "nodeLabel": "HAProxy",
                      "description": "HAProxy instances routing writes to the primary",
                      "defaultValue": 2
                    },
                    "replica": {
                      "label": "Redis Replicas",
                      "options": [
                        2,
                        3,
                        4,
                        5
                      ],
                      "nodeLabel": "Redis",
                      "description": "Nodes running Redis + colocated Sentinel",
                      "defaultValue": 2
                    },
                    "internal": null,
                    "description": "This will convert your Redis instance to an HA cluster with Sentinel failover and HAProxy routing to the primary."
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "ai-customer-service-agent",
      "method": "GET",
      "path": "/health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 3,
    "needs_volume": true
  },
  "generated_at": "2026-09-10T16:14:52.212Z",
  "generator_version": "0.1.0"
}
