{
  "repo": "tidbcloud/finops-sql",
  "binary": "finops-query-gateway",
  "binary_path": "finops-query-gateway/package.json",
  "dependencies": {
    "HTTP GET /healthz": {
      "infrastructure": {},
      "services": []
    },
    "HTTP GET /readyz": {
      "infrastructure": {
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "SELECT 1",
              "trigger": "GET /readyz",
              "implementation": "finops-query-gateway/src/routes/health.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP POST /v1/query/ask": {
      "infrastructure": {
        "llm": {
          "conditions": [
            "LLM API key configured"
          ],
          "operations": [
            {
              "operation": "Plan query from natural language",
              "trigger": "POST /v1/query/ask",
              "implementation": "finops-query-gateway/src/routes/query.ts"
            }
          ]
        },
        "bigquery": {
          "conditions": [
            "mode == execute or preview"
          ],
          "operations": [
            {
              "operation": "Preview or execute semantic query shards",
              "trigger": "POST /v1/query/ask",
              "implementation": "finops-query-gateway/src/routes/query.ts"
            }
          ]
        },
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Write and update audit logs",
              "trigger": "POST /v1/query/ask",
              "implementation": "finops-query-gateway/src/routes/query.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP POST /v1/query/analyses/:analysisId": {
      "infrastructure": {
        "bigquery": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Execute built-in analysis template",
              "trigger": "POST /v1/query/analyses/:analysisId",
              "implementation": "finops-query-gateway/src/routes/query.ts"
            }
          ]
        },
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Write and update audit logs",
              "trigger": "POST /v1/query/analyses/:analysisId",
              "implementation": "finops-query-gateway/src/routes/query.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP GET /v1/catalog/semantic-schema": {
      "infrastructure": {},
      "services": []
    },
    "HTTP GET /v1/catalog/accounts": {
      "infrastructure": {
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Resolve visible accounts",
              "trigger": "GET /v1/catalog/accounts",
              "implementation": "finops-query-gateway/src/routes/catalog.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP POST /v1/admin/tokens": {
      "infrastructure": {
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Create api_token rows",
              "trigger": "POST /v1/admin/tokens",
              "implementation": "finops-query-gateway/src/routes/admin.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP POST /v1/admin/grants": {
      "infrastructure": {
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Upsert account access grant",
              "trigger": "POST /v1/admin/grants",
              "implementation": "finops-query-gateway/src/routes/admin.ts"
            }
          ]
        }
      },
      "services": []
    },
    "HTTP GET /v1/admin/audit": {
      "infrastructure": {
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Read audit log rows",
              "trigger": "GET /v1/admin/audit",
              "implementation": "finops-query-gateway/src/routes/admin.ts"
            }
          ]
        }
      },
      "services": []
    }
  }
}
