{
  "manifest_version": "1.0.0",
  "template": {
    "id": "7b93e654-38ff-4ade-b40e-abe81105e9d5",
    "slug": "deploy-cap-with-ai-transcripts",
    "name": "Cap AI Transcripts",
    "description": "Transcripts, AI titles and summaries on your own Cap",
    "url": "https://railway.com/deploy/deploy-cap-with-ai-transcripts",
    "upstream": {
      "image": "ghcr.io/capsoftware/cap-web@sha256:8ee4cbd3fd87f88f538831aed06c954c525db9c2426a62abeaf0ca307c5e1ce9"
    }
  },
  "status": "unvalidated",
  "validated_at": null,
  "success_rate_30d": null,
  "services": [
    {
      "name": "cap-web",
      "source": {
        "image": "ghcr.io/capsoftware/cap-web@sha256:8ee4cbd3fd87f88f538831aed06c954c525db9c2426a62abeaf0ca307c5e1ce9"
      },
      "needs_volume": true,
      "volume_mount_path": "/app/apps/web/.workflow-data",
      "http": true
    },
    {
      "name": "MySQL",
      "source": {
        "image": "mysql:8.0.46@sha256:7dcddc01f13bab2f15cde676d44d01f61fc9f99fe7785e86196dfc07d358ae2b"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/mysql",
      "http": false
    },
    {
      "name": "media-server",
      "source": {
        "image": "ghcr.io/capsoftware/cap-media-server@sha256:d47944a3744f30e0e0a36b184e24ca99b2723618580ffe97853af2b6a08abde4"
      },
      "needs_volume": false,
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "cap-web",
      "description": "Port Next.js listens on; the public domain routes here.",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "WEB_URL",
      "service": "cap-web",
      "description": "Public HTTPS URL of Cap; also the bucket's allowed CORS origin.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "HOSTNAME",
      "service": "cap-web",
      "description": "Bind address; :: listens on IPv4 and IPv6 for the private network.",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "DATABASE_URL",
      "service": "cap-web",
      "description": "Private MySQL connection URL, referenced from the MySQL service.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "NEXTAUTH_URL",
      "service": "cap-web",
      "description": "Auth callback base URL; must equal WEB_URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "S3_PATH_STYLE",
      "service": "cap-web",
      "description": "false: Railway Buckets use virtual-hosted-style URLs.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "CAP_AWS_BUCKET",
      "service": "cap-web",
      "description": "Real S3 bucket name, referenced from the Railway Bucket.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "CAP_AWS_REGION",
      "service": "cap-web",
      "description": "Bucket region, referenced from the Railway Bucket.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "NEXTAUTH_SECRET",
      "service": "cap-web",
      "description": "Generated session signing secret; changing it logs everyone out.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "RAILWAY_RUN_UID",
      "service": "cap-web",
      "description": "Start as root to hand the volume to the app user, then drop privileges.",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "MEDIA_SERVER_URL",
      "service": "cap-web",
      "description": "Private URL of the FFmpeg media server.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CAP_AWS_ACCESS_KEY",
      "service": "cap-web",
      "description": "Bucket access key, referenced from the Railway Bucket.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "CAP_AWS_SECRET_KEY",
      "service": "cap-web",
      "description": "Bucket secret key, referenced from the Railway Bucket.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "S3_PUBLIC_ENDPOINT",
      "service": "cap-web",
      "description": "S3 endpoint used in presigned upload and playback URLs.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "S3_INTERNAL_ENDPOINT",
      "service": "cap-web",
      "description": "S3 endpoint cap-web uses for its own storage calls.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_ENCRYPTION_KEY",
      "service": "cap-web",
      "description": "Generated 32-byte hex key that encrypts stored credentials; never change it.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "WORKFLOW_LOCAL_DATA_DIR",
      "service": "cap-web",
      "description": "Volume path for durable background-job state (recording processing).",
      "secret": false,
      "strategy": "default",
      "default": "/app/apps/web/.workflow-data"
    },
    {
      "key": "MEDIA_SERVER_WEBHOOK_URL",
      "service": "cap-web",
      "description": "Private URL the media server reports job progress to.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "MEDIA_SERVER_WEBHOOK_SECRET",
      "service": "cap-web",
      "description": "Generated secret shared with media-server to sign job calls.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "MYSQLHOST",
      "service": "MySQL",
      "description": "MySQL private hostname.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "MYSQLPORT",
      "service": "MySQL",
      "description": "MySQL port (3306).",
      "secret": false,
      "strategy": "default",
      "default": "3306"
    },
    {
      "key": "MYSQLUSER",
      "service": "MySQL",
      "description": "Application user, for other services and the Data tab.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MYSQL_URL",
      "service": "MySQL",
      "description": "Full private connection URL that cap-web references.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "MYSQL_USER",
      "service": "MySQL",
      "description": "Application user (cap), created on first boot.",
      "secret": false,
      "strategy": "default",
      "default": "cap"
    },
    {
      "key": "MYSQLDATABASE",
      "service": "MySQL",
      "description": "Database name, for other services and the Data tab.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MYSQLPASSWORD",
      "service": "MySQL",
      "description": "Application user password, for other services and the Data tab.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MYSQL_DATABASE",
      "service": "MySQL",
      "description": "Database Cap uses (cap), created on first boot.",
      "secret": false,
      "strategy": "default",
      "default": "cap"
    },
    {
      "key": "MYSQL_PASSWORD",
      "service": "MySQL",
      "description": "Generated password for the cap user.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "MYSQL_ROOT_PASSWORD",
      "service": "MySQL",
      "description": "Generated MySQL root password.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "PORT",
      "service": "media-server",
      "description": "Media server HTTP port on the private network (3456).",
      "secret": false,
      "strategy": "default",
      "default": "3456"
    },
    {
      "key": "MEDIA_SERVER_WEB_ORIGIN",
      "service": "media-server",
      "description": "Cap's public URL, referenced from cap-web; trusted media origin.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MEDIA_SERVER_WEBHOOK_SECRET",
      "service": "media-server",
      "description": "Shared job secret, referenced from cap-web.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "deploy-cap-with-ai-transcripts"
      }
    },
    "cli": "railway deploy --template deploy-cap-with-ai-transcripts",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "7b93e654-38ff-4ade-b40e-abe81105e9d5",
            "serializedConfig": {
              "buckets": {
                "7ed5d2c0-4b20-4b35-bc7f-1206646dd311": {
                  "name": "Bucket"
                }
              },
              "services": {
                "091cb245-7814-4ad0-b085-d8d44840a82f": {
                  "icon": null,
                  "name": "cap-web",
                  "deploy": {
                    "startCommand": "node -e 'const e=process.env,fs=require(\"fs\"),d=e.WORKFLOW_LOCAL_DATA_DIR||\"/app/apps/web/.workflow-data\";if(process.getuid()===0){fs.mkdirSync(d,{recursive:true});fs.chownSync(d,1001,1001);process.setgroups([1001]);process.setgid(1001);process.setuid(1001);console.log(\"[railway] workflow data in \"+d+\", running as uid \"+process.getuid())}try{const{S3Client:C,PutBucketCorsCommand:P}=require(\"/app/node_modules/.pnpm/node_modules/@aws-sdk/client-s3\");new C({endpoint:e.S3_INTERNAL_ENDPOINT,region:e.CAP_AWS_REGION,forcePathStyle:e.S3_PATH_STYLE===\"true\",credentials:{accessKeyId:e.CAP_AWS_ACCESS_KEY||\"\",secretAccessKey:e.CAP_AWS_SECRET_KEY||\"\"}}).send(new P({Bucket:e.CAP_AWS_BUCKET,CORSConfiguration:{CORSRules:[{AllowedOrigins:[e.WEB_URL],AllowedMethods:[\"GET\",\"HEAD\",\"PUT\",\"POST\"],AllowedHeaders:[\"*\"],ExposeHeaders:[\"ETag\"],MaxAgeSeconds:3600}]}})).then(()=>console.log(\"[railway] bucket CORS set for \"+e.WEB_URL),x=>console.error(\"[railway] bucket CORS not set: \"+x.name+\" \"+x.message))}catch(x){console.error(\"[railway] bucket CORS skipped: \"+x.message)}e.HOSTNAME=\"::\";require(\"/app/apps/web/server.js\")'",
                    "healthcheckPath": "/api/status",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/capsoftware/cap-web@sha256:8ee4cbd3fd87f88f538831aed06c954c525db9c2426a62abeaf0ca307c5e1ce9"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port Next.js listens on; the public domain routes here.",
                      "defaultValue": "3000"
                    },
                    "WEB_URL": {
                      "isOptional": false,
                      "description": "Public HTTPS URL of Cap; also the bucket's allowed CORS origin.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "HOSTNAME": {
                      "isOptional": false,
                      "description": "Bind address; :: listens on IPv4 and IPv6 for the private network.",
                      "defaultValue": "::"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Private MySQL connection URL, referenced from the MySQL service.",
                      "defaultValue": "${{MySQL.MYSQL_URL}}"
                    },
                    "NEXTAUTH_URL": {
                      "isOptional": false,
                      "description": "Auth callback base URL; must equal WEB_URL.",
                      "defaultValue": "${{WEB_URL}}"
                    },
                    "S3_PATH_STYLE": {
                      "isOptional": false,
                      "description": "false: Railway Buckets use virtual-hosted-style URLs.",
                      "defaultValue": "false"
                    },
                    "CAP_AWS_BUCKET": {
                      "isOptional": false,
                      "description": "Real S3 bucket name, referenced from the Railway Bucket.",
                      "defaultValue": "${{Bucket.BUCKET}}"
                    },
                    "CAP_AWS_REGION": {
                      "isOptional": false,
                      "description": "Bucket region, referenced from the Railway Bucket.",
                      "defaultValue": "${{Bucket.REGION}}"
                    },
                    "NEXTAUTH_SECRET": {
                      "isOptional": false,
                      "description": "Generated session signing secret; changing it logs everyone out.",
                      "defaultValue": "{{NEXTAUTH_SECRET}}"
                    },
                    "RAILWAY_RUN_UID": {
                      "isOptional": false,
                      "description": "Start as root to hand the volume to the app user, then drop privileges.",
                      "defaultValue": "0"
                    },
                    "MEDIA_SERVER_URL": {
                      "isOptional": false,
                      "description": "Private URL of the FFmpeg media server.",
                      "defaultValue": "http://${{media-server.RAILWAY_PRIVATE_DOMAIN}}:3456"
                    },
                    "CAP_AWS_ACCESS_KEY": {
                      "isOptional": false,
                      "description": "Bucket access key, referenced from the Railway Bucket.",
                      "defaultValue": "${{Bucket.ACCESS_KEY_ID}}"
                    },
                    "CAP_AWS_SECRET_KEY": {
                      "isOptional": false,
                      "description": "Bucket secret key, referenced from the Railway Bucket.",
                      "defaultValue": "${{Bucket.SECRET_ACCESS_KEY}}"
                    },
                    "S3_PUBLIC_ENDPOINT": {
                      "isOptional": false,
                      "description": "S3 endpoint used in presigned upload and playback URLs.",
                      "defaultValue": "${{Bucket.ENDPOINT}}"
                    },
                    "S3_INTERNAL_ENDPOINT": {
                      "isOptional": false,
                      "description": "S3 endpoint cap-web uses for its own storage calls.",
                      "defaultValue": "${{Bucket.ENDPOINT}}"
                    },
                    "DATABASE_ENCRYPTION_KEY": {
                      "isOptional": false,
                      "description": "Generated 32-byte hex key that encrypts stored credentials; never change it.",
                      "defaultValue": "{{DATABASE_ENCRYPTION_KEY}}"
                    },
                    "WORKFLOW_LOCAL_DATA_DIR": {
                      "isOptional": false,
                      "description": "Volume path for durable background-job state (recording processing).",
                      "defaultValue": "/app/apps/web/.workflow-data"
                    },
                    "MEDIA_SERVER_WEBHOOK_URL": {
                      "isOptional": false,
                      "description": "Private URL the media server reports job progress to.",
                      "defaultValue": "http://${{RAILWAY_PRIVATE_DOMAIN}}:3000"
                    },
                    "MEDIA_SERVER_WEBHOOK_SECRET": {
                      "isOptional": false,
                      "description": "Generated secret shared with media-server to sign job calls.",
                      "defaultValue": "{{MEDIA_SERVER_WEBHOOK_SECRET}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:3000": {
                        "port": 3000
                      }
                    }
                  },
                  "volumeMounts": {
                    "091cb245-7814-4ad0-b085-d8d44840a82f": {
                      "mountPath": "/app/apps/web/.workflow-data"
                    }
                  }
                },
                "71a628ab-6e00-4e31-bb81-693649fa5fcc": {
                  "icon": null,
                  "name": "MySQL",
                  "deploy": {
                    "startCommand": "docker-entrypoint.sh mysqld --max_connections=1000 --default-authentication-plugin=mysql_native_password --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --performance-schema=OFF",
                    "healthcheckPath": null,
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "mysql:8.0.46@sha256:7dcddc01f13bab2f15cde676d44d01f61fc9f99fe7785e86196dfc07d358ae2b"
                  },
                  "variables": {
                    "MYSQLHOST": {
                      "isOptional": false,
                      "description": "MySQL private hostname.",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "MYSQLPORT": {
                      "isOptional": false,
                      "description": "MySQL port (3306).",
                      "defaultValue": "3306"
                    },
                    "MYSQLUSER": {
                      "isOptional": false,
                      "description": "Application user, for other services and the Data tab.",
                      "defaultValue": "${{MYSQL_USER}}"
                    },
                    "MYSQL_URL": {
                      "isOptional": false,
                      "description": "Full private connection URL that cap-web references.",
                      "defaultValue": "mysql://${{MYSQL_USER}}:${{MYSQL_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:3306/${{MYSQL_DATABASE}}"
                    },
                    "MYSQL_USER": {
                      "isOptional": false,
                      "description": "Application user (cap), created on first boot.",
                      "defaultValue": "cap"
                    },
                    "MYSQLDATABASE": {
                      "isOptional": false,
                      "description": "Database name, for other services and the Data tab.",
                      "defaultValue": "${{MYSQL_DATABASE}}"
                    },
                    "MYSQLPASSWORD": {
                      "isOptional": false,
                      "description": "Application user password, for other services and the Data tab.",
                      "defaultValue": "${{MYSQL_PASSWORD}}"
                    },
                    "MYSQL_DATABASE": {
                      "isOptional": false,
                      "description": "Database Cap uses (cap), created on first boot.",
                      "defaultValue": "cap"
                    },
                    "MYSQL_PASSWORD": {
                      "isOptional": false,
                      "description": "Generated password for the cap user.",
                      "defaultValue": "{{MYSQL_PASSWORD}}"
                    },
                    "MYSQL_ROOT_PASSWORD": {
                      "isOptional": false,
                      "description": "Generated MySQL root password.",
                      "defaultValue": "{{MYSQL_ROOT_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "71a628ab-6e00-4e31-bb81-693649fa5fcc": {
                      "mountPath": "/var/lib/mysql"
                    }
                  }
                },
                "d10c0e2f-ddfd-4e35-870e-1e070f7c5f58": {
                  "icon": null,
                  "name": "media-server",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/capsoftware/cap-media-server@sha256:d47944a3744f30e0e0a36b184e24ca99b2723618580ffe97853af2b6a08abde4"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Media server HTTP port on the private network (3456).",
                      "defaultValue": "3456"
                    },
                    "MEDIA_SERVER_WEB_ORIGIN": {
                      "isOptional": false,
                      "description": "Cap's public URL, referenced from cap-web; trusted media origin.",
                      "defaultValue": "${{cap-web.WEB_URL}}"
                    },
                    "MEDIA_SERVER_WEBHOOK_SECRET": {
                      "isOptional": false,
                      "description": "Shared job secret, referenced from cap-web.",
                      "defaultValue": "${{cap-web.MEDIA_SERVER_WEBHOOK_SECRET}}"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "cap-web",
      "method": "GET",
      "path": "/api/status",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 3,
    "needs_volume": true
  },
  "generated_at": "2026-10-21T10:14:45.258Z",
  "generator_version": "0.1.0"
}
