openvibe-sdk/notifications
Generated at from
openvibe-contracts v0.131.0 and
openvibe-sdk v0.41.0.
From types/notifications.d.ts (server only). Declarations are shown verbatim.
interface NotificationFields
network.notification-push-request@1 fields, minus the recipient (push() resolves it).
export interface NotificationFields {
type?: string;
title?: string;
message?: string | null;
url?: string;
category?: 'service' | 'social' | 'system' | string;
priority?: 'low' | 'normal' | 'high' | 'critical' | string;
icon?: string;
rich_content?: Record<string, unknown>;
service?: string;
[field: string]: unknown;
}type PushInput
export type PushInput = ({ subjectId: string; userId?: undefined } | { userId: number | string; subjectId?: undefined }) & NotificationFields;type PushResult
export type PushResult = { sent: true; skipped: boolean } | { sent: false; reason: 'unknown_subject' };interface NotificationsClient
export interface NotificationsClient {
push(input: PushInput): Promise<PushResult>;
}function createNotificationsClient
export declare function createNotificationsClient(client: OpenVibeClient, opts?: { baseUrl?: string }): NotificationsClient;