at.spandrel.counts.getRecordCounts
Get the number of records in each collection of an account's repo.
Details · query
| Kind | query |
|---|---|
| Authority | counts.spandrel.at |
| Commit rev | 3n2midypmw22p |
| Indexed |
Checks
Valid Lint pass{
"$type": "com.atproto.lexicon.schema",
"defs": {
"collectionCount": {
"properties": {
"collection": {
"format": "nsid",
"type": "string"
},
"count": {
"minimum": 1,
"type": "integer"
}
},
"required": [
"collection",
"count"
],
"type": "object"
},
"main": {
"description": "Get the number of records in each collection of an account's repo.",
"errors": [
{
"name": "RepoTakendown"
},
{
"name": "RepoSuspended"
},
{
"name": "RepoDeactivated"
},
{
"name": "RepoDeleted"
},
{
"description": "No repo was found for this account.",
"name": "RepoNotFound"
},
{
"description": "The repo is too large to count.",
"name": "RepoTooLarge"
},
{
"description": "The repo could not be fetched.",
"name": "UpstreamFailure"
},
{
"description": "The repo is still being counted. Retry after the time in the Retry-After header.",
"name": "CountInProgress"
},
{
"description": "Too many accounts are waiting to be counted. Retry after the time in the Retry-After header.",
"name": "CountQueueFull"
}
],
"output": {
"encoding": "application/json",
"schema": {
"properties": {
"counts": {
"description": "One count per collection, sorted by collection name.",
"items": {
"ref": "#collectionCount",
"type": "ref"
},
"type": "array"
},
"did": {
"format": "did",
"type": "string"
},
"rev": {
"description": "The last counted repo revision.",
"format": "tid",
"type": "string"
}
},
"required": [
"did",
"rev",
"counts"
],
"type": "object"
}
},
"parameters": {
"properties": {
"collection": {
"description": "Which collections to return counts for. If omitted, every collection is returned.",
"items": {
"format": "nsid",
"type": "string"
},
"maxLength": 50,
"type": "array"
},
"repo": {
"description": "The account. Only did:plc and did:web are supported.",
"format": "did",
"type": "string"
}
},
"required": [
"repo"
],
"type": "params"
},
"type": "query"
}
},
"id": "at.spandrel.counts.getRecordCounts",
"lexicon": 1
}