From 7c80bcdb92b3327fc1efa8a72454204e0dd45f42 Mon Sep 17 00:00:00 2001 From: Rafael Gutkowski Date: Sat, 21 Dec 2024 04:54:23 +0700 Subject: [PATCH] Add `GET frame/notification_tokens` [NEYN-3953] (#269) --- src/v2/spec.yaml | 78 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 77 insertions(+), 1 deletion(-) diff --git a/src/v2/spec.yaml b/src/v2/spec.yaml index 697d5fe..639d624 100644 --- a/src/v2/spec.yaml +++ b/src/v2/spec.yaml @@ -1,7 +1,7 @@ openapi: 3.1.0 info: title: Farcaster API V2 - version: "2.5.0" + version: "2.6.0" description: > The Farcaster API allows you to interact with the Farcaster protocol. See the [Neynar docs](https://docs.neynar.com/reference) for more details. @@ -2176,6 +2176,40 @@ components: $ref: "#/components/schemas/CastWithInteractions" next: $ref: "#/components/schemas/NextCursor" + FrameNotificationTokens: + type: object + required: + - notification_tokens + - next + properties: + notification_tokens: + type: array + items: + type: object + properties: + object: + type: string + enum: + - notification_token + url: + type: string + token: + type: string + status: + type: string + enum: + - enabled + - disabled + fid: + $ref: "#/components/schemas/Fid" + created_at: + type: string + format: date-time + updated_at: + type: string + format: date-time + next: + $ref: "#/components/schemas/NextCursor" ConversationSummary: type: object required: @@ -6806,6 +6840,48 @@ paths: $ref: "#/components/responses/400Response" "500": $ref: "#/components/responses/500Response" + /farcaster/frame/notification_tokens: + get: + tags: + - Frame + summary: | + List of frame notification tokens. + description: | + Returns a list of notifications tokens related for an app + externalDocs: + url: https://docs.neynar.com/reference/fetch-notification-tokens + operationId: fetch-notification-tokens + parameters: + - name: limit + in: query + description: Number of results to fetch + required: false + example: 30 + schema: + type: integer + default: 20 + minimum: 1 + maximum: 100 + x-is-limit-param: true + - name: fids + description: Comma separated list of FIDs, up to 100 at a time + in: query + required: false + example: 194, 191, 6131 + schema: + type: string + x-comma-separated: true + x-accept-as: integer + responses: + "200": + description: Successful operation. + content: + application/json: + schema: + $ref: "#/components/schemas/FrameNotificationTokens" + "400": + $ref: "#/components/responses/400Response" + /farcaster/frame/notifications: post: tags: