feat(iios): EmailAdapter (email-native normalize + threading) in adapter-sdk

Adds a canonical EmailInboundPayload + EmailAdapter implementing the
ChannelAdapter contract: HMAC signature verify + normalize with email-native
threading (whole reply chain → one IIOS thread via references/inReplyTo root),
messageId as providerEventId for dedup, html→text fallback, Re:/Fwd: stripping.
Plus emailInboundFixture/emailReplyFixture and unit tests.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-03 20:25:00 +05:30
parent 427396653f
commit ae50f56404
4 changed files with 139 additions and 2 deletions
+2 -1
View File
@@ -2,4 +2,5 @@ export * from './types';
export { hmacSign, hmacVerify } from './hmac';
export { SandboxSink } from './sandbox';
export { WebhookAdapter, type WebhookPayload } from './webhook-adapter';
export { emailFixture, whatsappFixture, signedFixture } from './fixtures';
export { EmailAdapter, type EmailInboundPayload } from './email-adapter';
export { emailFixture, whatsappFixture, emailInboundFixture, emailReplyFixture, signedFixture } from './fixtures';