@sentdm/sentdm 0.42.0 → 0.43.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.
Files changed (44) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/client.d.mts +2 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +2 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +2 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +2 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/calls/calls.d.mts +10 -8
  12. package/resources/calls/calls.d.mts.map +1 -1
  13. package/resources/calls/calls.d.ts +10 -8
  14. package/resources/calls/calls.d.ts.map +1 -1
  15. package/resources/calls/calls.js +5 -4
  16. package/resources/calls/calls.js.map +1 -1
  17. package/resources/calls/calls.mjs +5 -4
  18. package/resources/calls/calls.mjs.map +1 -1
  19. package/resources/calls/participants.d.mts +5 -5
  20. package/resources/calls/participants.d.ts +5 -5
  21. package/resources/calls/participants.js +5 -5
  22. package/resources/calls/participants.mjs +5 -5
  23. package/resources/messages.d.mts +13 -8
  24. package/resources/messages.d.mts.map +1 -1
  25. package/resources/messages.d.ts +13 -8
  26. package/resources/messages.d.ts.map +1 -1
  27. package/resources/messages.js +7 -4
  28. package/resources/messages.js.map +1 -1
  29. package/resources/messages.mjs +7 -4
  30. package/resources/messages.mjs.map +1 -1
  31. package/resources/webhooks.d.mts +8 -3
  32. package/resources/webhooks.d.mts.map +1 -1
  33. package/resources/webhooks.d.ts +8 -3
  34. package/resources/webhooks.d.ts.map +1 -1
  35. package/src/client.ts +2 -0
  36. package/src/resources/calls/calls.ts +10 -8
  37. package/src/resources/calls/participants.ts +5 -5
  38. package/src/resources/messages.ts +13 -8
  39. package/src/resources/webhooks.ts +8 -3
  40. package/src/version.ts +1 -1
  41. package/version.d.mts +1 -1
  42. package/version.d.ts +1 -1
  43. package/version.js +1 -1
  44. package/version.mjs +1 -1
@@ -15,6 +15,8 @@ import { path } from '../internal/utils/path';
15
15
  * **A message needs a sender.** What you can send, where, and at what cost is decided by the markets under **Channels** — so a recipient in a country you hold no sender for is refused here rather than queued.
16
16
  *
17
17
  * **A message can be resent on its id.** `POST /v3/messages/{id}/resend` puts a finished message — typically one BLOCKED for insufficient balance — back through the send pipeline. It is a new attempt, not a free retry: every policy runs again, the message is billed again, and its status webhooks fire again. A FILTERED message is never resendable.
18
+ *
19
+ * **A scheduled message can be called off.** `POST /v3/messages/{id}/cancel` cancels a send you scheduled with `scheduled_at`, as long as it has not been released yet. Cancelling is free, fires `message.cancelled`, and is final — a cancelled message cannot be resent.
18
20
  */
19
21
  export class Messages extends APIResource {
20
22
  /**
@@ -48,10 +50,11 @@ export class Messages extends APIResource {
48
50
  /**
49
51
  * Retrieves the current status and details of a message by ID. Includes delivery
50
52
  * status, timestamps, and error information if applicable. A message that is or
51
- * was held for a later time (a send you scheduled with scheduled_at, or a
52
- * quiet-hours hold) is returned as a ScheduledMessageResponse: the same fields
53
- * plus scheduled_at, the release instant in UTC. A message sent immediately has no
54
- * scheduled_at key.
53
+ * was held for a later time (a send you scheduled with scheduled_at, a quiet-hours
54
+ * hold, or a message you cancelled while it was held) is returned as a
55
+ * ScheduledMessageResponse: the same fields plus scheduled_at, the instant it is
56
+ * held for in UTC — or, on a CANCELLED message, the instant that was called off. A
57
+ * message sent immediately has no scheduled_at key.
55
58
  *
56
59
  * @example
57
60
  * ```ts
@@ -213,10 +216,12 @@ export namespace MessageRetrieveActivitiesResponse {
213
216
  reason_code?: string | null;
214
217
 
215
218
  /**
216
- * SCHEDULED activities only: when the held message will be released for delivery,
217
- * in UTC. Same wire name as on the send response, the message and the webhook.
218
- * Omitted on every other activity. A message that quiet hours moved at release has
219
- * two SCHEDULED entries, each carrying the instant as it stood at that moment.
219
+ * SCHEDULED and CANCELLED activities only, in UTC: on a SCHEDULED entry, when the
220
+ * held message will be released for delivery; on a CANCELLED entry, the instant
221
+ * that was called off. Same wire name as on the send response, the message and the
222
+ * webhook. Omitted on every other activity. A message that quiet hours moved at
223
+ * release has two SCHEDULED entries, each carrying the instant as it stood at that
224
+ * moment.
220
225
  */
221
226
  scheduled_at?: string | null;
222
227
 
@@ -1173,13 +1173,18 @@ export interface MessageEventPayload {
1173
1173
  /**
1174
1174
  * message.scheduled only: why the message is held, either because you scheduled it
1175
1175
  * or because the recipient is inside a protected quiet-hours window. Omitted on
1176
- * every other event.
1176
+ * every other event, including message.cancelled — that is a property of the hold,
1177
+ * not of the cancellation, and repeating it there would read as "why was this
1178
+ * cancelled", which it does not answer.
1177
1179
  */
1178
1180
  schedule_reason?: string | null;
1179
1181
 
1180
1182
  /**
1181
- * message.scheduled only: when the held message will be released for delivery, in
1182
- * UTC (yyyy-MM-ddTHH:mm:ssZ). Omitted on every other event.
1183
+ * message.scheduled and message.cancelled only, in UTC (yyyy-MM-ddTHH:mm:ssZ): on
1184
+ * message.scheduled it is when the held message will be released for delivery, on
1185
+ * message.cancelled the release instant that was called off — the same instant,
1186
+ * before and after. A consumer that recorded a future send from the first event
1187
+ * has what it needs to un-record it from the second. Omitted on every other event.
1183
1188
  */
1184
1189
  scheduled_at?: string | null;
1185
1190
 
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.42.0'; // x-release-please-version
1
+ export const VERSION = '0.43.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.42.0";
1
+ export declare const VERSION = "0.43.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.42.0";
1
+ export declare const VERSION = "0.43.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.42.0'; // x-release-please-version
4
+ exports.VERSION = '0.43.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.42.0'; // x-release-please-version
1
+ export const VERSION = '0.43.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map