@dereekb/firebase 13.2.2 → 13.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs.js +12893 -4062
- package/index.esm.js +12872 -4065
- package/package.json +5 -5
- package/src/lib/client/error/error.d.ts +18 -3
- package/src/lib/client/firestore/array.d.ts +16 -3
- package/src/lib/client/firestore/driver.accessor.batch.d.ts +35 -4
- package/src/lib/client/firestore/driver.accessor.create.d.ts +15 -0
- package/src/lib/client/firestore/driver.accessor.d.ts +15 -0
- package/src/lib/client/firestore/driver.accessor.default.d.ts +32 -0
- package/src/lib/client/firestore/driver.accessor.transaction.d.ts +35 -4
- package/src/lib/client/firestore/driver.d.ts +16 -0
- package/src/lib/client/firestore/driver.query.d.ts +36 -0
- package/src/lib/client/firestore/firestore.d.ts +11 -1
- package/src/lib/client/firestore/increment.d.ts +12 -3
- package/src/lib/client/function/development.function.factory.d.ts +27 -2
- package/src/lib/client/function/error.d.ts +27 -0
- package/src/lib/client/function/function.callable.d.ts +50 -5
- package/src/lib/client/function/function.factory.d.ts +70 -4
- package/src/lib/client/function/model.function.factory.d.ts +64 -9
- package/src/lib/client/storage/driver.accessor.d.ts +93 -0
- package/src/lib/client/storage/driver.d.ts +15 -0
- package/src/lib/client/storage/storage.d.ts +10 -1
- package/src/lib/common/auth/auth.context.d.ts +17 -2
- package/src/lib/common/auth/auth.d.ts +38 -9
- package/src/lib/common/auth/auth.error.d.ts +25 -0
- package/src/lib/common/auth/auth.server.error.d.ts +6 -2
- package/src/lib/common/development/function.d.ts +17 -6
- package/src/lib/common/development/function.schedule.d.ts +30 -1
- package/src/lib/common/firestore/accessor/accessor.wrap.modify.d.ts +36 -12
- package/src/lib/common/firestore/accessor/array.d.ts +14 -4
- package/src/lib/common/firestore/accessor/document.d.ts +77 -2
- package/src/lib/common/firestore/accessor/increment.d.ts +15 -3
- package/src/lib/common/firestore/collection/collection.d.ts +22 -4
- package/src/lib/common/firestore/collection/collection.util.d.ts +12 -2
- package/src/lib/common/firestore/driver/accessor.d.ts +28 -1
- package/src/lib/common/firestore/driver/batch.d.ts +6 -4
- package/src/lib/common/firestore/driver/driver.d.ts +18 -1
- package/src/lib/common/firestore/driver/query.d.ts +20 -1
- package/src/lib/common/firestore/driver/query.handler.d.ts +23 -0
- package/src/lib/common/firestore/driver/transaction.d.ts +18 -6
- package/src/lib/common/firestore/error.d.ts +16 -4
- package/src/lib/common/firestore/query/iterator.d.ts +11 -0
- package/src/lib/common/firestore/reference.d.ts +11 -6
- package/src/lib/common/firestore/snapshot/snapshot.d.ts +4 -0
- package/src/lib/common/firestore/snapshot/snapshot.field.d.ts +263 -63
- package/src/lib/common/firestore/types.d.ts +39 -1
- package/src/lib/common/firestore/util/id.batch.d.ts +55 -3
- package/src/lib/common/function/action.d.ts +35 -0
- package/src/lib/common/model/context.d.ts +11 -1
- package/src/lib/common/model/function.d.ts +45 -9
- package/src/lib/common/model/model/model.loader.d.ts +37 -0
- package/src/lib/common/model/model/model.param.d.ts +24 -2
- package/src/lib/common/model/model.service.d.ts +126 -4
- package/src/lib/common/model/permission/permission.context.d.ts +15 -0
- package/src/lib/common/model/permission/permission.d.ts +16 -0
- package/src/lib/common/model/permission/permission.service.d.ts +24 -1
- package/src/lib/common/model/permission/permission.service.grant.d.ts +72 -28
- package/src/lib/common/model/permission/permission.service.role.d.ts +15 -0
- package/src/lib/common/storage/accessor/path.model.d.ts +25 -8
- package/src/lib/common/storage/context.d.ts +23 -6
- package/src/lib/common/storage/driver/accessor.d.ts +15 -4
- package/src/lib/common/storage/driver/accessor.iterate.d.ts +31 -8
- package/src/lib/common/storage/driver/accessor.util.d.ts +13 -6
- package/src/lib/common/storage/driver/driver.d.ts +10 -1
- package/src/lib/common/storage/driver/error.d.ts +16 -0
- package/src/lib/common/storage/driver/list.d.ts +30 -0
- package/src/lib/common/storage/storage.d.ts +76 -19
- package/src/lib/common/storage/types.d.ts +23 -5
- package/src/lib/model/index.d.ts +1 -0
- package/src/lib/model/notification/notification.action.d.ts +8 -0
- package/src/lib/model/notification/notification.api.d.ts +26 -0
- package/src/lib/model/notification/notification.api.error.d.ts +15 -0
- package/src/lib/model/notification/notification.api.util.d.ts +27 -12
- package/src/lib/model/notification/notification.config.d.ts +193 -64
- package/src/lib/model/notification/notification.create.d.ts +62 -13
- package/src/lib/model/notification/notification.create.task.d.ts +25 -4
- package/src/lib/model/notification/notification.d.ts +258 -99
- package/src/lib/model/notification/notification.details.d.ts +66 -18
- package/src/lib/model/notification/notification.id.d.ts +90 -12
- package/src/lib/model/notification/notification.item.d.ts +57 -16
- package/src/lib/model/notification/notification.message.d.ts +84 -18
- package/src/lib/model/notification/notification.query.d.ts +21 -24
- package/src/lib/model/notification/notification.send.d.ts +38 -5
- package/src/lib/model/notification/notification.task.d.ts +87 -16
- package/src/lib/model/notification/notification.task.subtask.d.ts +42 -13
- package/src/lib/model/notification/notification.util.d.ts +68 -18
- package/src/lib/model/oidcmodel/index.d.ts +8 -0
- package/src/lib/model/oidcmodel/oidcmodel.action.d.ts +37 -0
- package/src/lib/model/oidcmodel/oidcmodel.api.d.ts +131 -0
- package/src/lib/model/oidcmodel/oidcmodel.d.ts +114 -0
- package/src/lib/model/oidcmodel/oidcmodel.data.d.ts +17 -0
- package/src/lib/model/oidcmodel/oidcmodel.id.d.ts +18 -0
- package/src/lib/model/oidcmodel/oidcmodel.interaction.d.ts +40 -0
- package/src/lib/model/oidcmodel/oidcmodel.interaction.oauth.d.ts +73 -0
- package/src/lib/model/oidcmodel/oidcmodel.query.d.ts +21 -0
- package/src/lib/model/storagefile/storagefile.action.d.ts +47 -0
- package/src/lib/model/storagefile/storagefile.api.d.ts +54 -4
- package/src/lib/model/storagefile/storagefile.create.d.ts +40 -3
- package/src/lib/model/storagefile/storagefile.d.ts +153 -16
- package/src/lib/model/storagefile/storagefile.file.d.ts +22 -7
- package/src/lib/model/storagefile/storagefile.group.d.ts +30 -1
- package/src/lib/model/storagefile/storagefile.group.processing.d.ts +20 -2
- package/src/lib/model/storagefile/storagefile.id.d.ts +44 -5
- package/src/lib/model/storagefile/storagefile.permission.d.ts +23 -4
- package/src/lib/model/storagefile/storagefile.query.d.ts +63 -11
- package/src/lib/model/storagefile/storagefile.task.d.ts +47 -4
- package/src/lib/model/storagefile/storagefile.upload.claims.d.ts +21 -4
- package/src/lib/model/storagefile/storagefile.upload.d.ts +41 -9
- package/src/lib/model/storagefile/storagefile.upload.determiner.d.ts +112 -20
- package/src/lib/model/storagefile/storagefile.util.d.ts +66 -3
- package/src/lib/model/system/system.action.d.ts +25 -0
- package/src/lib/model/system/system.d.ts +80 -4
- package/src/lib/model/user.d.ts +8 -2
- package/test/index.cjs.js +11168 -3295
- package/test/index.esm.js +11176 -3303
- package/test/package.json +6 -6
- package/test/src/lib/client/firebase.authorized.d.ts +18 -0
- package/test/src/lib/client/firebase.d.ts +60 -0
- package/test/src/lib/common/firebase.instance.d.ts +21 -0
- package/test/src/lib/common/firestore/firestore.d.ts +40 -0
- package/test/src/lib/common/firestore/firestore.instance.d.ts +16 -0
- package/test/src/lib/common/firestore/test.driver.accessor.d.ts +39 -2
- package/test/src/lib/common/firestore/test.driver.utility.d.ts +8 -2
- package/test/src/lib/common/firestore/test.iterator.d.ts +7 -2
- package/test/src/lib/common/mock/mock.item.collection.fixture.d.ts +29 -1
- package/test/src/lib/common/mock/mock.item.d.ts +219 -5
- package/test/src/lib/common/mock/mock.item.id.d.ts +6 -0
- package/test/src/lib/common/mock/mock.item.query.d.ts +12 -0
- package/test/src/lib/common/mock/mock.item.service.d.ts +60 -0
- package/test/src/lib/common/mock/mock.item.storage.fixture.d.ts +28 -1
- package/test/src/lib/common/storage/storage.d.ts +30 -0
- package/test/src/lib/common/storage/storage.instance.d.ts +22 -0
- package/test/src/lib/common/storage/test.driver.accessor.d.ts +7 -2
- package/index.cjs.js.map +0 -1
- package/index.esm.js.map +0 -1
|
@@ -1,170 +1,258 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module notification.config
|
|
3
|
+
*
|
|
4
|
+
* Notification recipient configuration types and the bitwise encoding system for per-template channel preferences.
|
|
5
|
+
*
|
|
6
|
+
* Configuration follows a 3-level hierarchy (highest priority first):
|
|
7
|
+
* 1. {@link NotificationUser.gc} — Global config override (applies at send time, not synced to boxes)
|
|
8
|
+
* 2. {@link NotificationUserNotificationBoxRecipientConfig} — Per-box config on the user (synced to boxes)
|
|
9
|
+
* 3. {@link NotificationBoxRecipientTemplateConfig} — Template defaults from the system configuration
|
|
10
|
+
*
|
|
11
|
+
* Each level can enable/disable delivery per channel (email, text, push, summary) per template type.
|
|
12
|
+
* Configs are stored efficiently using bitwise encoding via {@link EncodedNotificationBoxRecipientTemplateConfig}.
|
|
13
|
+
*/
|
|
1
14
|
import { type Maybe, type EmailAddress, type E164PhoneNumber, type BitwiseEncodedSet, type IndexRef, type NeedsSyncBoolean } from '@dereekb/util';
|
|
2
15
|
import { type NotificationBoxId, type NotificationSummaryId, type NotificationTemplateType } from './notification.id';
|
|
3
16
|
import { type FirebaseAuthUserId, type SavedToFirestoreIfTrue } from '../../common';
|
|
4
17
|
/**
|
|
5
|
-
*
|
|
18
|
+
* Per-template notification channel preferences for a recipient.
|
|
6
19
|
*
|
|
7
|
-
*
|
|
20
|
+
* Controls which delivery channels are enabled for a specific {@link NotificationTemplateType}.
|
|
21
|
+
* Undefined values inherit from the parent level in the configuration hierarchy.
|
|
22
|
+
*
|
|
23
|
+
* Field abbreviations:
|
|
24
|
+
* - `sd` — send default (master toggle for all channels)
|
|
25
|
+
* - `se` — send email
|
|
26
|
+
* - `st` — send text/SMS
|
|
27
|
+
* - `sp` — send push notification
|
|
28
|
+
* - `sn` — send to notification summary
|
|
8
29
|
*/
|
|
9
30
|
export interface NotificationBoxRecipientTemplateConfig {
|
|
10
31
|
/**
|
|
11
|
-
*
|
|
32
|
+
* Master toggle. When set, acts as the default for all channels that aren't individually configured.
|
|
12
33
|
*/
|
|
13
34
|
sd?: Maybe<boolean>;
|
|
14
35
|
/**
|
|
15
|
-
* Email enabled
|
|
36
|
+
* Email channel enabled/disabled.
|
|
16
37
|
*/
|
|
17
38
|
se?: Maybe<boolean>;
|
|
18
39
|
/**
|
|
19
|
-
*
|
|
40
|
+
* Text/SMS channel enabled/disabled.
|
|
20
41
|
*/
|
|
21
42
|
st?: Maybe<boolean>;
|
|
22
43
|
/**
|
|
23
|
-
* Push notification enabled
|
|
44
|
+
* Push notification channel enabled/disabled.
|
|
24
45
|
*/
|
|
25
46
|
sp?: Maybe<boolean>;
|
|
26
47
|
/**
|
|
27
|
-
*
|
|
48
|
+
* In-app notification summary channel enabled/disabled.
|
|
28
49
|
*/
|
|
29
50
|
sn?: Maybe<boolean>;
|
|
30
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* Merges two {@link NotificationBoxRecipientTemplateConfig} objects, preferring values from `a` over `b`.
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* ```ts
|
|
57
|
+
* const merged = mergeNotificationBoxRecipientTemplateConfigs(
|
|
58
|
+
* { se: true }, // user prefers email on
|
|
59
|
+
* { se: false, st: true } // defaults
|
|
60
|
+
* );
|
|
61
|
+
* // merged === { se: true, st: true }
|
|
62
|
+
* ```
|
|
63
|
+
*/
|
|
31
64
|
export declare function mergeNotificationBoxRecipientTemplateConfigs(a?: Maybe<NotificationBoxRecipientTemplateConfig>, b?: Maybe<NotificationBoxRecipientTemplateConfig>): NotificationBoxRecipientTemplateConfig;
|
|
65
|
+
/**
|
|
66
|
+
* Resolves a {@link NotificationBoxRecipientTemplateConfig} by filling in undefined channel flags with the `sd` (send default) value.
|
|
67
|
+
*
|
|
68
|
+
* This produces the "effective" configuration used at send time, where each channel has a definite boolean.
|
|
69
|
+
*
|
|
70
|
+
* @example
|
|
71
|
+
* ```ts
|
|
72
|
+
* const effective = effectiveNotificationBoxRecipientTemplateConfig({ sd: true, se: false });
|
|
73
|
+
* // effective === { sd: true, se: false, st: true, sp: true, sn: true }
|
|
74
|
+
* ```
|
|
75
|
+
*/
|
|
32
76
|
export declare function effectiveNotificationBoxRecipientTemplateConfig(a: NotificationBoxRecipientTemplateConfig): NotificationBoxRecipientTemplateConfig;
|
|
33
77
|
/**
|
|
34
|
-
*
|
|
78
|
+
* Contact information for a notification recipient.
|
|
79
|
+
*
|
|
80
|
+
* When `uid` is set, the server resolves contact details (name, email, phone) from the user's profile.
|
|
81
|
+
* Override fields (`n`, `e`, `t`) take precedence over profile data when present.
|
|
82
|
+
*
|
|
83
|
+
* Field abbreviations:
|
|
84
|
+
* - `uid` — Firebase auth user ID
|
|
85
|
+
* - `n` — name override
|
|
86
|
+
* - `e` — email override
|
|
87
|
+
* - `t` — phone/text number override (E.164 format)
|
|
88
|
+
* - `s` — notification summary ID (ignored when `uid` is set)
|
|
35
89
|
*/
|
|
36
90
|
export interface NotificationRecipient {
|
|
37
91
|
/**
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
* Is used to retrieve the contact's information when sending them information, as well as push notification details.
|
|
92
|
+
* Firebase auth UID. When set, contact info is resolved from the user's profile and push notification tokens.
|
|
41
93
|
*/
|
|
42
94
|
uid?: Maybe<FirebaseAuthUserId>;
|
|
43
95
|
/**
|
|
44
|
-
*
|
|
96
|
+
* Display name override. Takes precedence over the user's profile name.
|
|
45
97
|
*/
|
|
46
98
|
n?: Maybe<string>;
|
|
47
99
|
/**
|
|
48
|
-
*
|
|
100
|
+
* Email address override. Takes precedence over the user's profile email.
|
|
49
101
|
*/
|
|
50
102
|
e?: Maybe<EmailAddress>;
|
|
51
103
|
/**
|
|
52
|
-
*
|
|
104
|
+
* Phone number override (E.164 format). Takes precedence over the user's profile phone.
|
|
53
105
|
*/
|
|
54
106
|
t?: Maybe<E164PhoneNumber>;
|
|
55
107
|
/**
|
|
56
|
-
* Notification summary
|
|
108
|
+
* Notification summary ID for in-app delivery. Automatically cleared when `uid` is set.
|
|
57
109
|
*/
|
|
58
110
|
s?: Maybe<NotificationSummaryId>;
|
|
59
111
|
}
|
|
112
|
+
/**
|
|
113
|
+
* Updates a {@link NotificationRecipient} with partial values, preserving existing fields where the update is undefined.
|
|
114
|
+
*
|
|
115
|
+
* Automatically clears the summary ID (`s`) when a `uid` is present.
|
|
116
|
+
*/
|
|
60
117
|
export declare function updateNotificationRecipient(a: NotificationRecipient, b: Partial<NotificationRecipient>): NotificationRecipient;
|
|
118
|
+
/**
|
|
119
|
+
* A {@link NotificationRecipient} combined with inline {@link NotificationBoxRecipientTemplateConfig} overrides.
|
|
120
|
+
*
|
|
121
|
+
* Used on individual {@link Notification} documents to attach per-notification recipient preferences
|
|
122
|
+
* that can override the box-level and user-level configurations.
|
|
123
|
+
*/
|
|
61
124
|
export interface NotificationRecipientWithConfig extends NotificationRecipient, NotificationBoxRecipientTemplateConfig {
|
|
62
125
|
}
|
|
126
|
+
/**
|
|
127
|
+
* Firestore sub-object converter for {@link NotificationRecipientWithConfig}.
|
|
128
|
+
*/
|
|
63
129
|
export declare const firestoreNotificationRecipientWithConfig: import("../..").FirestoreSubObjectFieldMapFunctionsConfig<NotificationRecipientWithConfig, Partial<import("@dereekb/util").ReplaceType<NotificationRecipientWithConfig, import("@dereekb/util").MaybeMap<object>, any>>>;
|
|
130
|
+
/**
|
|
131
|
+
* Recipient-level opt-in/opt-out flag on a {@link NotificationBoxRecipient}.
|
|
132
|
+
*
|
|
133
|
+
* Non-zero values cause the recipient to be skipped during notification delivery.
|
|
134
|
+
*/
|
|
64
135
|
export declare enum NotificationBoxRecipientFlag {
|
|
65
136
|
/**
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
* This is a transient state that should not be stored.
|
|
137
|
+
* Recipient is active and will receive notifications. This is the default; not stored in Firestore.
|
|
69
138
|
*/
|
|
70
139
|
ENABLED = 0,
|
|
71
140
|
/**
|
|
72
|
-
*
|
|
141
|
+
* Recipient is administratively disabled (e.g., by the box owner).
|
|
73
142
|
*/
|
|
74
143
|
DISABLED = 1,
|
|
75
144
|
/**
|
|
76
|
-
* Recipient opted themselves out from
|
|
145
|
+
* Recipient opted themselves out from receiving notifications.
|
|
77
146
|
*/
|
|
78
147
|
OPT_OUT = 2
|
|
79
148
|
}
|
|
80
149
|
/**
|
|
81
|
-
*
|
|
150
|
+
* Recipient entry embedded in a {@link NotificationBox}. Combines contact info with per-template channel configs.
|
|
151
|
+
*
|
|
152
|
+
* When `uid` is set, contact details are resolved from the user's profile at send time.
|
|
153
|
+
* The `i` field (from {@link IndexRef}) tracks the recipient's position and is synced with
|
|
154
|
+
* the corresponding {@link NotificationUserNotificationBoxRecipientConfig} on the user side.
|
|
82
155
|
*
|
|
83
|
-
*
|
|
156
|
+
* Field abbreviations:
|
|
157
|
+
* - `x` — excluded flag (set via {@link NotificationBoxSendExclusion})
|
|
158
|
+
* - `c` — per-template channel config record
|
|
159
|
+
* - `f` — opt-in/opt-out flag
|
|
160
|
+
* - `lk` — locked flag (prevents box-side updates; user can still update their own config)
|
|
84
161
|
*/
|
|
85
162
|
export interface NotificationBoxRecipient extends NotificationRecipient, IndexRef {
|
|
86
163
|
/**
|
|
87
|
-
*
|
|
88
|
-
*
|
|
89
|
-
* This can only be updated by removing the exclusion from the.
|
|
164
|
+
* Excluded flag. Set when the recipient is excluded via a {@link NotificationBoxSendExclusion} on their {@link NotificationUser}.
|
|
165
|
+
* Can only be cleared by removing the exclusion from the user's exclusion list.
|
|
90
166
|
*/
|
|
91
167
|
x?: Maybe<SavedToFirestoreIfTrue>;
|
|
92
168
|
/**
|
|
93
|
-
*
|
|
169
|
+
* Per-template channel configuration. Keys are {@link NotificationTemplateType} values.
|
|
94
170
|
*/
|
|
95
171
|
c: NotificationBoxRecipientTemplateConfigRecord;
|
|
96
172
|
/**
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
* TODO: Test updating the flag and syncing
|
|
173
|
+
* Opt-in/opt-out flag. Non-zero values prevent notification delivery to this recipient.
|
|
100
174
|
*/
|
|
101
175
|
f?: Maybe<NotificationBoxRecipientFlag>;
|
|
102
176
|
/**
|
|
103
|
-
* Locked
|
|
104
|
-
*
|
|
105
|
-
* If locked, updating the NotificationBox recipient will throw an error. The user can update their settings without issue.
|
|
177
|
+
* Locked flag. When true, the box cannot modify this recipient's config — only the user can update via their {@link NotificationUser}.
|
|
106
178
|
*/
|
|
107
179
|
lk?: Maybe<SavedToFirestoreIfTrue>;
|
|
108
180
|
}
|
|
181
|
+
/**
|
|
182
|
+
* Creates a new {@link NotificationBoxRecipient} for a user with an empty config record.
|
|
183
|
+
*
|
|
184
|
+
* @param uid - the user's Firebase auth UID
|
|
185
|
+
* @param i - the recipient's index position in the box's recipient array
|
|
186
|
+
*/
|
|
109
187
|
export declare function newNotificationBoxRecipientForUid(uid: FirebaseAuthUserId, i: number): NotificationBoxRecipient;
|
|
110
188
|
/**
|
|
111
|
-
* Default
|
|
189
|
+
* Default/fallback notification config stored on a {@link NotificationUser}.
|
|
190
|
+
*
|
|
191
|
+
* Used as the base configuration for the user's direct/default config (`dc`) and global config override (`gc`).
|
|
192
|
+
* Omits per-recipient fields (index, name, summary ID, uid, exclusion) that only apply to box-level entries.
|
|
193
|
+
*
|
|
194
|
+
* Field abbreviations:
|
|
195
|
+
* - `lk` — locked flag (prevents box-side updates to this user's recipient entry)
|
|
196
|
+
* - `bk` — blocked flag (prevents the box from re-adding this user)
|
|
112
197
|
*/
|
|
113
198
|
export interface NotificationUserDefaultNotificationBoxRecipientConfig extends Omit<NotificationBoxRecipient, 'i' | 'n' | 's' | 'uid' | 'x'> {
|
|
114
199
|
/**
|
|
115
|
-
* Locked
|
|
116
|
-
*
|
|
117
|
-
* If locked, updating the NotificationBox recipient will throw an error. The user can update their settings without issue.
|
|
200
|
+
* Locked flag. Prevents the NotificationBox from modifying this user's recipient config.
|
|
118
201
|
*/
|
|
119
202
|
lk?: Maybe<SavedToFirestoreIfTrue>;
|
|
120
203
|
/**
|
|
121
|
-
* Blocked
|
|
122
|
-
*
|
|
123
|
-
* If blocked, this NotificationBox will not be able to add this user back.
|
|
204
|
+
* Blocked flag. Prevents the NotificationBox from re-adding this user as a recipient.
|
|
124
205
|
*/
|
|
125
206
|
bk?: Maybe<SavedToFirestoreIfTrue>;
|
|
126
207
|
}
|
|
208
|
+
/**
|
|
209
|
+
* Merges two {@link NotificationUserDefaultNotificationBoxRecipientConfig} objects, preferring defined values from `a` over `b`.
|
|
210
|
+
*/
|
|
127
211
|
export declare function mergeNotificationUserDefaultNotificationBoxRecipientConfig(a: NotificationUserDefaultNotificationBoxRecipientConfig, b: NotificationUserDefaultNotificationBoxRecipientConfig): NotificationUserDefaultNotificationBoxRecipientConfig;
|
|
128
212
|
/**
|
|
129
|
-
*
|
|
213
|
+
* Per-box notification config stored on a {@link NotificationUser}, mirroring the user's {@link NotificationBoxRecipient} entry.
|
|
130
214
|
*
|
|
131
|
-
* The
|
|
215
|
+
* The `i` field tracks the user's index in the box's recipient array. Changes here are synced
|
|
216
|
+
* bidirectionally with the corresponding {@link NotificationBox} during server-side sync.
|
|
217
|
+
*
|
|
218
|
+
* Field abbreviations:
|
|
219
|
+
* - `nb` — NotificationBox ID this config mirrors
|
|
220
|
+
* - `rm` — removed flag (user self-removed from the box)
|
|
221
|
+
* - `ns` — needs-sync flag
|
|
222
|
+
* - `lk` — locked flag (prevents box-side updates)
|
|
223
|
+
* - `bk` — blocked flag (prevents re-addition to the box)
|
|
132
224
|
*/
|
|
133
225
|
export interface NotificationUserNotificationBoxRecipientConfig extends Omit<NotificationBoxRecipient, 'uid'> {
|
|
134
226
|
/**
|
|
135
|
-
* NotificationBox this
|
|
136
|
-
*
|
|
137
|
-
* The model can be derived from this id.
|
|
227
|
+
* ID of the {@link NotificationBox} this config mirrors. The related model key can be inferred via {@link inferNotificationBoxRelatedModelKey}.
|
|
138
228
|
*/
|
|
139
229
|
nb: NotificationBoxId;
|
|
140
230
|
/**
|
|
141
|
-
*
|
|
142
|
-
*
|
|
143
|
-
* If flagged, then this user has flagged themselves to be removed from the NotificationBox or have already been removed.
|
|
144
|
-
*
|
|
145
|
-
* Only the NotificationBox can restore a user, so a if a user removes themselves the user cannot restore themselves.
|
|
146
|
-
* A user will typically prefer to utilize the "f" value (opt-out) flag to not recieve any notifications, rather than remove themselves.
|
|
231
|
+
* Self-removal flag. When set, the user has removed themselves from this box.
|
|
147
232
|
*
|
|
148
|
-
*
|
|
233
|
+
* Only the box owner can restore a removed user. Users typically prefer the `f` (opt-out) flag instead,
|
|
234
|
+
* which stops delivery without removing the subscription. The config is retained unless the user explicitly deletes it.
|
|
149
235
|
*/
|
|
150
236
|
rm?: Maybe<SavedToFirestoreIfTrue>;
|
|
151
237
|
/**
|
|
152
|
-
*
|
|
238
|
+
* Whether this config needs to be synced with the corresponding {@link NotificationBox} recipient entry.
|
|
153
239
|
*/
|
|
154
240
|
ns?: Maybe<NeedsSyncBoolean>;
|
|
155
241
|
/**
|
|
156
|
-
* Locked
|
|
157
|
-
*
|
|
158
|
-
* If locked, updating the NotificationBox recipient will throw an error. The user can update their settings without issue.
|
|
242
|
+
* Locked flag. Prevents the box from modifying this user's recipient config.
|
|
159
243
|
*/
|
|
160
244
|
lk?: Maybe<SavedToFirestoreIfTrue>;
|
|
161
245
|
/**
|
|
162
|
-
* Blocked
|
|
163
|
-
*
|
|
164
|
-
* If blocked, this NotificationBox will not be able to add this user back.
|
|
246
|
+
* Blocked flag. Prevents the box from re-adding this user as a recipient.
|
|
165
247
|
*/
|
|
166
248
|
bk?: Maybe<SavedToFirestoreIfTrue>;
|
|
167
249
|
}
|
|
250
|
+
/**
|
|
251
|
+
* Bit positions for encoding {@link NotificationBoxRecipientTemplateConfig} as a {@link BitwiseEncodedSet}.
|
|
252
|
+
*
|
|
253
|
+
* Each channel has an ON and OFF bit. If neither is set, the channel inherits from the parent config.
|
|
254
|
+
* This encoding allows compact storage of per-template preferences in Firestore.
|
|
255
|
+
*/
|
|
168
256
|
export declare enum NotificationBoxRecipientTemplateConfigBoolean {
|
|
169
257
|
SEND_ALL_ON = 0,
|
|
170
258
|
SEND_ALL_OFF = 1,
|
|
@@ -178,35 +266,76 @@ export declare enum NotificationBoxRecipientTemplateConfigBoolean {
|
|
|
178
266
|
NOTIFICATION_SUMMARY_OFF = 9
|
|
179
267
|
}
|
|
180
268
|
/**
|
|
181
|
-
*
|
|
269
|
+
* Bitwise-encoded form of {@link NotificationBoxRecipientTemplateConfig}, stored as a number in Firestore
|
|
270
|
+
* for space efficiency. Decoded via the internal `notificationBoxRecipientTemplateConfigDencoder`.
|
|
182
271
|
*/
|
|
183
272
|
export type EncodedNotificationBoxRecipientTemplateConfig = BitwiseEncodedSet;
|
|
184
273
|
/**
|
|
185
|
-
* Map of
|
|
274
|
+
* Map of {@link NotificationTemplateType} to per-channel configuration for a recipient.
|
|
186
275
|
*
|
|
187
|
-
*
|
|
276
|
+
* Stored on {@link NotificationBoxRecipient} and {@link NotificationUserNotificationBoxRecipientConfig}.
|
|
277
|
+
* Template types with all channels disabled should be omitted to save space.
|
|
188
278
|
*/
|
|
189
279
|
export type NotificationBoxRecipientTemplateConfigRecord = Record<NotificationTemplateType, NotificationBoxRecipientTemplateConfig>;
|
|
280
|
+
/**
|
|
281
|
+
* Merges two {@link NotificationBoxRecipientTemplateConfigRecord} objects, preferring defined values from `a`.
|
|
282
|
+
*/
|
|
190
283
|
export declare function mergeNotificationBoxRecipientTemplateConfigRecords(a: NotificationBoxRecipientTemplateConfigRecord, b: NotificationBoxRecipientTemplateConfigRecord): NotificationBoxRecipientTemplateConfigRecord;
|
|
191
284
|
/**
|
|
192
|
-
*
|
|
285
|
+
* Bitwise-encoded form of {@link NotificationBoxRecipientTemplateConfigRecord}, with each template type
|
|
286
|
+
* mapped to its {@link EncodedNotificationBoxRecipientTemplateConfig} number.
|
|
193
287
|
*/
|
|
194
288
|
export type EncodedNotificationBoxRecipientTemplateConfigRecord = Record<NotificationTemplateType, EncodedNotificationBoxRecipientTemplateConfig>;
|
|
289
|
+
/**
|
|
290
|
+
* Creates a Firestore field converter for {@link NotificationBoxRecipientTemplateConfigRecord},
|
|
291
|
+
* using bitwise encoding for compact storage.
|
|
292
|
+
*/
|
|
195
293
|
export declare function firestoreNotificationBoxRecipientTemplateConfigRecord(): import("../..").FirestoreModelFieldMapFunctionsConfig<import("../..").FirestoreEncodedObjectMapFieldValueType<NotificationBoxRecipientTemplateConfig, string>, import("../..").FirestoreMapFieldType<number, string>>;
|
|
294
|
+
/**
|
|
295
|
+
* Firestore sub-object converter for {@link NotificationBoxRecipient}.
|
|
296
|
+
*/
|
|
196
297
|
export declare const firestoreNotificationBoxRecipient: import("../..").FirestoreSubObjectFieldMapFunctionsConfig<NotificationBoxRecipient, Partial<import("@dereekb/util").ReplaceType<NotificationBoxRecipient, import("@dereekb/util").MaybeMap<object>, any>>>;
|
|
298
|
+
/**
|
|
299
|
+
* Firestore sub-object converter for {@link NotificationUserDefaultNotificationBoxRecipientConfig}.
|
|
300
|
+
*/
|
|
197
301
|
export declare const firestoreNotificationUserDefaultNotificationBoxRecipientConfig: import("../..").FirestoreSubObjectFieldMapFunctionsConfig<NotificationUserDefaultNotificationBoxRecipientConfig, Partial<import("@dereekb/util").ReplaceType<NotificationUserDefaultNotificationBoxRecipientConfig, import("@dereekb/util").MaybeMap<object>, any>>>;
|
|
302
|
+
/**
|
|
303
|
+
* Firestore sub-object converter for {@link NotificationUserNotificationBoxRecipientConfig}.
|
|
304
|
+
*/
|
|
198
305
|
export declare const firestoreNotificationUserNotificationBoxRecipientConfig: import("../..").FirestoreSubObjectFieldMapFunctionsConfig<NotificationUserNotificationBoxRecipientConfig, Partial<import("@dereekb/util").ReplaceType<NotificationUserNotificationBoxRecipientConfig, import("@dereekb/util").MaybeMap<object>, any>>>;
|
|
306
|
+
/**
|
|
307
|
+
* Array-form entry of a {@link NotificationBoxRecipientTemplateConfig} with its template type key.
|
|
308
|
+
*
|
|
309
|
+
* Used for UI display where iterating over an array is more convenient than a record.
|
|
310
|
+
*/
|
|
199
311
|
export interface NotificationBoxRecipientTemplateConfigArrayEntry extends NotificationBoxRecipientTemplateConfig {
|
|
200
312
|
/**
|
|
201
|
-
*
|
|
313
|
+
* The template type this config entry belongs to.
|
|
202
314
|
*/
|
|
203
315
|
type: NotificationTemplateType;
|
|
204
316
|
}
|
|
317
|
+
/**
|
|
318
|
+
* Array form of {@link NotificationBoxRecipientTemplateConfigRecord} for UI consumption.
|
|
319
|
+
*/
|
|
205
320
|
export type NotificationBoxRecipientTemplateConfigArray = NotificationBoxRecipientTemplateConfigArrayEntry[];
|
|
321
|
+
/**
|
|
322
|
+
* Converts a {@link NotificationBoxRecipientTemplateConfigRecord} to an array of entries with their type keys.
|
|
323
|
+
*
|
|
324
|
+
* @example
|
|
325
|
+
* ```ts
|
|
326
|
+
* const array = notificationBoxRecipientTemplateConfigRecordToArray({ 'comment': { se: true } });
|
|
327
|
+
* // array === [{ type: 'comment', se: true }]
|
|
328
|
+
* ```
|
|
329
|
+
*/
|
|
206
330
|
export declare function notificationBoxRecipientTemplateConfigRecordToArray(input: NotificationBoxRecipientTemplateConfigRecord): NotificationBoxRecipientTemplateConfigArray;
|
|
331
|
+
/**
|
|
332
|
+
* Converts a {@link NotificationBoxRecipientTemplateConfigArray} back to a {@link NotificationBoxRecipientTemplateConfigRecord}.
|
|
333
|
+
*/
|
|
207
334
|
export declare function notificationBoxRecipientTemplateConfigArrayToRecord(input: NotificationBoxRecipientTemplateConfigArray): NotificationBoxRecipientTemplateConfigRecord;
|
|
208
335
|
/**
|
|
209
|
-
*
|
|
336
|
+
* Mixin interface for objects that can optionally trigger a notification on save/update.
|
|
337
|
+
*
|
|
338
|
+
* Used in API parameter types to let callers opt in or out of notification delivery for an action.
|
|
210
339
|
*/
|
|
211
340
|
export interface SendNotificationRef {
|
|
212
341
|
sendNotification?: Maybe<boolean>;
|
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module notification.create
|
|
3
|
+
*
|
|
4
|
+
* Factory functions and template types for creating {@link Notification} documents.
|
|
5
|
+
*
|
|
6
|
+
* Provides a fluent input pattern ({@link CreateNotificationTemplateInput}) that maps friendly field names
|
|
7
|
+
* to the abbreviated Firestore fields, plus throttling support to avoid duplicate sends.
|
|
8
|
+
*/
|
|
1
9
|
import { type Maybe, type Milliseconds, type ModelKey } from '@dereekb/util';
|
|
2
10
|
import { type Notification, type NotificationDocument, type NotificationFirestoreCollections, NotificationSendType } from './notification';
|
|
3
11
|
import { type NotificationRecipientWithConfig } from './notification.config';
|
|
@@ -5,7 +13,8 @@ import { type NotificationTaskType, type NotificationTaskUniqueId, type Notifica
|
|
|
5
13
|
import { type FirebaseAuthUserId, type FirestoreDocumentAccessor, type ReadFirestoreModelKeyInput, type Transaction } from '../../common';
|
|
6
14
|
import { type NotificationItem } from './notification.item';
|
|
7
15
|
/**
|
|
8
|
-
* Template
|
|
16
|
+
* Template for the embedded {@link NotificationItem} within a new notification.
|
|
17
|
+
* Omits auto-generated fields (`id`, `cat`) that are set during document creation.
|
|
9
18
|
*/
|
|
10
19
|
export interface CreateNotificationTemplateItem extends Omit<NotificationItem, 'r' | 'id' | 'cat'> {
|
|
11
20
|
/**
|
|
@@ -14,7 +23,9 @@ export interface CreateNotificationTemplateItem extends Omit<NotificationItem, '
|
|
|
14
23
|
readonly cat?: Maybe<Date>;
|
|
15
24
|
}
|
|
16
25
|
/**
|
|
17
|
-
*
|
|
26
|
+
* Low-level template for creating a new {@link Notification} document. Uses Firestore field abbreviations directly.
|
|
27
|
+
*
|
|
28
|
+
* Prefer using {@link CreateNotificationTemplateInput} with {@link createNotificationTemplate} for a friendlier API.
|
|
18
29
|
*/
|
|
19
30
|
export interface CreateNotificationTemplate extends Partial<Omit<Notification, 'n' | 'a' | 'd' | 'tsr' | 'esr'>> {
|
|
20
31
|
/**
|
|
@@ -44,6 +55,22 @@ export interface CreateNotificationTemplate extends Partial<Omit<Notification, '
|
|
|
44
55
|
*/
|
|
45
56
|
readonly overrideExistingTask?: Maybe<boolean>;
|
|
46
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Friendly input type for creating notification templates. Maps readable field names to the abbreviated Firestore fields.
|
|
60
|
+
*
|
|
61
|
+
* Processed by {@link createNotificationTemplate} into a {@link CreateNotificationTemplate}.
|
|
62
|
+
*
|
|
63
|
+
* @example
|
|
64
|
+
* ```ts
|
|
65
|
+
* const template = createNotificationTemplate({
|
|
66
|
+
* notificationModel: 'project/abc123',
|
|
67
|
+
* type: 'comment',
|
|
68
|
+
* subject: 'New comment',
|
|
69
|
+
* message: 'Someone commented on your project',
|
|
70
|
+
* createdBy: 'user-uid-123'
|
|
71
|
+
* });
|
|
72
|
+
* ```
|
|
73
|
+
*/
|
|
47
74
|
export interface CreateNotificationTemplateInput extends Partial<Omit<CreateNotificationTemplate, 'notificationModel'>>, Partial<Omit<CreateNotificationTemplateItem, 't' | 'cat'>> {
|
|
48
75
|
/**
|
|
49
76
|
* Model key input of the NotificationBox's target model (not the NotificationBox/key)
|
|
@@ -90,7 +117,20 @@ export interface CreateNotificationTemplateInput extends Partial<Omit<CreateNoti
|
|
|
90
117
|
*/
|
|
91
118
|
readonly explicitOptInTextSmsSendOnly?: Maybe<boolean>;
|
|
92
119
|
}
|
|
120
|
+
/**
|
|
121
|
+
* Converts a {@link CreateNotificationTemplateInput} into a {@link CreateNotificationTemplate}
|
|
122
|
+
* ready for document creation.
|
|
123
|
+
*
|
|
124
|
+
* Maps friendly field names (`subject`, `message`, `createdBy`, etc.) to their Firestore abbreviations
|
|
125
|
+
* and filters out null/undefined metadata values.
|
|
126
|
+
*/
|
|
93
127
|
export declare function createNotificationTemplate(input: CreateNotificationTemplateInput): CreateNotificationTemplate;
|
|
128
|
+
/**
|
|
129
|
+
* Input parameters controlling whether a notification should actually be created and sent.
|
|
130
|
+
*
|
|
131
|
+
* Supports both an explicit toggle (`sendNotification`) and time-based throttling
|
|
132
|
+
* to prevent duplicate sends within a configurable window.
|
|
133
|
+
*/
|
|
94
134
|
export interface ShouldSendCreatedNotificationInput {
|
|
95
135
|
/**
|
|
96
136
|
* Whether or not to actually create/save the notification. Defaults to true.
|
|
@@ -106,12 +146,15 @@ export interface ShouldSendCreatedNotificationInput {
|
|
|
106
146
|
readonly sendNotificationThrottleTime?: Maybe<Milliseconds>;
|
|
107
147
|
}
|
|
108
148
|
/**
|
|
109
|
-
*
|
|
149
|
+
* Determines whether a notification should be created based on the explicit toggle and throttle settings.
|
|
110
150
|
*
|
|
111
|
-
*
|
|
112
|
-
* @returns
|
|
151
|
+
* Returns false if `sendNotification` is explicitly false, or if the throttle window hasn't elapsed.
|
|
113
152
|
*/
|
|
114
153
|
export declare function shouldSendCreatedNotificationInput(input: ShouldSendCreatedNotificationInput): boolean;
|
|
154
|
+
/**
|
|
155
|
+
* Full input for creating a {@link Notification} document, including the template, transaction context,
|
|
156
|
+
* and collection accessors.
|
|
157
|
+
*/
|
|
115
158
|
export interface CreateNotificationDocumentPairInput extends ShouldSendCreatedNotificationInput {
|
|
116
159
|
/**
|
|
117
160
|
* Now to use when creating the notification.
|
|
@@ -140,6 +183,9 @@ export interface CreateNotificationDocumentPairInput extends ShouldSendCreatedNo
|
|
|
140
183
|
*/
|
|
141
184
|
readonly accessor?: FirestoreDocumentAccessor<Notification, NotificationDocument>;
|
|
142
185
|
}
|
|
186
|
+
/**
|
|
187
|
+
* Result of creating a notification document pair (document reference + data), before or after saving.
|
|
188
|
+
*/
|
|
143
189
|
export interface CreateNotificationDocumentPairResult extends Pick<CreateNotificationTemplate, 'overrideExistingTask'> {
|
|
144
190
|
readonly notificationDocument: NotificationDocument;
|
|
145
191
|
readonly notification: Notification;
|
|
@@ -153,11 +199,14 @@ export interface CreateNotificationDocumentPairResult extends Pick<CreateNotific
|
|
|
153
199
|
readonly isNotificationTask: boolean;
|
|
154
200
|
}
|
|
155
201
|
/**
|
|
156
|
-
* Creates a
|
|
202
|
+
* Creates a notification document reference and builds the {@link Notification} data, but does NOT save to Firestore.
|
|
203
|
+
*
|
|
204
|
+
* Use {@link createNotificationDocument} to both create and save in one step.
|
|
157
205
|
*
|
|
158
|
-
*
|
|
206
|
+
* For unique task notifications, generates a deterministic document ID from the target model and task type.
|
|
159
207
|
*
|
|
160
|
-
* @
|
|
208
|
+
* @throws {Error} When neither an accessor nor sufficient context is provided
|
|
209
|
+
* @throws {Error} When `unique=true` but no target model is specified
|
|
161
210
|
*/
|
|
162
211
|
export declare function createNotificationDocumentPair(input: CreateNotificationDocumentPairInput): CreateNotificationDocumentPairResult;
|
|
163
212
|
/**
|
|
@@ -165,15 +214,15 @@ export declare function createNotificationDocumentPair(input: CreateNotification
|
|
|
165
214
|
*/
|
|
166
215
|
export declare function _createNotificationDocumentFromPair(input: Pick<CreateNotificationDocumentPairInput, 'shouldCreateNotification' | keyof ShouldSendCreatedNotificationInput>, pair: CreateNotificationDocumentPairResult): Promise<CreateNotificationDocumentPairResult>;
|
|
167
216
|
/**
|
|
168
|
-
* Creates a new Notification and saves it to Firestore.
|
|
217
|
+
* Creates a new {@link Notification} document and saves it to Firestore.
|
|
169
218
|
*
|
|
170
|
-
*
|
|
219
|
+
* For unique tasks with `overrideExistingTask`, uses `set()` to replace existing documents.
|
|
220
|
+
* Otherwise uses `create()` which fails if the document already exists.
|
|
171
221
|
*/
|
|
172
222
|
export declare function createNotificationDocument(input: CreateNotificationDocumentPairInput): Promise<CreateNotificationDocumentPairResult>;
|
|
173
223
|
/**
|
|
174
|
-
* Creates
|
|
224
|
+
* Creates and saves a notification only if sending conditions are met (not throttled, not explicitly disabled).
|
|
175
225
|
*
|
|
176
|
-
*
|
|
177
|
-
* @returns
|
|
226
|
+
* Returns `undefined` if the notification was not created.
|
|
178
227
|
*/
|
|
179
228
|
export declare function createNotificationDocumentIfSending(input: CreateNotificationDocumentPairInput): Promise<Maybe<CreateNotificationDocumentPairResult>>;
|
|
@@ -1,10 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module notification.create.task
|
|
3
|
+
*
|
|
4
|
+
* Convenience factory for creating task-type notification templates.
|
|
5
|
+
* Wraps {@link createNotificationTemplate} with task-specific defaults.
|
|
6
|
+
*/
|
|
1
7
|
import { type Maybe } from '@dereekb/util';
|
|
2
8
|
import { type NotificationTaskCheckpointString } from './notification';
|
|
3
9
|
import { type CreateNotificationTemplate, type CreateNotificationTemplateInput } from './notification.create';
|
|
4
10
|
/**
|
|
5
|
-
* Template
|
|
11
|
+
* Template for creating a task-type {@link Notification}. Alias for {@link CreateNotificationTemplate}.
|
|
6
12
|
*/
|
|
7
13
|
export type CreateNotificationTaskTemplate = CreateNotificationTemplate;
|
|
14
|
+
/**
|
|
15
|
+
* Simplified input for creating task notification templates. Omits fields not applicable to tasks
|
|
16
|
+
* (recipients, send type, recipient flags) and makes `notificationModel` optional.
|
|
17
|
+
*
|
|
18
|
+
* When `notificationModel` is omitted, defaults to {@link DEFAULT_NOTIFICATION_TASK_NOTIFICATION_MODEL_KEY}.
|
|
19
|
+
*/
|
|
8
20
|
export interface CreateNotificationTaskTemplateInput extends Omit<CreateNotificationTemplateInput, 'notificationModel' | 'st' | 'recipients' | 'r' | 'rf' | 'sendType' | 'st'>, Partial<Pick<CreateNotificationTemplateInput, 'notificationModel'>> {
|
|
9
21
|
/**
|
|
10
22
|
* Corresponds with the tpr field in the Notification.
|
|
@@ -14,9 +26,18 @@ export interface CreateNotificationTaskTemplateInput extends Omit<CreateNotifica
|
|
|
14
26
|
readonly completedCheckpoints?: Maybe<NotificationTaskCheckpointString[]>;
|
|
15
27
|
}
|
|
16
28
|
/**
|
|
17
|
-
* Creates a
|
|
29
|
+
* Creates a {@link CreateNotificationTaskTemplate} with `TASK_NOTIFICATION` send type and no recipients.
|
|
30
|
+
*
|
|
31
|
+
* @throws {Error} When `unique=true` but no `notificationModel` or target model is specified.
|
|
18
32
|
*
|
|
19
|
-
* @
|
|
20
|
-
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* const template = createNotificationTaskTemplate({
|
|
36
|
+
* type: 'generate-report',
|
|
37
|
+
* targetModel: 'project/abc123',
|
|
38
|
+
* unique: true,
|
|
39
|
+
* data: { reportType: 'monthly' }
|
|
40
|
+
* });
|
|
41
|
+
* ```
|
|
21
42
|
*/
|
|
22
43
|
export declare function createNotificationTaskTemplate(input: CreateNotificationTaskTemplateInput): CreateNotificationTaskTemplate;
|