{"modulePath":"github.com/utmstack/UTMStack/plugins/soc-ai","version":"v0.0.0-20261126134315-738f65073a40","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package api\n\n## Functions\n\n```go\nfunc StartHTTPServer()\n```\nStartHTTPServer starts the HTTP API server for manual alert submission\n\n## Types\n\n```go\ntype AgentTaskRequest struct {\n\tTask string `json:\"task\"`\n\tPage string `json:\"page\"`\n\t// Lang is the user's interface language code (en/es/pt/…) so the agent\n\t// replies in that language regardless of the message language.\n\tLang string `json:\"lang\"`\n\t// History is prior chat turns from the client (text only). Only user and\n\t// assistant roles are accepted; tool_use/tool_result turns are internal to\n\t// a single Run() and must not be replayed.\n\tHistory []AgentTurn `json:\"history,omitempty\"`\n}\n```\nAgentTaskRequest is the body for the live operations endpoint. Page is a human-readable description of where the user currently is in the app (route + any focused entity), forwarded so the agent can pick tools and craft navigation.\n\n```go\ntype AgentTurn struct {\n\tRole    string `json:\"role\"` // \"user\" | \"assistant\"\n\tContent string `json:\"content\"`\n}\n```\nAgentTurn is a single prior chat message forwarded by the client.\n\n```go\ntype AnalyzeRequest struct {\n\tschema.AlertFields\n}\n```\nAnalyzeRequest represents the request body for manual alert analysis\n\n```go\ntype AnalyzeResponse struct {\n\tStatus  string `json:\"status\"`\n\tAlertID string `json:\"alertId,omitempty\"`\n\tMessage string `json:\"message,omitempty\"`\n}\n```\nAnalyzeResponse represents the response for the analyze endpoint\n\n","path":"github.com/utmstack/UTMStack/plugins/soc-ai/internal/api","name":"api","synopsis":"","isRedistributable":true}
