{
    "openapi": "3.0.0",
    "info": {
        "title": "TurboStack API",
        "contact": {
            "email": "support@hosted-power.com"
        },
        "version": "v1"
    },
    "paths": {
        "/api/v1/analysis": {
            "get": {
                "tags": [
                    "Analysis"
                ],
                "summary": "Staff meta-analysis work queue (Central Brain)",
                "operationId": "analysis.account",
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden for client tokens"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/clients": {
            "get": {
                "tags": [
                    "Clients"
                ],
                "summary": "List of all clients",
                "description": "List clients",
                "operationId": "clients",
                "parameters": [
                    {
                        "name": "size",
                        "in": "query",
                        "description": "Number of items per page",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 15
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "description": "Page number for pagination",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "description": "Filter clients by name, email, company, or ID",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Lists of Clients",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "properties": {
                                            "id": {
                                                "type": "number"
                                            },
                                            "firstname": {
                                                "type": "string"
                                            },
                                            "lastname": {
                                                "type": "string"
                                            },
                                            "email": {
                                                "type": "string"
                                            },
                                            "created_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "updated_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            }
                                        },
                                        "type": "object"
                                    }
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/clients/{id}": {
            "get": {
                "tags": [
                    "Clients"
                ],
                "summary": "Fetch one specific client",
                "description": "Fetch a specific client by ID",
                "operationId": "client/id",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the client",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One Client",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "id": {
                                            "type": "number"
                                        },
                                        "firstname": {
                                            "type": "string"
                                        },
                                        "lastname": {
                                            "type": "string"
                                        },
                                        "email": {
                                            "type": "string"
                                        },
                                        "created_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        },
                                        "updated_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/clients/{id}/hosts": {
            "get": {
                "tags": [
                    "Clients"
                ],
                "summary": "Get all active hosts of client",
                "description": "Lists hosts by client",
                "operationId": "clients/id/hosts",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the client",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "size",
                        "in": "query",
                        "description": "Number of items per page",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 15
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "description": "Page number for pagination",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "description": "Filter hosts by name (partial match)",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Lists hosts of Client",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "properties": {
                                            "id": {
                                                "type": "number"
                                            },
                                            "client_id": {
                                                "type": "number"
                                            },
                                            "active": {
                                                "type": "number"
                                            },
                                            "name": {
                                                "type": "string"
                                            },
                                            "json": {
                                                "format": "string"
                                            },
                                            "created_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "updated_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "monitoring": {
                                                "description": "Live server status read from Redis (populated by icinga-monitoring:sync)",
                                                "properties": {
                                                    "load": {
                                                        "type": "object"
                                                    },
                                                    "disk": {
                                                        "type": "object"
                                                    },
                                                    "memory": {
                                                        "type": "object"
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "type": "object"
                                    }
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/clients/{id}/groups": {
            "get": {
                "tags": [
                    "Clients"
                ],
                "summary": "Get all groups of client",
                "description": "List groups by client",
                "operationId": "clients/id/groups",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the client",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "size",
                        "in": "query",
                        "description": "Number of items per page",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 15
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "description": "Page number for pagination",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "description": "Filter groups by name (partial match)",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Lists groups of Client",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "properties": {
                                            "id": {
                                                "type": "number"
                                            },
                                            "client_id": {
                                                "type": "number"
                                            },
                                            "name": {
                                                "type": "string"
                                            },
                                            "json": {
                                                "format": "string"
                                            },
                                            "created_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "updated_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            }
                                        },
                                        "type": "object"
                                    }
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "List of all active hosts",
                "description": "List hosts",
                "operationId": "hosts",
                "parameters": [
                    {
                        "name": "size",
                        "in": "query",
                        "description": "Number of items per page",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 15
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "description": "Page number for pagination",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "description": "Filter hosts by name (partial match)",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Lists of Hosts",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "properties": {
                                            "id": {
                                                "type": "number"
                                            },
                                            "client_id": {
                                                "type": "number"
                                            },
                                            "active": {
                                                "type": "number"
                                            },
                                            "name": {
                                                "type": "string"
                                            },
                                            "json": {
                                                "format": "string"
                                            },
                                            "created_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "updated_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "monitoring": {
                                                "description": "Live server status read from Redis (populated by icinga-monitoring:sync)",
                                                "properties": {
                                                    "load": {
                                                        "type": "object"
                                                    },
                                                    "disk": {
                                                        "type": "object"
                                                    },
                                                    "memory": {
                                                        "type": "object"
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "type": "object"
                                    }
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            },
            "post": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Create a new host (admin only)",
                "description": "Create a new host (admin only)",
                "operationId": "hosts-create",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "required": [
                                    "name",
                                    "client_id"
                                ],
                                "properties": {
                                    "name": {
                                        "type": "string",
                                        "example": "new-host.example.com"
                                    },
                                    "client_id": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "active": {
                                        "type": "boolean",
                                        "example": true
                                    },
                                    "json": {
                                        "type": "object"
                                    },
                                    "yaml": {
                                        "type": "string"
                                    },
                                    "json_admin": {
                                        "type": "object"
                                    },
                                    "yaml_admin": {
                                        "type": "string"
                                    }
                                },
                                "type": "object"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Host created successfully",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "id": {
                                            "type": "integer",
                                            "example": 42
                                        },
                                        "message": {
                                            "type": "string",
                                            "example": "Host created successfully"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "422": {
                        "description": "Validation errors"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Fetch one specific host",
                "description": "Host detail",
                "operationId": "hosts/id",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Lists of Hosts",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "id": {
                                            "type": "number"
                                        },
                                        "client_id": {
                                            "type": "number"
                                        },
                                        "active": {
                                            "type": "number"
                                        },
                                        "name": {
                                            "type": "string"
                                        },
                                        "json": {
                                            "format": "string"
                                        },
                                        "created_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        },
                                        "updated_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        },
                                        "monitoring": {
                                            "description": "Live server status read from Redis (populated by icinga-monitoring:sync)",
                                            "properties": {
                                                "load": {
                                                    "type": "object"
                                                },
                                                "disk": {
                                                    "type": "object"
                                                },
                                                "memory": {
                                                    "type": "object"
                                                }
                                            },
                                            "type": "object"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            },
            "post": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Update JSON (configuration) of host",
                "description": "Save host",
                "operationId": "hosts/id/save",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "properties": {
                                    "json": {
                                        "description": "Client configuration (client-access tokens)",
                                        "type": "object"
                                    },
                                    "json_admin": {
                                        "description": "Admin configuration (admin-access tokens only)",
                                        "type": "object"
                                    }
                                },
                                "type": "object"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Saved Successfully",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "message": {
                                            "type": "string",
                                            "example": "Host saved successfully"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/deploy": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Get status of deploy",
                "description": "Get deploy status",
                "operationId": "hosts/id/deploy-status",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Deploy Status",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "publishing": {
                                            "description": "Whether a deploy is marked as active",
                                            "type": "boolean"
                                        },
                                        "publishing_status": {
                                            "description": "Current deploy status",
                                            "type": "string",
                                            "enum": [
                                                "deploy",
                                                "published",
                                                "error",
                                                "timeout",
                                                "canceled"
                                            ]
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Host not found or no deploy history",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "error": {
                                            "type": "string",
                                            "example": "No deploy history found"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            },
            "post": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Start deploy of host",
                "description": "Start deploy of host",
                "operationId": "hosts/id/deploy-start",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "required": [
                                    "type"
                                ],
                                "properties": {
                                    "type": {
                                        "description": "Type of deployment to execute",
                                        "type": "string",
                                        "enum": [
                                            "deploy",
                                            "fullDeploy",
                                            "fullDeleteDeploy"
                                        ]
                                    }
                                },
                                "type": "object"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Deploy Started",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "message": {
                                            "type": "string",
                                            "example": "Deploy started"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "Validation error or host is currently deploying",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "error": {
                                            "type": "string",
                                            "example": "Host is currently deploying"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            },
            "delete": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Reset stuck deploy state",
                "description": "Reset deploy state so a new deploy can be triggered.",
                "operationId": "hosts/id/deploy-reset",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Deploy Reset",
                        "content": {
                            "application/json": {
                                "schema": {}
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/groups": {
            "get": {
                "tags": [
                    "Groups"
                ],
                "summary": "List of all groups",
                "description": "List Groups",
                "operationId": "groups",
                "parameters": [
                    {
                        "name": "size",
                        "in": "query",
                        "description": "Number of items per page",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 15
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "description": "Page number for pagination",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "description": "Filter groups by name (partial match)",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "List of Groups",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "properties": {
                                            "id": {
                                                "type": "number"
                                            },
                                            "name": {
                                                "type": "string"
                                            },
                                            "json": {
                                                "format": "string"
                                            },
                                            "created_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            },
                                            "updated_at": {
                                                "type": "string",
                                                "format": "date-time"
                                            }
                                        },
                                        "type": "object"
                                    }
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/groups/{id}": {
            "get": {
                "tags": [
                    "Groups"
                ],
                "summary": "Fetch one specific group",
                "description": "Group detail",
                "operationId": "groups/id",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Group",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Object of Group",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "id": {
                                            "type": "number"
                                        },
                                        "name": {
                                            "type": "string"
                                        },
                                        "json": {
                                            "format": "string"
                                        },
                                        "created_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        },
                                        "updated_at": {
                                            "type": "string",
                                            "format": "date-time"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            },
            "post": {
                "tags": [
                    "Groups"
                ],
                "summary": "Save or update a specific group",
                "description": "Save Group",
                "operationId": "saveGroup",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Group",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "required": [
                                    "json"
                                ],
                                "properties": {
                                    "json": {
                                        "type": "object"
                                    }
                                },
                                "type": "object"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Group saved successfully",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "message": {
                                            "type": "string",
                                            "example": "Group saved successfully"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "error": {
                                            "type": "string",
                                            "example": "Forbidden"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Group not found",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "error": {
                                            "type": "string",
                                            "example": "Group not found"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/credentials": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Get credentials for a specific host",
                "description": "Get host credentials from Vault + YAML",
                "operationId": "hosts/id/credentials",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Host credentials and configuration",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "hostname": {
                                            "type": "string"
                                        },
                                        "master_user": {
                                            "description": "Only returned for admin-access or cms-access tokens",
                                            "properties": {
                                                "user": {
                                                    "type": "string"
                                                },
                                                "password": {
                                                    "type": "string",
                                                    "nullable": true
                                                }
                                            },
                                            "type": "object"
                                        },
                                        "admin_user": {
                                            "description": "Only returned for admin-access or cms-access tokens on supported panels",
                                            "properties": {
                                                "user": {
                                                    "type": "string"
                                                },
                                                "password": {
                                                    "type": "string",
                                                    "nullable": true
                                                }
                                            },
                                            "type": "object"
                                        },
                                        "facts": {
                                            "type": "object"
                                        },
                                        "network": {
                                            "type": "object"
                                        },
                                        "platform": {
                                            "type": "object"
                                        },
                                        "system_users": {
                                            "type": "array",
                                            "items": {
                                                "type": "object"
                                            }
                                        },
                                        "ftp_users": {
                                            "type": "array",
                                            "items": {
                                                "type": "object"
                                            }
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Unauthorized"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    },
                    "500": {
                        "description": "Internal server error"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/health": {
            "get": {
                "tags": [
                    "Health"
                ],
                "summary": "Health check for the API and external services",
                "operationId": "health.check",
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/api/v1/health/issues": {
            "get": {
                "tags": [
                    "Health"
                ],
                "summary": "Scoped top issues (Central Brain)",
                "operationId": "health.issues",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Staff only: comma-separated HostBill client ids",
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "422": {
                        "description": "Validation error"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/health/reports": {
            "get": {
                "tags": [
                    "Health"
                ],
                "summary": "Scoped health reports (Central Brain)",
                "operationId": "health.reports",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Comma-separated HostBill client ids",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "host_names",
                        "in": "query",
                        "description": "Comma-separated host names",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "description": "Reports per host (max 50)",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "422": {
                        "description": "Validation error"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/health/{id}/issues": {
            "get": {
                "tags": [
                    "Health"
                ],
                "summary": "Host top issues (Central Brain)",
                "operationId": "host.issues",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Not found"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/health/{id}/reports": {
            "get": {
                "tags": [
                    "Health"
                ],
                "summary": "Host reports (Central Brain)",
                "operationId": "host.reports",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Not found"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/history/revisions": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Configuration revisions of a host",
                "description": "The Revisions tab of the History modal. One entry per logical save, newest first. `api_token` names the API token a change came through, is an empty string when that name is hidden from a client token, and is null for a change made in the GUI.",
                "operationId": "hosts/id/history/revisions",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1,
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 25,
                            "maximum": 100,
                            "minimum": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Revisions",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "properties": {
                                                    "id": {
                                                        "type": "integer"
                                                    },
                                                    "author": {
                                                        "type": "string",
                                                        "example": "jane@example.com",
                                                        "nullable": true
                                                    },
                                                    "api_token": {
                                                        "type": "string",
                                                        "example": "Deploy pipeline",
                                                        "nullable": true
                                                    },
                                                    "published": {
                                                        "type": "boolean"
                                                    },
                                                    "reverted": {
                                                        "type": "boolean"
                                                    },
                                                    "from_group": {
                                                        "type": "boolean"
                                                    },
                                                    "deploy_tags": {
                                                        "description": "Plays a publish of this change runs; empty means a full deploy",
                                                        "type": "array",
                                                        "items": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "changes": {
                                                        "type": "array",
                                                        "items": {
                                                            "properties": {
                                                                "path": {
                                                                    "type": "string",
                                                                    "example": "/mysql_version"
                                                                },
                                                                "old": {
                                                                    "nullable": true
                                                                },
                                                                "new": {
                                                                    "nullable": true
                                                                }
                                                            },
                                                            "type": "object"
                                                        }
                                                    },
                                                    "created_at": {
                                                        "type": "string",
                                                        "format": "date-time"
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "meta": {
                                            "$ref": "#/components/schemas/HistoryMeta"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/history/deploys": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Deploys of a host",
                "description": "The Deploys tab of the History modal, newest first, including the AWX output of each deploy.",
                "operationId": "hosts/id/history/deploys",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1,
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 25,
                            "maximum": 100,
                            "minimum": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Deploys",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "properties": {
                                                    "id": {
                                                        "type": "integer"
                                                    },
                                                    "author": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "deploy_type": {
                                                        "type": "string",
                                                        "example": "Deploy"
                                                    },
                                                    "components": {
                                                        "description": "Plays that ran; empty means a full deploy",
                                                        "type": "array",
                                                        "items": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "status": {
                                                        "type": "string",
                                                        "enum": [
                                                            "deploy",
                                                            "published",
                                                            "error",
                                                            "timeout",
                                                            "canceled"
                                                        ]
                                                    },
                                                    "started_at": {
                                                        "type": "string",
                                                        "format": "date-time"
                                                    },
                                                    "finished_at": {
                                                        "type": "string",
                                                        "format": "date-time",
                                                        "nullable": true
                                                    },
                                                    "job_stdout": {
                                                        "type": "string"
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "meta": {
                                            "$ref": "#/components/schemas/HistoryMeta"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/history/cloning": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Clone operations of a host",
                "description": "The Cloning tab of the History modal, newest first.",
                "operationId": "hosts/id/history/cloning",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1,
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 25,
                            "maximum": 100,
                            "minimum": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Clone operations",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "properties": {
                                                    "id": {
                                                        "type": "integer"
                                                    },
                                                    "author": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "clone_type": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "source_host": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "source_username": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "destination_username": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "clone_files": {
                                                        "type": "boolean"
                                                    },
                                                    "clone_database": {
                                                        "type": "boolean"
                                                    },
                                                    "parameters": {
                                                        "type": "object"
                                                    },
                                                    "created_at": {
                                                        "type": "string",
                                                        "format": "date-time"
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "meta": {
                                            "$ref": "#/components/schemas/HistoryMeta"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/hosts/{id}/history/actions": {
            "get": {
                "tags": [
                    "Hosts"
                ],
                "summary": "Monitoring actions of a host",
                "description": "The Actions tab of the History modal: every pause of the downtime monitoring, newest first. `status` is `active` while the pause runs, `resumed` when someone ended it early and `expired` when it ran until its end.",
                "operationId": "hosts/id/history/actions",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "ID of the Host",
                        "required": true,
                        "schema": {
                            "type": "integer",
                            "format": "int64"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 1,
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "integer",
                            "default": 25,
                            "maximum": 100,
                            "minimum": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Monitoring actions",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "properties": {
                                                    "id": {
                                                        "type": "integer"
                                                    },
                                                    "action": {
                                                        "type": "string",
                                                        "enum": [
                                                            "pause_downtime_monitoring"
                                                        ]
                                                    },
                                                    "author": {
                                                        "type": "string",
                                                        "nullable": true
                                                    },
                                                    "status": {
                                                        "type": "string",
                                                        "enum": [
                                                            "active",
                                                            "resumed",
                                                            "expired"
                                                        ]
                                                    },
                                                    "starts_at": {
                                                        "type": "string",
                                                        "format": "date-time"
                                                    },
                                                    "ends_at": {
                                                        "description": "The planned end of the pause",
                                                        "type": "string",
                                                        "format": "date-time"
                                                    },
                                                    "ended_at": {
                                                        "type": "string",
                                                        "format": "date-time",
                                                        "nullable": true
                                                    },
                                                    "ended_by": {
                                                        "description": "Who resumed the monitoring early",
                                                        "type": "string",
                                                        "nullable": true
                                                    }
                                                },
                                                "type": "object"
                                            }
                                        },
                                        "meta": {
                                            "$ref": "#/components/schemas/HistoryMeta"
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/monitoring": {
            "get": {
                "tags": [
                    "Monitoring"
                ],
                "summary": "Icinga monitoring services (scoped to token)",
                "operationId": "monitoring.account",
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/monitoring/{id}": {
            "get": {
                "tags": [
                    "Monitoring"
                ],
                "summary": "Host Icinga services and metrics",
                "operationId": "host.monitoring",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "403": {
                        "description": "Forbidden"
                    },
                    "404": {
                        "description": "Not found"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threat-center": {
            "get": {
                "tags": [
                    "ThreatCenter"
                ],
                "summary": "Account-wide Threat Center (vulnerabilities|iocs|events)",
                "operationId": "threatCenter.account",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Comma-separated portal client ids",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "host_names",
                        "in": "query",
                        "description": "Comma-separated host names",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "endpoint",
                        "in": "query",
                        "description": "One of vulnerabilities,iocs,events",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "example": "vulnerabilities"
                        }
                    },
                    {
                        "name": "priority",
                        "in": "query",
                        "description": "Optional priority filter for vulnerabilities/events",
                        "required": false,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "items": {
                                            "type": "array",
                                            "items": {
                                                "type": "object"
                                            }
                                        },
                                        "counts": {
                                            "type": "object"
                                        },
                                        "truncated": {
                                            "type": "boolean"
                                        },
                                        "failed_client_ids": {
                                            "type": "array",
                                            "items": {
                                                "type": "integer"
                                            }
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Validation error"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threat-center/{id}": {
            "get": {
                "tags": [
                    "ThreatCenter"
                ],
                "summary": "Host-scoped Threat Center view",
                "operationId": "threatCenter.host",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "Host file id",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "endpoint",
                        "in": "query",
                        "description": "One of vulnerabilities,iocs,events",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "example": "vulnerabilities"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "file": {
                                            "type": "object"
                                        },
                                        "items": {
                                            "type": "object"
                                        },
                                        "connector": {
                                            "type": "object"
                                        },
                                        "rescan_requested_at": {
                                            "type": "integer",
                                            "nullable": true
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Not found"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "422": {
                        "description": "Invalid parameter: empty client_ids or host_names, an unscoped staff request, or an unknown endpoint"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threat-center/{id}/rescan": {
            "post": {
                "tags": [
                    "ThreatCenter"
                ],
                "summary": "Request host rescan",
                "operationId": "threatCenter.host.rescan",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "description": "Host file id",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "properties": {
                                        "ok": {
                                            "type": "boolean"
                                        },
                                        "requested_at": {
                                            "type": "integer",
                                            "nullable": true
                                        },
                                        "error": {
                                            "type": "string",
                                            "nullable": true
                                        }
                                    },
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Not found"
                    },
                    "429": {
                        "description": "Too many rescans: at most 5 per minute per caller and host"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/vulnerabilities": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Account-wide or client-scoped vulnerabilities",
                "operationId": "threats.vulnerabilities",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Comma-separated client ids",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "host_names",
                        "in": "query",
                        "description": "Comma-separated host names",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "priority",
                        "in": "query",
                        "description": "Filter by priority",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "description": "Account-wide limit (max 200)",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "422": {
                        "description": "Invalid parameter: empty client_ids or host_names, an unscoped staff request, or an unknown endpoint"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/iocs": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Account-wide or client-scoped Indicators of Compromise",
                "operationId": "threats.iocs",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Comma-separated client ids",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "host_names",
                        "in": "query",
                        "description": "Comma-separated host names",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "description": "Account-wide limit (max 200)",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "422": {
                        "description": "Invalid parameter: empty client_ids or host_names, an unscoped staff request, or an unknown endpoint"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/runtime-detections": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Account-wide or client-scoped runtime detections (Falco)",
                "operationId": "threats.runtimeDetections",
                "parameters": [
                    {
                        "name": "client_ids",
                        "in": "query",
                        "description": "Comma-separated client ids",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "host_names",
                        "in": "query",
                        "description": "Comma-separated host names",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "description": "Account-wide limit (max 200)",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "422": {
                        "description": "Invalid parameter: empty client_ids or host_names, an unscoped staff request, or an unknown endpoint"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/{id}/vulnerabilities": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Host vulnerabilities",
                "operationId": "host.vulnerabilities",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "priority",
                        "in": "query",
                        "description": "Filter by priority",
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/{id}/iocs": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Host Indicators of Compromise",
                "operationId": "host.iocs",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        },
        "/api/v1/threats/{id}/runtime-detections": {
            "get": {
                "tags": [
                    "Threats"
                ],
                "summary": "Host runtime detections (Falco)",
                "operationId": "host.runtimeDetections",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    },
                    "401": {
                        "description": "Unauthenticated: missing or invalid token"
                    },
                    "403": {
                        "description": "Forbidden: the token may not see this scope or host"
                    },
                    "404": {
                        "description": "Host not found"
                    }
                },
                "security": [
                    {
                        "bearerAuth": []
                    }
                ]
            }
        }
    },
    "components": {
        "schemas": {
            "HistoryMeta": {
                "properties": {
                    "page": {
                        "description": "Exposes the History modal of a host through the external API.\n\nOne route per tab of the modal: revisions, deploys, cloning and actions. Each answers the\nsame records the tab shows, newest first and paginated, with dates in ISO 8601. A client\ntoken sees Hosted Power staff as \"Hosted Power\" wherever the tab masks them.",
                        "type": "integer",
                        "example": 1
                    },
                    "per_page": {
                        "type": "integer",
                        "example": 25
                    },
                    "total": {
                        "type": "integer",
                        "example": 3
                    },
                    "last_page": {
                        "type": "integer",
                        "example": 1
                    }
                },
                "type": "object"
            }
        },
        "securitySchemes": {
            "bearerAuth": {
                "type": "apiKey",
                "description": "Enter token in format: Bearer {your-token}",
                "name": "Authorization",
                "in": "header"
            }
        }
    },
    "tags": [
        {
            "name": "Analysis",
            "description": "Analysis"
        },
        {
            "name": "Clients",
            "description": "Clients"
        },
        {
            "name": "Hosts",
            "description": "Hosts"
        },
        {
            "name": "Groups",
            "description": "Groups"
        },
        {
            "name": "Health",
            "description": "Health"
        },
        {
            "name": "Monitoring",
            "description": "Monitoring"
        },
        {
            "name": "ThreatCenter",
            "description": "ThreatCenter"
        },
        {
            "name": "Threats",
            "description": "Threats"
        }
    ]
}