{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "followedReader": {
      "properties": {
        "did": {
          "format": "did",
          "type": "string"
        },
        "status": {
          "knownValues": [
            "wantToRead",
            "reading",
            "read",
            "abandoned"
          ],
          "type": "string"
        }
      },
      "required": [
        "did",
        "status"
      ],
      "type": "object"
    },
    "main": {
      "description": "Signed in, also which readers the caller follows have it.",
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "following": {
              "items": {
                "ref": "#followedReader",
                "type": "ref"
              },
              "type": "array"
            },
            "read": {
              "minimum": 0,
              "type": "integer"
            },
            "reading": {
              "minimum": 0,
              "type": "integer"
            },
            "wantToRead": {
              "minimum": 0,
              "type": "integer"
            }
          },
          "required": [
            "wantToRead",
            "reading",
            "read"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "hiveId": {
            "maxLength": 64,
            "type": "string"
          },
          "scope": {
            "default": "all",
            "description": "all: every book reader the server knows, on BookHive, Popfeed and Resenha. resenha: Resenha's readers only.",
            "knownValues": [
              "all",
              "resenha"
            ],
            "type": "string"
          }
        },
        "required": [
          "hiveId"
        ],
        "type": "params"
      },
      "type": "query"
    }
  },
  "description": "How many readers have a book, by status.",
  "id": "ink.resenha.book.getReaders",
  "lexicon": 1
}
