@mailhooks/sdk 2.6.12 → 2.6.13
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/dist/index.js +4 -2
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import axios from 'axios';
|
|
2
|
+
import { EventSource as EventSource$1 } from 'eventsource';
|
|
2
3
|
import { createHmac, timingSafeEqual } from 'crypto';
|
|
3
4
|
import { simpleParser } from 'mailparser';
|
|
4
5
|
|
|
@@ -241,8 +242,9 @@ var EmailsResource = class extends MailhooksClient {
|
|
|
241
242
|
}
|
|
242
243
|
}
|
|
243
244
|
};
|
|
244
|
-
|
|
245
|
-
|
|
245
|
+
if (typeof globalThis.EventSource === "undefined") {
|
|
246
|
+
globalThis.EventSource = EventSource$1;
|
|
247
|
+
}
|
|
246
248
|
var RealtimeEventType = /* @__PURE__ */ ((RealtimeEventType2) => {
|
|
247
249
|
RealtimeEventType2["EMAIL_RECEIVED"] = "email.received";
|
|
248
250
|
RealtimeEventType2["EMAIL_UPDATED"] = "email.updated";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mailhooks/sdk",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.13",
|
|
4
4
|
"description": "TypeScript SDK for Mailhooks API",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
],
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"axios": "^1.6.0",
|
|
29
|
+
"eventsource": "^3.0.0",
|
|
29
30
|
"mailparser": "^3.7.2"
|
|
30
31
|
},
|
|
31
32
|
"devDependencies": {
|