{
  "openapi": "3.1.0",
  "info": {
    "title": "EDGE-GROK StrataMesh Lab Desk",
    "version": "1.5.3-ping-real-fog",
    "description": "Public lab edge automation desk. Read discovery is unauthenticated. Operator /ops and /internal/v1/* require Fog Bearer. Lab/pre-testnet only.",
    "contact": {
      "email": "grok@calhegasmorais.pt",
      "url": "https://edge.calhegasmorais.pt"
    },
    "license": {
      "name": "Lab public documentation — see repository"
    }
  },
  "servers": [
    {
      "url": "https://edge.calhegasmorais.pt"
    }
  ],
  "paths": {
    "/health": {
      "get": {
        "summary": "Liveness + identity",
        "operationId": "getHealth",
        "responses": {
          "200": {
            "description": "Edge identity JSON"
          }
        }
      }
    },
    "/status": {
      "get": {
        "summary": "Fog/gossip linked status",
        "operationId": "getStatus",
        "responses": {
          "200": {
            "description": "Status + discovery links"
          }
        }
      }
    },
    "/mesh": {
      "get": {
        "summary": "Mesh participation summary",
        "operationId": "getMesh",
        "responses": {
          "200": {
            "description": "Mesh state"
          }
        }
      }
    },
    "/mesh/activate": {
      "get": {
        "summary": "Lab gossip sync pulse (rate-limit)",
        "operationId": "activateMesh",
        "responses": {
          "200": {
            "description": "Sync result"
          }
        }
      }
    },
    "/ping-fog": {
      "get": {
        "summary": "Real Fog process /health (not status Worker pulse)",
        "operationId": "pingFog",
        "responses": {
          "200": {
            "description": "Fog probe"
          }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "summary": "LLM/crawler oriented plain-text guide",
        "operationId": "getLlmsTxt",
        "responses": {
          "200": {
            "description": "text/plain"
          }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "summary": "This OpenAPI document",
        "operationId": "getOpenApi",
        "responses": {
          "200": {
            "description": "OpenAPI JSON"
          }
        }
      }
    },
    "/ops": {
      "get": {
        "summary": "Authenticated operator HTML dash (lab)",
        "operationId": "getOpsDesk",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Operator HTML"
          },
          "401": {
            "description": "auth_required"
          }
        }
      }
    },
    "/internal/v1/identity": {
      "get": {
        "summary": "EDGE-GROK identity (kind=user, not SCA)",
        "operationId": "getOpsIdentity",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Identity JSON"
          },
          "401": {
            "description": "auth_required"
          }
        }
      }
    },
    "/internal/v1/posture": {
      "get": {
        "summary": "Aggregate live probes + torch",
        "operationId": "getOpsPosture",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Posture JSON"
          },
          "401": {
            "description": "auth_required"
          }
        }
      }
    },
    "/internal/v1/automations": {
      "get": {
        "summary": "Desk-owned automation catalog + capability/training",
        "operationId": "getOpsAutomations",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Automations JSON"
          },
          "401": {
            "description": "auth_required"
          }
        }
      }
    },
    "/internal/v1/torch": {
      "get": {
        "summary": "Torch/handoff gates; do not pass unless capability ready",
        "operationId": "getOpsTorch",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Torch JSON"
          },
          "401": {
            "description": "auth_required"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "Fog session",
        "description": "Authorization: Bearer <fog session>. Public routes stay unauthenticated."
      }
    }
  },
  "x-lab": true,
  "x-node-id": "EDGE-GROK-CMN-001",
  "x-linked-fog": "FOG-NODE-PT-CM-001",
  "x-sdk": "https://github.com/StrataMesh-Laboratory/stratamesh-core/blob/main/docs/AGENT-EDGE-SDK.md"
}