# social.grain.group.listFeed

> Every gallery in every pool the viewer is a member of, newest first. Assembled per viewer at request time: which groups they belong to is a public fact in the index, but what is in each pool is a permissioned space, read with a credential that group's host issues. Nothing here is shared between viewers or cached.

- Kind: query
- Authority: group.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.group.listFeed)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.group.listFeed/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.group.listFeed/analytics)

## Query (`social.grain.group.listFeed`)

Type: query · GET

### Parameters (query string)

- `limit` (integer)
  - Constraints: minimum: 1, maximum: 100, default: 30

### Output (application/json)

- `galleries` (array, required)
  - `items` (ref)
    - Reference: `social.grain.group.defs#poolFeedItem`
- `groups` (array, required): The pools these came out of, so a card can say whose it is.
  - `items` (ref)
    - Reference: `social.grain.group.defs#groupView`

### Errors

- `NotAuthorized`: No pool the viewer belongs to would answer.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Every gallery in every pool the viewer is a member of, newest first. Assembled per viewer at request time: which groups they belong to is a public fact in the index, but what is in each pool is a permissioned space, read with a credential that group's host issues. Nothing here is shared between viewers or cached.",
      "errors": [
        {
          "description": "No pool the viewer belongs to would answer.",
          "name": "NotAuthorized"
        }
      ],
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "galleries": {
              "items": {
                "ref": "social.grain.group.defs#poolFeedItem",
                "type": "ref"
              },
              "type": "array"
            },
            "groups": {
              "description": "The pools these came out of, so a card can say whose it is.",
              "items": {
                "ref": "social.grain.group.defs#groupView",
                "type": "ref"
              },
              "type": "array"
            }
          },
          "required": [
            "galleries",
            "groups"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "limit": {
            "default": 30,
            "maximum": 100,
            "minimum": 1,
            "type": "integer"
          }
        },
        "type": "params"
      },
      "type": "query"
    }
  },
  "id": "social.grain.group.listFeed",
  "lexicon": 1
}
```
