# pub.oysters.getFeed

> Published by [oysters.pub](https://lexicon.garden/identity/did:plc:gsvuczfwpmrqpap45iz23j43)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:gsvuczfwpmrqpap45iz23j43/pub.oysters.getFeed)
- [Documentation](https://lexicon.garden/lexicon/did:plc:gsvuczfwpmrqpap45iz23j43/pub.oysters.getFeed/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:gsvuczfwpmrqpap45iz23j43/pub.oysters.getFeed/examples)

## Definitions

### `pub.oysters.getFeed`

**Type**: `query`

A page of the board's feed. Public: no authentication, and the same answer for everybody.

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `sort` | `string` | No | Ranking to page through. 'hot' is the board's own ranking; 'new' is submission order. |
| `tags` | `array` | No | Restrict to submissions carrying any of these tags. OR, not AND. Tags outside the curated vocabulary are an error rather than an empty page, so a typo is visible. |
| `limit` | `integer` | No | How many submissions to return. |
| `cursor` | `string` | No | Opaque. Pass back what the previous page returned; do not construct one. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `feed` | `array` | Yes | The page, in ranking order. |
| `cursor` | `string` | No | Pass to the next call. Absent when there is nothing more. |

#### Errors

- **InvalidRequest**: An unknown tag, an unknown sort, or a cursor that did not decode.

## Raw Schema

```json
{
  "id": "pub.oysters.getFeed",
  "defs": {
    "main": {
      "type": "query",
      "errors": [
        {
          "name": "InvalidRequest",
          "description": "An unknown tag, an unknown sort, or a cursor that did not decode."
        }
      ],
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "feed"
          ],
          "properties": {
            "feed": {
              "type": "array",
              "items": {
                "ref": "pub.oysters.defs#postView",
                "type": "ref"
              },
              "description": "The page, in ranking order."
            },
            "cursor": {
              "type": "string",
              "description": "Pass to the next call. Absent when there is nothing more."
            }
          }
        },
        "encoding": "application/json"
      },
      "parameters": {
        "type": "params",
        "properties": {
          "sort": {
            "type": "string",
            "default": "hot",
            "description": "Ranking to page through. 'hot' is the board's own ranking; 'new' is submission order.",
            "knownValues": [
              "hot",
              "new"
            ]
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 128
            },
            "maxLength": 10,
            "description": "Restrict to submissions carrying any of these tags. OR, not AND. Tags outside the curated vocabulary are an error rather than an empty page, so a typo is visible."
          },
          "limit": {
            "type": "integer",
            "default": 25,
            "maximum": 100,
            "minimum": 1,
            "description": "How many submissions to return."
          },
          "cursor": {
            "type": "string",
            "description": "Opaque. Pass back what the previous page returned; do not construct one."
          }
        }
      },
      "description": "A page of the board's feed. Public: no authentication, and the same answer for everybody."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
