Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .changeset/stupid-feet-allow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
"@atproto/ozone": patch
"@atproto/bsky": patch
"@atproto/api": patch
"@atproto/pds": patch
---

Add optional reasons param to listNotifications
8 changes: 8 additions & 0 deletions lexicons/app/bsky/notification/listNotifications.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@
"parameters": {
"type": "params",
"properties": {
"reasons": {
"description": "Notification reasons to include in response.",
"type": "array",
"items": {
"type": "string",
"description": "A reason that matches the reason property of #notification."
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We originally had a knownValues here, but it was screwing up some types in the route handler and I just didn't think it was a great use of time to debug. This also prevents us from having to duplicate every new reason in 2 locations.

}
},
"limit": {
"type": "integer",
"minimum": 1,
Expand Down
9 changes: 9 additions & 0 deletions packages/api/src/client/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8944,6 +8944,15 @@ export const schemaDict = {
parameters: {
type: 'params',
properties: {
reasons: {
description: 'Notification reasons to include in response.',
type: 'array',
items: {
type: 'string',
description:
'A reason that matches the reason property of #notification.',
},
},
limit: {
type: 'integer',
minimum: 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import * as AppBskyActorDefs from '../actor/defs'
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs'

export interface QueryParams {
/** Notification reasons to include in response. */
reasons?: string[]
limit?: number
priority?: boolean
cursor?: string
Expand Down
9 changes: 9 additions & 0 deletions packages/bsky/src/lexicon/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8944,6 +8944,15 @@ export const schemaDict = {
parameters: {
type: 'params',
properties: {
reasons: {
description: 'Notification reasons to include in response.',
type: 'array',
items: {
type: 'string',
description:
'A reason that matches the reason property of #notification.',
},
},
limit: {
type: 'integer',
minimum: 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import * as AppBskyActorDefs from '../actor/defs'
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs'

export interface QueryParams {
/** Notification reasons to include in response. */
reasons?: string[]
limit: number
priority?: boolean
cursor?: string
Expand Down
9 changes: 9 additions & 0 deletions packages/ozone/src/lexicon/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8944,6 +8944,15 @@ export const schemaDict = {
parameters: {
type: 'params',
properties: {
reasons: {
description: 'Notification reasons to include in response.',
type: 'array',
items: {
type: 'string',
description:
'A reason that matches the reason property of #notification.',
},
},
limit: {
type: 'integer',
minimum: 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import * as AppBskyActorDefs from '../actor/defs'
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs'

export interface QueryParams {
/** Notification reasons to include in response. */
reasons?: string[]
limit: number
priority?: boolean
cursor?: string
Expand Down
9 changes: 9 additions & 0 deletions packages/pds/src/lexicon/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8944,6 +8944,15 @@ export const schemaDict = {
parameters: {
type: 'params',
properties: {
reasons: {
description: 'Notification reasons to include in response.',
type: 'array',
items: {
type: 'string',
description:
'A reason that matches the reason property of #notification.',
},
},
limit: {
type: 'integer',
minimum: 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import * as AppBskyActorDefs from '../actor/defs'
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs'

export interface QueryParams {
/** Notification reasons to include in response. */
reasons?: string[]
limit: number
priority?: boolean
cursor?: string
Expand Down