{
  "manifest_version": "1.0.0",
  "template": {
    "id": "889f4f1d-95da-4e9e-8b9a-f7b1e29a049c",
    "slug": "turnstile",
    "name": "Turnstile",
    "description": "A reverse proxy that authenticates users via Railway's OAuth flow.",
    "url": "https://railway.com/deploy/turnstile",
    "upstream": {
      "repo_url": "https://github.com/TinyboxSoftware/turnstile"
    }
  },
  "status": "unvalidated",
  "validated_at": null,
  "success_rate_30d": null,
  "services": [
    {
      "name": "Turnstile",
      "source": {
        "repo": "https://github.com/TinyboxSoftware/turnstile"
      },
      "needs_volume": false,
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "Turnstile",
      "description": "Port to listen on.",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "RAILWAY_CLIENT_ID",
      "service": "Turnstile",
      "description": "OAuth app client ID from Railway Developer Settings.",
      "secret": false,
      "strategy": "ask_user"
    },
    {
      "key": "RAILWAY_PROJECT_ID",
      "service": "Turnstile",
      "description": "The project to gate access to. You must grant the OAuth app access to this project during consent.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "TURNSTILE_PUBLIC_URL",
      "service": "Turnstile",
      "description": "The public URL Turnstile itself is served from. should be set to https://${{RAILWAY_PUBLIC_DOMAIN}}.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "RAILWAY_CLIENT_SECRET",
      "service": "Turnstile",
      "description": "OAuth app client secret, generated alongside the client ID.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "TURNSTILE_BACKEND_URL",
      "service": "Turnstile",
      "description": "Internal URL of the service to proxy to including port and protocol",
      "secret": false,
      "strategy": "ask_user"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "turnstile"
      }
    },
    "cli": "railway deploy --template turnstile",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "889f4f1d-95da-4e9e-8b9a-f7b1e29a049c",
            "serializedConfig": {
              "services": {
                "49bc0f29-8a20-48ea-9e78-6860030115c0": {
                  "icon": "https://em-content.zobj.net/source/google/439/locked_1f512.png",
                  "name": "Turnstile",
                  "deploy": {
                    "healthcheckPath": "/_turnstile/health"
                  },
                  "source": {
                    "repo": "TinyboxSoftware/turnstile",
                    "branch": null,
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port to listen on.",
                      "defaultValue": "8080"
                    },
                    "RAILWAY_CLIENT_ID": {
                      "isOptional": false,
                      "description": "OAuth app client ID from Railway Developer Settings.",
                      "defaultValue": "{{RAILWAY_CLIENT_ID}}"
                    },
                    "RAILWAY_PROJECT_ID": {
                      "isOptional": false,
                      "description": "The project to gate access to. You must grant the OAuth app access to this project during consent.",
                      "defaultValue": "${{RAILWAY_PROJECT_ID}}"
                    },
                    "TURNSTILE_PUBLIC_URL": {
                      "isOptional": false,
                      "description": "The public URL Turnstile itself is served from. should be set to https://${{RAILWAY_PUBLIC_DOMAIN}}.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "RAILWAY_CLIENT_SECRET": {
                      "isOptional": false,
                      "description": "OAuth app client secret, generated alongside the client ID.",
                      "defaultValue": "{{RAILWAY_CLIENT_SECRET}}"
                    },
                    "TURNSTILE_BACKEND_URL": {
                      "isOptional": false,
                      "description": "Internal URL of the service to proxy to including port and protocol",
                      "defaultValue": "{{TURNSTILE_BACKEND_URL}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "Turnstile",
      "method": "GET",
      "path": "/_turnstile/health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 1,
    "needs_volume": false
  },
  "generated_at": "2026-09-04T05:44:27.711Z",
  "generator_version": "0.1.0"
}
