mailgun.js 10.2.0 → 10.2.1

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/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [10.2.1](https://github.com/mailgun/mailgun.js/compare/v10.2.0...v10.2.1) (2024-02-16)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * Source.on is not a function for t:variables ([e647143](https://github.com/mailgun/mailgun.js/commits/e64714326b443b70022c646ab4d0c123d1bf6abe))
11
+
5
12
  ## [10.2.0](https://github.com/mailgun/mailgun.js/compare/v10.1.0...v10.2.0) (2024-02-15)
6
13
 
7
14
 
@@ -18,7 +18,14 @@ export type CustomFile = {
18
18
  [key: string]: unknown;
19
19
  };
20
20
  export type MessageAttachment = CustomFile | CustomFile[] | File | File[] | string | CustomFileData | CustomFileData[];
21
- export type FormDataInputValue = MimeMessage | CustomFileData | string | string[] | boolean | MessageAttachment | undefined | number;
21
+ export type FormDataInputValue = MimeMessage | CustomFileData | string | string[] | boolean | MessageAttachment | undefined | number | JsonObject;
22
+ export type JsonPrimitive = string | number | boolean | null;
23
+ export type JsonArray = Json[];
24
+ export type JsonObject = {
25
+ [key: string]: Json;
26
+ };
27
+ export type JsonComposite = JsonArray | JsonObject;
28
+ export type Json = JsonPrimitive | JsonComposite;
22
29
  export type MailgunMessageContent = AtLeastOneKeyPresent<{
23
30
  /**
24
31
  * Body of the message. (text version)
@@ -85,6 +92,11 @@ export type MailgunMessageData = MailgunMessageContent & {
85
92
  * in the text part of the message in case of template sending
86
93
  */
87
94
  't:text'?: boolean | 'yes' | 'no';
95
+ /**
96
+ * A valid JSON-encoded dictionary used as the input for template variable expansion.
97
+ * See [Templates](https://documentation.mailgun.com/en/latest/api-templates.html#api-templates) for more information.
98
+ */
99
+ 't:variables'?: string | JsonObject;
88
100
  /**
89
101
  * Tag string. See [Tagging](https://documentation.mailgun.com/en/latest/user_manual.html#tagging) for more information.
90
102
  */