@steve31415/baselib 3.33.2 → 3.34.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/dist/email.d.ts +4 -0
- package/dist/email.js +1 -0
- package/package.json +1 -1
package/dist/email.d.ts
CHANGED
|
@@ -15,6 +15,10 @@ export interface EmailMessage {
|
|
|
15
15
|
text?: string;
|
|
16
16
|
html?: string;
|
|
17
17
|
attachments?: EmailAttachment[];
|
|
18
|
+
/** Extra message headers (`X-Coder-Task`, `In-Reply-To`, …), passed to
|
|
19
|
+
* Resend's `headers` field as given. Coder uses them so Radar can
|
|
20
|
+
* recognise and thread its task mail (2026-10-11). */
|
|
21
|
+
headers?: Record<string, string>;
|
|
18
22
|
}
|
|
19
23
|
export interface SendEmailResult {
|
|
20
24
|
ok: boolean;
|
package/dist/email.js
CHANGED
|
@@ -54,6 +54,7 @@ export async function sendEmail(msg, deps) {
|
|
|
54
54
|
subject: msg.subject,
|
|
55
55
|
...(msg.text !== undefined ? { text: msg.text } : {}),
|
|
56
56
|
...(msg.html !== undefined ? { html: msg.html } : {}),
|
|
57
|
+
...(msg.headers && Object.keys(msg.headers).length ? { headers: msg.headers } : {}),
|
|
57
58
|
...(msg.attachments?.length
|
|
58
59
|
? {
|
|
59
60
|
attachments: msg.attachments.map((attachment) => ({
|
package/package.json
CHANGED