@surgeapi/node 0.37.0 → 0.38.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 (59) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/client.d.mts +3 -3
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +3 -3
  5. package/client.d.ts.map +1 -1
  6. package/client.js +8 -7
  7. package/client.js.map +1 -1
  8. package/client.mjs +8 -7
  9. package/client.mjs.map +1 -1
  10. package/internal/tslib.js +22 -22
  11. package/internal/utils/query.d.mts +2 -0
  12. package/internal/utils/query.d.mts.map +1 -0
  13. package/internal/utils/query.d.ts +2 -0
  14. package/internal/utils/query.d.ts.map +1 -0
  15. package/internal/utils/query.js +10 -0
  16. package/internal/utils/query.js.map +1 -0
  17. package/internal/utils/query.mjs +6 -0
  18. package/internal/utils/query.mjs.map +1 -0
  19. package/internal/utils.d.mts +1 -0
  20. package/internal/utils.d.ts +1 -0
  21. package/internal/utils.js +1 -0
  22. package/internal/utils.js.map +1 -1
  23. package/internal/utils.mjs +1 -0
  24. package/package.json +7 -1
  25. package/resources/blasts.d.mts +3 -2
  26. package/resources/blasts.d.mts.map +1 -1
  27. package/resources/blasts.d.ts +3 -2
  28. package/resources/blasts.d.ts.map +1 -1
  29. package/resources/campaigns.d.mts +1 -1
  30. package/resources/campaigns.d.mts.map +1 -1
  31. package/resources/campaigns.d.ts +1 -1
  32. package/resources/campaigns.d.ts.map +1 -1
  33. package/resources/index.d.mts +1 -1
  34. package/resources/index.d.mts.map +1 -1
  35. package/resources/index.d.ts +1 -1
  36. package/resources/index.d.ts.map +1 -1
  37. package/resources/index.js.map +1 -1
  38. package/resources/index.mjs.map +1 -1
  39. package/resources/phone-numbers.d.mts +4 -0
  40. package/resources/phone-numbers.d.mts.map +1 -1
  41. package/resources/phone-numbers.d.ts +4 -0
  42. package/resources/phone-numbers.d.ts.map +1 -1
  43. package/resources/webhooks.d.mts +44 -2
  44. package/resources/webhooks.d.mts.map +1 -1
  45. package/resources/webhooks.d.ts +44 -2
  46. package/resources/webhooks.d.ts.map +1 -1
  47. package/src/client.ts +13 -10
  48. package/src/internal/utils/query.ts +7 -0
  49. package/src/internal/utils.ts +1 -0
  50. package/src/resources/blasts.ts +3 -2
  51. package/src/resources/campaigns.ts +1 -1
  52. package/src/resources/index.ts +1 -0
  53. package/src/resources/phone-numbers.ts +5 -0
  54. package/src/resources/webhooks.ts +52 -0
  55. package/src/version.ts +1 -1
  56. package/version.d.mts +1 -1
  57. package/version.d.ts +1 -1
  58. package/version.js +1 -1
  59. package/version.mjs +1 -1
@@ -699,6 +699,56 @@ export namespace MessageSentWebhookEvent {
699
699
  }
700
700
  }
701
701
 
702
+ export interface PhoneNumberAttachedToCampaignWebhookEvent {
703
+ /**
704
+ * The ID of the account in which this event occurred
705
+ */
706
+ account_id: string;
707
+
708
+ /**
709
+ * The data associated with the event
710
+ */
711
+ data: PhoneNumberAttachedToCampaignWebhookEvent.Data;
712
+
713
+ /**
714
+ * The timestamp when this event occurred, in ISO8601 format
715
+ */
716
+ timestamp: string;
717
+
718
+ /**
719
+ * The type of the event. Always `phone_number.attached_to_campaign` for this
720
+ * event.
721
+ */
722
+ type: 'phone_number.attached_to_campaign';
723
+ }
724
+
725
+ export namespace PhoneNumberAttachedToCampaignWebhookEvent {
726
+ /**
727
+ * The data associated with the event
728
+ */
729
+ export interface Data {
730
+ /**
731
+ * The unique identifier for the phone number
732
+ */
733
+ id: string;
734
+
735
+ /**
736
+ * The unique identifier of the campaign this phone number is attached to
737
+ */
738
+ campaign_id: string;
739
+
740
+ /**
741
+ * The phone number in E.164 format
742
+ */
743
+ number: string;
744
+
745
+ /**
746
+ * Whether the phone number is local, toll-free, or short code
747
+ */
748
+ type: 'local' | 'short_code' | 'toll_free';
749
+ }
750
+ }
751
+
702
752
  export interface RecordingCompletedWebhookEvent {
703
753
  /**
704
754
  * The ID of the account in which this event occurred
@@ -885,6 +935,7 @@ export type UnwrapWebhookEvent =
885
935
  | MessageFailedWebhookEvent
886
936
  | MessageReceivedWebhookEvent
887
937
  | MessageSentWebhookEvent
938
+ | PhoneNumberAttachedToCampaignWebhookEvent
888
939
  | RecordingCompletedWebhookEvent
889
940
  | VoicemailReceivedWebhookEvent;
890
941
 
@@ -900,6 +951,7 @@ export declare namespace Webhooks {
900
951
  type MessageFailedWebhookEvent as MessageFailedWebhookEvent,
901
952
  type MessageReceivedWebhookEvent as MessageReceivedWebhookEvent,
902
953
  type MessageSentWebhookEvent as MessageSentWebhookEvent,
954
+ type PhoneNumberAttachedToCampaignWebhookEvent as PhoneNumberAttachedToCampaignWebhookEvent,
903
955
  type RecordingCompletedWebhookEvent as RecordingCompletedWebhookEvent,
904
956
  type VoicemailReceivedWebhookEvent as VoicemailReceivedWebhookEvent,
905
957
  type UnwrapWebhookEvent as UnwrapWebhookEvent,
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.37.0'; // x-release-please-version
1
+ export const VERSION = '0.38.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.37.0";
1
+ export declare const VERSION = "0.38.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.37.0";
1
+ export declare const VERSION = "0.38.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.37.0'; // x-release-please-version
4
+ exports.VERSION = '0.38.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.37.0'; // x-release-please-version
1
+ export const VERSION = '0.38.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map