@insignia-education/api-sdk-js 0.15.119 → 0.15.120
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/package.json +1 -1
- package/src/api/v1/Users.js +3 -1
package/package.json
CHANGED
package/src/api/v1/Users.js
CHANGED
|
@@ -242,13 +242,15 @@ export default class Users {
|
|
|
242
242
|
/** GDPR access/portability request (Art. 15/20) — self-service or sales-and-above. Runs synchronously and returns the DataRequest with `pdf_url`/`json_url` already populated. */
|
|
243
243
|
exportData(userId) { return this.#client.post(`/users/${userId}/data-export`); }
|
|
244
244
|
|
|
245
|
-
/** Notifications are created by internal services, not over the API — `resend()`
|
|
245
|
+
/** Notifications are created by internal services, not over the API — `resend()` and `send()` (both sales-and-above) are the exceptions. */
|
|
246
246
|
notifications(userId) {
|
|
247
247
|
const base = `/users/${userId}/notifications`;
|
|
248
248
|
const client = this.#client;
|
|
249
249
|
return {
|
|
250
250
|
get: () => client.get(base),
|
|
251
251
|
resend: (id) => client.post(`${base}/${id}/resend`),
|
|
252
|
+
/** Composes and sends (or schedules) a one-off message to this user. data: { subject, content, channels, include_signature?, scheduled_at? }. */
|
|
253
|
+
send: (data) => client.post(`${base}/send`, data),
|
|
252
254
|
};
|
|
253
255
|
}
|
|
254
256
|
|