{
  "repo": "tidbcloud/finops-sql",
  "binary": "finops-query-gateway",
  "binary_path": "finops-query-gateway/package.json",
  "surface_kind": "http_service",
  "type": "http_service",
  "services": [
    {
      "name": "HealthAPI",
      "type": "http",
      "methods": [
        {
          "name": "Healthz",
          "name_key": "HTTP GET /healthz",
          "path": "/healthz",
          "method": "GET",
          "description": "Basic liveness probe for the Fastify gateway."
        },
        {
          "name": "Readyz",
          "name_key": "HTTP GET /readyz",
          "path": "/readyz",
          "method": "GET",
          "description": "Database-backed readiness probe for the gateway."
        }
      ]
    },
    {
      "name": "QueryAPI",
      "type": "http",
      "methods": [
        {
          "name": "Ask",
          "name_key": "HTTP POST /v1/query/ask",
          "path": "/v1/query/ask",
          "method": "POST",
          "description": "Translate natural language FinOps questions into semantic queries and optionally execute them."
        },
        {
          "name": "RunAnalysis",
          "name_key": "HTTP POST /v1/query/analyses/:analysisId",
          "path": "/v1/query/analyses/:analysisId",
          "method": "POST",
          "description": "Run a built-in FinOps analysis template."
        }
      ]
    },
    {
      "name": "CatalogAPI",
      "type": "http",
      "methods": [
        {
          "name": "GetSemanticSchema",
          "name_key": "HTTP GET /v1/catalog/semantic-schema",
          "path": "/v1/catalog/semantic-schema",
          "method": "GET",
          "description": "Return supported dimensions, metrics, and analysis templates."
        },
        {
          "name": "GetAccounts",
          "name_key": "HTTP GET /v1/catalog/accounts",
          "path": "/v1/catalog/accounts",
          "method": "GET",
          "description": "Return visible cloud accounts for the authenticated caller."
        }
      ]
    },
    {
      "name": "AdminAPI",
      "type": "http",
      "methods": [
        {
          "name": "CreateToken",
          "name_key": "HTTP POST /v1/admin/tokens",
          "path": "/v1/admin/tokens",
          "method": "POST",
          "description": "Create a new API token."
        },
        {
          "name": "CreateGrant",
          "name_key": "HTTP POST /v1/admin/grants",
          "path": "/v1/admin/grants",
          "method": "POST",
          "description": "Grant account access to a user."
        },
        {
          "name": "GetAuditLog",
          "name_key": "HTTP GET /v1/admin/audit",
          "path": "/v1/admin/audit",
          "method": "GET",
          "description": "Query audit log records."
        }
      ]
    }
  ],
  "extensions": {}
}
