Get a library statistic
get_library_statisticRetrieve pre-aggregated library-wide statistics charts for distributions, top lists, timelines, relationships, and metadata health. Optionally filter by library IDs to focus on specific collections.
Instructions
Get one pre-aggregated, library-wide statistics chart (not the user's personal reading — use get_reading_statistic for that; for headline totals use get_library_stats). Pick a 'kind':
Distributions: format-distribution, genre-distribution, language-distribution, publication-decade, page-count-distribution, storage-by-format.
Top-N & rankings: top-authors, top-series, largest-books.
Timelines: books-added-over-time, publication-year-timeline, format-share-over-time.
Relationships: genre-cooccurrence, acquisition-lag-scatter.
Metadata health: metadata-completeness, library-metadata-completeness, metadata-score-distribution, metadata-freshness-gauge, library-integrity-gauge. Optionally restrict to one or more libraryIds. 'granularity' and 'range' apply only to books-added-over-time.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Which library statistic to fetch. | |
| range | No | Only for books-added-over-time. Default all-time. | |
| libraryIds | No | Restrict the aggregation to these library ids (default: all visible). | |
| granularity | No | Only for books-added-over-time. Default monthly. |