{
  "repo": "tidbcloud/infra-api",
  "binary": "audit",
  "binary_path": "cmd/audit/main.go",
  "surface_kind": "mixed_service",
  "type": "mixed_service",
  "services": [
    {
      "name": "AuditCLI",
      "type": "cli",
      "methods": [
        {
          "name": "Precheck",
          "name_key": "CLI audit precheck",
          "description": "Validate remote object storage permissions by pushing one empty file."
        },
        {
          "name": "Server",
          "name_key": "Runtime AuditCLI.Server",
          "description": "Start the long-running audit log shipping worker."
        }
      ]
    },
    {
      "name": "MetricsAPI",
      "type": "http",
      "methods": [
        {
          "name": "Metrics",
          "name_key": "HTTP GET /metrics",
          "path": "/metrics",
          "method": "GET",
          "description": "Expose Prometheus metrics when metricsPort is configured in the audit config."
        }
      ]
    }
  ],
  "extensions": {
    "notes": [
      "cmd/audit supports a precheck CLI path, a long-running audit worker path, and an optional metrics endpoint."
    ]
  }
}
