UNPKG

textiot

Version:

A framework for building web and native (IoT) Dapps on the IPFS network

29 lines (28 loc) 810 B
import { API } from '../core/api'; import { NotificationList } from '../models'; /** * Notifications is an API module for managing notifications * * Notifications are generated by thread and account activity. * * @extends API */ export default class Notifications extends API { /** * Retrieves all notifications generated by thread and account activity * @returns An array of Notification objects */ list(): Promise<NotificationList>; /** * Marks a notifiction as read by ID * * @param id ID of the target notification * @returns Whether the operation was successful */ read(id: string): Promise<boolean>; /** * Marks all notifictions as read * @returns Whether the operation was successful */ readAll(): Promise<boolean>; }