{
  "manifest_version": "1.0.0",
  "template": {
    "id": "de63fe85-66e2-4616-8a5f-07fd3712f4c1",
    "slug": "mosquitto-broker-jwt-auth",
    "name": "Mosquitto Broker - JWT Auth",
    "description": "MQTT message broker with JWT authentication and authorization",
    "url": "https://railway.com/deploy/mosquitto-broker-jwt-auth",
    "upstream": {
      "repo_url": "https://github.com/Lima-e-Silva/mosquitto-jwt"
    }
  },
  "services": [
    {
      "name": "MQTT Broker with JWT",
      "source": {
        "repo": "https://github.com/Lima-e-Silva/mosquitto-jwt"
      },
      "needs_volume": false,
      "tcp_ports": [
        1883
      ],
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "JWT_SECRET",
      "service": "MQTT Broker with JWT",
      "description": "Secret key for JWT authentication",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "MAX_CONNECTIONS",
      "service": "MQTT Broker with JWT",
      "description": "The maximum number of client connections allowed",
      "secret": false,
      "strategy": "default",
      "default": "65536"
    },
    {
      "key": "MOSQUITTO_WS_HOST",
      "service": "MQTT Broker with JWT",
      "description": "The host for websockets connections",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "MOSQUITTO_WS_PORT",
      "service": "MQTT Broker with JWT",
      "description": "The external port for websocket connections",
      "secret": false,
      "strategy": "default",
      "default": "443"
    },
    {
      "key": "MOSQUITTO_TCP_HOST",
      "service": "MQTT Broker with JWT",
      "description": "The host for TCP connections",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MOSQUITTO_TCP_PORT",
      "service": "MQTT Broker with JWT",
      "description": "The external port for the TCP Proxy",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MAX_QUEUED_MESSAGES",
      "service": "MQTT Broker with JWT",
      "description": "The maximum number of QoS 1 or 2 messages to hold in the queue (per client) above those messages that are currently in flight",
      "secret": false,
      "strategy": "default",
      "default": "1024"
    },
    {
      "key": "MAX_INFLIGHT_MESSAGES",
      "service": "MQTT Broker with JWT",
      "description": "The maximum number of outgoing QoS 1 or 2 messages that can be in the process of being transmitted simultaneously",
      "secret": false,
      "strategy": "default",
      "default": "20"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "mosquitto-broker-jwt-auth"
      }
    },
    "cli": "railway deploy --template mosquitto-broker-jwt-auth",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "de63fe85-66e2-4616-8a5f-07fd3712f4c1",
            "serializedConfig": {
              "services": {
                "61b480cb-3f31-4396-a886-70d31c3d86e4": {
                  "icon": "https://github.com/Lima-e-Silva/mosquitto-jwt/blob/a144d184637be552fa8a73c566d88642954e2590/static/icon.png?raw=true",
                  "name": "MQTT Broker with JWT",
                  "source": {
                    "repo": "Lima-e-Silva/mosquitto-jwt",
                    "branch": null,
                    "rootDirectory": null
                  },
                  "variables": {
                    "JWT_SECRET": {
                      "isOptional": true,
                      "description": "Secret key for JWT authentication",
                      "defaultValue": "{{JWT_SECRET}}"
                    },
                    "MAX_CONNECTIONS": {
                      "isOptional": true,
                      "description": "The maximum number of client connections allowed",
                      "defaultValue": "65536"
                    },
                    "MOSQUITTO_WS_HOST": {
                      "description": "The host for websockets connections",
                      "defaultValue": "${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "MOSQUITTO_WS_PORT": {
                      "description": "The external port for websocket connections",
                      "defaultValue": "443"
                    },
                    "MOSQUITTO_TCP_HOST": {
                      "description": "The host for TCP connections",
                      "defaultValue": "${{RAILWAY_TCP_PROXY_DOMAIN}}"
                    },
                    "MOSQUITTO_TCP_PORT": {
                      "description": "The external port for the TCP Proxy",
                      "defaultValue": "${{RAILWAY_TCP_PROXY_PORT}}"
                    },
                    "MAX_QUEUED_MESSAGES": {
                      "isOptional": true,
                      "description": "The maximum number of QoS 1 or 2 messages to hold in the queue (per client) above those messages that are currently in flight",
                      "defaultValue": "1024"
                    },
                    "MAX_INFLIGHT_MESSAGES": {
                      "isOptional": true,
                      "description": "The maximum number of outgoing QoS 1 or 2 messages that can be in the process of being transmitted simultaneously",
                      "defaultValue": "20"
                    }
                  },
                  "networking": {
                    "tcpProxies": {
                      "1883": {}
                    },
                    "serviceDomains": {
                      "<hasDomain>:9001": {
                        "port": 9001
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {},
  "resources": {
    "expected_services": 1,
    "needs_volume": false
  },
  "generated_at": "2026-09-20T10:14:37.339Z",
  "generator_version": "0.1.0",
  "status": "degraded",
  "validated_at": "2026-09-19T13:07:22.971Z",
  "success_rate_30d": 0.1667,
  "validation": {
    "last_run_id": "run_3db3e4f2f1a2455f874b",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": false,
        "detail": "FAILED"
      }
    ],
    "typical_ready_seconds": 178
  }
}
