{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Get information about the authenticated aggregator's API key. Note: The actual key value is NEVER returned - only metadata about the key.",
      "errors": [
        {
          "description": "Authentication is required to get API key info",
          "name": "AuthenticationRequired"
        },
        {
          "description": "Only registered aggregators can get API key info",
          "name": "AggregatorRequired"
        },
        {
          "description": "Aggregator not found",
          "name": "AggregatorNotFound"
        }
      ],
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "hasKey": {
              "description": "Whether the aggregator has an API key (active or revoked)",
              "type": "boolean"
            },
            "keyInfo": {
              "description": "API key metadata. Only present if hasKey is true.",
              "ref": "social.coves.aggregator.defs#apiKeyView",
              "type": "ref"
            }
          },
          "required": [
            "hasKey"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "description": "No parameters required. Returns key info for the authenticated aggregator.",
        "properties": {},
        "type": "params"
      },
      "type": "query"
    }
  },
  "id": "social.coves.aggregator.getApiKey",
  "lexicon": 1
}
