Skip to content

PATCH   /notifications

Mark notification(s) as read/unread

Update the read status of one or multiple notifications

Authentication Required

Authorization: Bearer {token}   header string

This header is required to access this endpoint

Required Parameters

x-account-id   header string

Account ID for the request

Request Body

{}

Try it out

Loading...

Output:

Responses

Description

Notification(s) updated successfully

{
"id": 0,
"event": "string",
"user": "string",
"account_id": "string",
"data": {},
"notificationSubject": "string",
"notificationBody": "string",
"portalLink": "string",
"portalLinkDescription": "string",
"error": false,
"markedRead": false,
"created": "string"
}

References

#/components/parameters/xAccountIdHeader

in: header
name: x-account-id
schema:
type: string
description: Account ID for the request
required: true
example: "2311"

#/components/schemas/Notification

type: object
properties:
id:
type: integer
description: Unique notification ID
event:
type: string
description: Event type
user:
type: string
description: User email associated with this notification
account_id:
type: string
description: Account ID
data:
type: object
description: Additional event data
notificationSubject:
type: string
description: Notification subject line
notificationBody:
type: string
description: Notification message body
portalLink:
type: string
description: A Link to the frontend portal to view the event data
portalLinkDescription:
type: string
description: Human readable text to be used in the link tag for the portalLink
error:
type: boolean
description: Whether this is an error notification
markedRead:
type: boolean
description: Whether this notification has been marked as read
created:
type: string
format: date-time
description: When the notification was created

#/components/schemas/Error

type: object
properties:
error:
type: string
description: Error message
status:
type: integer
description: HTTP status code
message:
type: string
description: Detailed error message
description: Error response object
required:
- error

Route Source Code

Check out the source code for this route entrypoint here: /notifications/route.ts

Or the swagger.yaml spec this documentation was generated from: /notifications/swagger.yaml