Notifications
Those endpoints allow you to manage the notifications received and read.
Endpoints
- get /api/v3/notification/notifications
- post /api/v3/notification/notifications
- patch /api/v3/notification/notifications/:id/read
- get /api/v3/notification/notifications/:resource_id
- patch /api/v3/notification/notifications/check_expired
- get /api/v3/notification/notifications/read_all
- get /api/v3/notification/notifications/unread_count
- get /api/v3/notification/notifications/unread_summary
get/api/v3/notification/notifications
Return a paginated list of notification/notifications
Input Schema
object
page?:
object
The page number, default to 1
number?: integer
The number of items per page, default to 1000
size?: integer
The sort order, comma separated list of fields. See sorting section for more details
sort?: string
Set to true to return the total number of items in the collection
count?: boolean
filter?:
object
id?: unknown
account_id?: unknown
link?: unknown
resource?: unknown
status?: unknown
category?: unknown
title?: unknown
icon?: unknown
content?: unknown
enable_actions?: unknown
actions?: unknown
created_by_id?: unknown
read_at?: unknown
created_at?: unknown
expires_at?: unknown
The fields to include in the response.
The key is the resource type and the value is an array of fields.
fields?: The key is the resource type and the value is an array of fields.
dictionary
Values: array
Typescript
type InputSchema = {
page?: {
// The page number, default to 1
number?: number;
// The number of items per page, default to 1000
size?: number;
};
// The sort order, comma separated list of fields. See sorting section for more details
sort?: string;
// Set to true to return the total number of items in the collection
count?: boolean;
filter?: {
id?: any;
account_id?: any;
link?: any;
resource?: any;
status?: any;
category?: any;
title?: any;
icon?: any;
content?: any;
enable_actions?: any;
actions?: any;
created_by_id?: any;
read_at?: any;
created_at?: any;
expires_at?: any;
};
// The fields to include in the response.
// The key is the resource type and the value is an array of fields.
fields?: { [key: string]: Array<any> };
};
Output Schema
object
data:
array
Elements:
object
type: string
id?: string
attributes?:
object
id?: integer
account_id?: integer
link?: string
resource?: string
status?: string
category?: string
title?: string
icon?: string
content?: string
enable_actions?: boolean
actions?: array
created_by_id?: integer
read_at?: datetime
created_at?: datetime
expires_at?: datetime
relationships?: open struct
included?:
array
Elements: open struct
Typescript
type OutputSchema = {
data: Array<{
type: string;
id?: string;
attributes?: {
id?: number;
account_id?: number;
link?: string;
resource?: string;
status?: string;
category?: string;
title?: string;
icon?: string;
content?: string;
enable_actions?: boolean;
actions?: Array<any>;
created_by_id?: number;
read_at?: Date;
created_at?: Date;
expires_at?: Date;
};
relationships?: Record<string, any>;
}>;
included?: Array<Record<string, any>>;
};
post/api/v3/notification/notifications
Create a new notification/notifications
Input Schema
object
data:
object
type: string
attributes:
object
id?: integer
account_id?: integer
link?: string
resource?: string
status?: string
category?: string
title?: string
icon?: string
content?: string
enable_actions?: boolean
actions?: array
created_by_id?: integer
read_at?: datetime
created_at?: datetime
expires_at?: datetime
Typescript
type InputSchema = {
data: {
type: string;
attributes: {
id?: number;
account_id?: number;
link?: string;
resource?: string;
status?: string;
category?: string;
title?: string;
icon?: string;
content?: string;
enable_actions?: boolean;
actions?: Array<any>;
created_by_id?: number;
read_at?: Date;
created_at?: Date;
expires_at?: Date;
};
};
};
patch/api/v3/notification/notifications/:id/read
Mark a notification as read.
Input Schema
object
id: integer
Typescript
type InputSchema = { id: number };
Output Schema
object
data:
object
type: string
id?: string
attributes?:
object
id?: integer
account_id?: integer
link?: string
resource?: string
status?: string
category?: string
title?: string
icon?: string
content?: string
enable_actions?: boolean
actions?: array
created_by_id?: integer
read_at?: datetime
created_at?: datetime
expires_at?: datetime
relationships?: open struct
included?:
array
Elements: open struct
Typescript
type OutputSchema = {
data: {
type: string;
id?: string;
attributes?: {
id?: number;
account_id?: number;
link?: string;
resource?: string;
status?: string;
category?: string;
title?: string;
icon?: string;
content?: string;
enable_actions?: boolean;
actions?: Array<any>;
created_by_id?: number;
read_at?: Date;
created_at?: Date;
expires_at?: Date;
};
relationships?: Record<string, any>;
};
included?: Array<Record<string, any>>;
};
get/api/v3/notification/notifications/:resource_id
Show a specific notification/notifications
Input Schema
object
resource_id: integer
included?:
array
Elements: string
fields?:
dictionary
Values: array
Typescript
type InputSchema = {
resource_id: number;
included?: Array<string>;
fields?: { [key: string]: Array<any> };
};
Output Schema
object
data:
object
type: string
id?: string
attributes?:
object
id?: integer
account_id?: integer
link?: string
resource?: string
status?: string
category?: string
title?: string
icon?: string
content?: string
enable_actions?: boolean
actions?: array
created_by_id?: integer
read_at?: datetime
created_at?: datetime
expires_at?: datetime
relationships?: open struct
included?:
array
Elements: open struct
Typescript
type OutputSchema = {
data: {
type: string;
id?: string;
attributes?: {
id?: number;
account_id?: number;
link?: string;
resource?: string;
status?: string;
category?: string;
title?: string;
icon?: string;
content?: string;
enable_actions?: boolean;
actions?: Array<any>;
created_by_id?: number;
read_at?: Date;
created_at?: Date;
expires_at?: Date;
};
relationships?: Record<string, any>;
};
included?: Array<Record<string, any>>;
};
patch/api/v3/notification/notifications/check_expired
get/api/v3/notification/notifications/read_all
get/api/v3/notification/notifications/unread_count
Returns the number of unread notifications for the current user.
Output Schema
object
unread_count: integer
Typescript
type OutputSchema = { unread_count: number };
get/api/v3/notification/notifications/unread_summary
Returns the number of unread notifications for the current user.
Output Schema
object
unread_summary:
dictionary
Values: integer
Typescript
type OutputSchema = { unread_summary: { [key: string]: number } };