# social.grain.admin.getReviewStats

> Rollups for the review queue, the classifiers there are, and the progress of the latest scan. Requires an admin session.

- Kind: query
- Authority: admin.grain.social
- Lexicon: 1
- Published by [grain.social](https://lexicon.garden/identity/did:plc:e7rftrdyz5e2rw4y6ocszew2), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.admin.getReviewStats)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.admin.getReviewStats/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.admin.getReviewStats/analytics)

## Query (`social.grain.admin.getReviewStats`)

Type: query · GET

### Output (application/json)

- `byClassifier` (array, required)
  - `items` (ref)
    - Reference: `social.grain.admin.defs#classifierCount`
- `classifiers` (array, required)
  - `items` (string)
- `configured` (boolean, required): Whether a classifier model is configured, so a scan can run.
- `lastScan` (string · datetime)
- `pending` (integer, required): Subjects with an open report.
- `scan` (ref)
  - Reference: `social.grain.admin.defs#scanProgress`
- `total` (integer, required): Subjects scored.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Rollups for the review queue, the classifiers there are, and the progress of the latest scan. Requires an admin session.",
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "byClassifier": {
              "items": {
                "ref": "social.grain.admin.defs#classifierCount",
                "type": "ref"
              },
              "type": "array"
            },
            "classifiers": {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            "configured": {
              "description": "Whether a classifier model is configured, so a scan can run.",
              "type": "boolean"
            },
            "lastScan": {
              "format": "datetime",
              "type": "string"
            },
            "pending": {
              "description": "Subjects with an open report.",
              "type": "integer"
            },
            "scan": {
              "ref": "social.grain.admin.defs#scanProgress",
              "type": "ref"
            },
            "total": {
              "description": "Subjects scored.",
              "type": "integer"
            }
          },
          "required": [
            "total",
            "pending",
            "byClassifier",
            "classifiers",
            "configured"
          ],
          "type": "object"
        }
      },
      "type": "query"
    }
  },
  "id": "social.grain.admin.getReviewStats",
  "lexicon": 1
}
```
