# dev.knotless.getFeed

> What happened on the public repositories an appview has indexed, newest first: repositories created and forked, refs pushed and deleted, pulls and issues opened, discussed and moved between states, and repositories starred. With filter `following`, what the account asking and those it follows did, and anything done on its repositories and those it starred; without, the same for anyone, but no stars. Without `actor`, what a repository's bots said or pushed on it is left out: the runners and triagers its record names, but its owner and collaborators. A pull a runner merged landing the merge queue is shown as merged by whoever queued it. Optional authentication: asked as an account, with a service token or the pages' session cookie, what happened on the private repositories it may read too, its own and those it was proven a member of, as the server's index of their spaces has it, whoever did it, whom it follows or not; and the answer is that account's alone.

- Kind: query
- Authority: knotless.dev
- Lexicon: 1
- Published by [lexicons.knotless.dev](https://lexicon.garden/identity/did:plc:yqsg7znbbhfmj3a2nrpnaerk), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getFeed)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getFeed/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getFeed/analytics)

## Query (`dev.knotless.getFeed`)

Type: query · GET

### Parameters (query string)

- `actor` (string · did): Only what this account did: the repositories it created, the refs it pushed, the pulls, issues, comments and changes of state it wrote, and the repositories it starred.
- `cursor` (string): Where the page starts: a previous page's cursor.
- `filter` (string): Whose doings: `everyone`'s, or with `following`, those of the account asking and whom it follows, which needs an account to ask.
  - Constraints: default: "everyone", knownValues: everyone | following
- `kind` (string): Only what is of this kind: refs pushed and deleted, pulls or issues opened and moved between states, comments, repositories starred, repositories created and forked but gists, or gists created and forked. A kind the appview does not know answers nothing.
  - Constraints: knownValues: pushes | pulls | issues | comments | stars | repos | gists
- `limit` (integer)
  - Constraints: minimum: 1, maximum: 100, default: 40

### Output (application/json)

- `cursor` (string): Where the next page starts, when there may be one.
- `events` (array, required)
  - `items` (ref)
    - Reference: `#eventView`

## #actorView (`dev.knotless.getFeed#actorView`)

Type: object

### Properties

- `avatar` (string · uri): The account's picture, as in dev.knotless.getProfile#profileView.
- `bot` (boolean): Whether its knotless profile says it is a bot, as in dev.knotless.defs#actorView.
- `did` (string · did, required)
- `handle` (string, required): The handle the account claims, when it resolves back to it; else the DID.

## #changed (`dev.knotless.getFeed#changed`)

Type: object

A pull or an issue moved to another state.

### Properties

- `state` (string, required)
  - Constraints: knownValues: open | closed | merged
- `subject` (string · at-uri, required)
- `subjectState` (string): Where the subject stands now, whoever moved it there.
  - Constraints: knownValues: open | closed | merged
- `title` (string, required): The subject's title.

## #commented (`dev.knotless.getFeed#commented`)

Type: object

A comment or review on a pull or an issue, or a comment on a gist.

### Properties

- `subject` (string · at-uri, required): The pull or issue, or the gist's own dev.knotless.repo record.
- `subjectState` (string): Where the subject stands now, whoever moved it there.
  - Constraints: knownValues: open | closed | merged
- `text` (string, required): The comment, as Markdown.
- `title` (string, required): The subject's title: for a gist, its description, else its name.
- `verdict` (string)
  - Constraints: knownValues: approve | changes

## #commitView (`dev.knotless.getFeed#commitView`)

Type: object

### Properties

- `merge` (boolean): Whether the commit has more than one parent. Absent when not.
- `message` (string, required)
- `sha` (string, required)

## #created (`dev.knotless.getFeed#created`)

Type: object

A repository or a gist created, or forked from another.

### Properties

- `description` (string)
  - Constraints: maxLength: 3000, maxGraphemes: 300
- `forkOf` (ref)
  - Reference: `#repoView`
- `kind` (string): gist for a gist, a repository whose record says it is one. Absent for any other repository.
  - Constraints: knownValues: gist

## #deleted (`dev.knotless.getFeed#deleted`)

Type: object

A ref deleted.

### Properties

- `ref` (string, required)

## #eventView (`dev.knotless.getFeed#eventView`)

Type: object

Something an account did to a repository.

### Properties

- `action` (union, required)
  - One of: `#created`, `#pushed`, `#deleted`, `#opened`, `#commented`, `#changed`, `#starred`
- `actor` (ref, required)
  - Reference: `#actorView`
- `createdAt` (string · datetime, required): When the record saying so was made.
- `repo` (ref, required)
  - Reference: `#repoView`

## #opened (`dev.knotless.getFeed#opened`)

Type: object

A pull or an issue opened.

### Properties

- `subject` (string · at-uri, required): The dev.knotless.pull or dev.knotless.issue record.
- `subjectState` (string): Where the subject stands now, whoever moved it there.
  - Constraints: knownValues: open | closed | merged
- `title` (string, required)

## #pushed (`dev.knotless.getFeed#pushed`)

Type: object

A ref created or moved, or moved again and again by one account, each move within an hour of the last, as one. A new ref brings what the repository's default branch did not reach just before, nor its fork source's; a fork's copies of its source's refs are not events.

### Properties

- `commits` (array, required): The newest of the new ones, newest first.
  - Constraints: maxLength: 10
  - `items` (ref)
    - Reference: `#commitView`
- `count` (integer, required): Commits the push brought; 100 means at least that many. A forced push's leave out those it brought again: the same author, at the same time, with the same message as a commit it left behind.
  - Constraints: minimum: 0, maximum: 100
- `created` (boolean, required): Whether the ref was new.
- `forced` (boolean): Whether the ref moved to where it no longer reaches some of what it did, as a rebase or a rewrite does. Absent when not.
- `new` (integer, required): Of those, the commits no other ref of the repository had before, and no event before it on the same page lists; the rest are only counted.
  - Constraints: minimum: 0, maximum: 100
- `ref` (string, required): The full ref name, such as refs/heads/main.
- `to` (string): The commit the ref was left at, in hex: what the push brought, which a page can link to after the ref is gone.

## #repoView (`dev.knotless.getFeed#repoView`)

Type: object

A repository, under the name it has now.

### Properties

- `did` (string · did, required): The repository's owner.
- `handle` (string, required): The owner's handle, as in #actorView.
- `name` (string, required)
  - Constraints: maxLength: 100

## #starred (`dev.knotless.getFeed#starred`)

Type: object

The event's repository starred.

### Properties

- `subject` (string · at-uri): The dev.knotless.repo record starred.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "actorView": {
      "properties": {
        "avatar": {
          "description": "The account's picture, as in dev.knotless.getProfile#profileView.",
          "format": "uri",
          "type": "string"
        },
        "bot": {
          "description": "Whether its knotless profile says it is a bot, as in dev.knotless.defs#actorView.",
          "type": "boolean"
        },
        "did": {
          "format": "did",
          "type": "string"
        },
        "handle": {
          "description": "The handle the account claims, when it resolves back to it; else the DID.",
          "type": "string"
        }
      },
      "required": [
        "did",
        "handle"
      ],
      "type": "object"
    },
    "changed": {
      "description": "A pull or an issue moved to another state.",
      "properties": {
        "state": {
          "knownValues": [
            "open",
            "closed",
            "merged"
          ],
          "type": "string"
        },
        "subject": {
          "format": "at-uri",
          "type": "string"
        },
        "subjectState": {
          "description": "Where the subject stands now, whoever moved it there.",
          "knownValues": [
            "open",
            "closed",
            "merged"
          ],
          "type": "string"
        },
        "title": {
          "description": "The subject's title.",
          "type": "string"
        }
      },
      "required": [
        "subject",
        "title",
        "state"
      ],
      "type": "object"
    },
    "commented": {
      "description": "A comment or review on a pull or an issue, or a comment on a gist.",
      "properties": {
        "subject": {
          "description": "The pull or issue, or the gist's own dev.knotless.repo record.",
          "format": "at-uri",
          "type": "string"
        },
        "subjectState": {
          "description": "Where the subject stands now, whoever moved it there.",
          "knownValues": [
            "open",
            "closed",
            "merged"
          ],
          "type": "string"
        },
        "text": {
          "description": "The comment, as Markdown.",
          "type": "string"
        },
        "title": {
          "description": "The subject's title: for a gist, its description, else its name.",
          "type": "string"
        },
        "verdict": {
          "knownValues": [
            "approve",
            "changes"
          ],
          "type": "string"
        }
      },
      "required": [
        "subject",
        "title",
        "text"
      ],
      "type": "object"
    },
    "commitView": {
      "properties": {
        "merge": {
          "description": "Whether the commit has more than one parent. Absent when not.",
          "type": "boolean"
        },
        "message": {
          "type": "string"
        },
        "sha": {
          "type": "string"
        }
      },
      "required": [
        "sha",
        "message"
      ],
      "type": "object"
    },
    "created": {
      "description": "A repository or a gist created, or forked from another.",
      "properties": {
        "description": {
          "maxGraphemes": 300,
          "maxLength": 3000,
          "type": "string"
        },
        "forkOf": {
          "ref": "#repoView",
          "type": "ref"
        },
        "kind": {
          "description": "gist for a gist, a repository whose record says it is one. Absent for any other repository.",
          "knownValues": [
            "gist"
          ],
          "type": "string"
        }
      },
      "type": "object"
    },
    "deleted": {
      "description": "A ref deleted.",
      "properties": {
        "ref": {
          "type": "string"
        }
      },
      "required": [
        "ref"
      ],
      "type": "object"
    },
    "eventView": {
      "description": "Something an account did to a repository.",
      "properties": {
        "action": {
          "refs": [
            "#created",
            "#pushed",
            "#deleted",
            "#opened",
            "#commented",
            "#changed",
            "#starred"
          ],
          "type": "union"
        },
        "actor": {
          "ref": "#actorView",
          "type": "ref"
        },
        "createdAt": {
          "description": "When the record saying so was made.",
          "format": "datetime",
          "type": "string"
        },
        "repo": {
          "ref": "#repoView",
          "type": "ref"
        }
      },
      "required": [
        "createdAt",
        "actor",
        "repo",
        "action"
      ],
      "type": "object"
    },
    "main": {
      "description": "What happened on the public repositories an appview has indexed, newest first: repositories created and forked, refs pushed and deleted, pulls and issues opened, discussed and moved between states, and repositories starred. With filter `following`, what the account asking and those it follows did, and anything done on its repositories and those it starred; without, the same for anyone, but no stars. Without `actor`, what a repository's bots said or pushed on it is left out: the runners and triagers its record names, but its owner and collaborators. A pull a runner merged landing the merge queue is shown as merged by whoever queued it. Optional authentication: asked as an account, with a service token or the pages' session cookie, what happened on the private repositories it may read too, its own and those it was proven a member of, as the server's index of their spaces has it, whoever did it, whom it follows or not; and the answer is that account's alone.",
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "cursor": {
              "description": "Where the next page starts, when there may be one.",
              "type": "string"
            },
            "events": {
              "items": {
                "ref": "#eventView",
                "type": "ref"
              },
              "type": "array"
            }
          },
          "required": [
            "events"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "actor": {
            "description": "Only what this account did: the repositories it created, the refs it pushed, the pulls, issues, comments and changes of state it wrote, and the repositories it starred.",
            "format": "did",
            "type": "string"
          },
          "cursor": {
            "description": "Where the page starts: a previous page's cursor.",
            "type": "string"
          },
          "filter": {
            "default": "everyone",
            "description": "Whose doings: `everyone`'s, or with `following`, those of the account asking and whom it follows, which needs an account to ask.",
            "knownValues": [
              "everyone",
              "following"
            ],
            "type": "string"
          },
          "kind": {
            "description": "Only what is of this kind: refs pushed and deleted, pulls or issues opened and moved between states, comments, repositories starred, repositories created and forked but gists, or gists created and forked. A kind the appview does not know answers nothing.",
            "knownValues": [
              "pushes",
              "pulls",
              "issues",
              "comments",
              "stars",
              "repos",
              "gists"
            ],
            "type": "string"
          },
          "limit": {
            "default": 40,
            "maximum": 100,
            "minimum": 1,
            "type": "integer"
          }
        },
        "type": "params"
      },
      "type": "query"
    },
    "opened": {
      "description": "A pull or an issue opened.",
      "properties": {
        "subject": {
          "description": "The dev.knotless.pull or dev.knotless.issue record.",
          "format": "at-uri",
          "type": "string"
        },
        "subjectState": {
          "description": "Where the subject stands now, whoever moved it there.",
          "knownValues": [
            "open",
            "closed",
            "merged"
          ],
          "type": "string"
        },
        "title": {
          "type": "string"
        }
      },
      "required": [
        "subject",
        "title"
      ],
      "type": "object"
    },
    "pushed": {
      "description": "A ref created or moved, or moved again and again by one account, each move within an hour of the last, as one. A new ref brings what the repository's default branch did not reach just before, nor its fork source's; a fork's copies of its source's refs are not events.",
      "properties": {
        "commits": {
          "description": "The newest of the new ones, newest first.",
          "items": {
            "ref": "#commitView",
            "type": "ref"
          },
          "maxLength": 10,
          "type": "array"
        },
        "count": {
          "description": "Commits the push brought; 100 means at least that many. A forced push's leave out those it brought again: the same author, at the same time, with the same message as a commit it left behind.",
          "maximum": 100,
          "minimum": 0,
          "type": "integer"
        },
        "created": {
          "description": "Whether the ref was new.",
          "type": "boolean"
        },
        "forced": {
          "description": "Whether the ref moved to where it no longer reaches some of what it did, as a rebase or a rewrite does. Absent when not.",
          "type": "boolean"
        },
        "new": {
          "description": "Of those, the commits no other ref of the repository had before, and no event before it on the same page lists; the rest are only counted.",
          "maximum": 100,
          "minimum": 0,
          "type": "integer"
        },
        "ref": {
          "description": "The full ref name, such as refs/heads/main.",
          "type": "string"
        },
        "to": {
          "description": "The commit the ref was left at, in hex: what the push brought, which a page can link to after the ref is gone.",
          "type": "string"
        }
      },
      "required": [
        "ref",
        "created",
        "count",
        "new",
        "commits"
      ],
      "type": "object"
    },
    "repoView": {
      "description": "A repository, under the name it has now.",
      "properties": {
        "did": {
          "description": "The repository's owner.",
          "format": "did",
          "type": "string"
        },
        "handle": {
          "description": "The owner's handle, as in #actorView.",
          "type": "string"
        },
        "name": {
          "maxLength": 100,
          "type": "string"
        }
      },
      "required": [
        "did",
        "handle",
        "name"
      ],
      "type": "object"
    },
    "starred": {
      "description": "The event's repository starred.",
      "properties": {
        "subject": {
          "description": "The dev.knotless.repo record starred.",
          "format": "at-uri",
          "type": "string"
        }
      },
      "type": "object"
    }
  },
  "description": "What happened on the public repositories an appview has indexed, and on the private ones the account asking may read, newest first.",
  "id": "dev.knotless.getFeed",
  "lexicon": 1
}
```
