Thanks to visit codestin.com
Credit goes to github.com

Skip to content

feat: add batch specific email options type to reflect API limitations#801

Merged
gabrielmfern merged 2 commits into
resend:canaryfrom
titouv:canary
Feb 10, 2026
Merged

feat: add batch specific email options type to reflect API limitations#801
gabrielmfern merged 2 commits into
resend:canaryfrom
titouv:canary

Conversation

@titouv

@titouv titouv commented Jan 21, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Exclude attachments and scheduledAt from CreateBatchEmailOptions type to reflect batch API limitations
  • Add new CreateBatchEmailOptions type using Omit<CreateEmailOptions, 'attachments' | 'scheduledAt'>

These fields are not supported by the batch API as documented at https://resend.com/docs/dashboard/emails/batch-sending#limitations

Objective

This tries to solve a problem I encountered where the types allowed an attachments array value, but no attachments could be sent via the Batch API and the "issue" was just ignored misleading the developper.

This provides compile-time errors when users attempt to use unsupported features with batch sending.


Summary by cubic

Align batch email types with API limitations by excluding attachments and scheduledAt. Adds CreateBatchEmailOptions and updates CreateBatchOptions to use it, so unsupported fields cause compile-time errors.

Written for commit 5e3f2e5. Summary will update on new commits.

@titouv titouv requested a review from a team as a code owner January 21, 2026 22:58
@titouv titouv requested a review from CarolinaMoraes January 21, 2026 22:58

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

@pkg-pr-new

pkg-pr-new Bot commented Jan 26, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/resend/resend-node/resend@801

commit: 5e3f2e5

@gabrielmfern gabrielmfern merged commit 2856a15 into resend:canary Feb 10, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants