Skip to content

Conversation

@vieiralucas
Copy link
Member

@vieiralucas vieiralucas commented Oct 24, 2025

  • Moved resend.attachments.sending → resend.emails.attachments
  • Moved resend.attachments.receiving → resend.emails.receiving.attachments
  • Removed top-level resend.attachments module
  • Updated API paths from /emails/sending/ to /emails/

Depends on https://github.com/resend/resend-api/pull/2291


Summary by cubic

Reorganized attachments under Emails to match the final API design and align with PRODUCT-791. Endpoints now use /emails/, and the top-level attachments module is removed.

  • Refactors

    • resend.attachments.sending → resend.emails.attachments
    • resend.attachments.receiving → resend.emails.receiving.attachments
    • Removed top-level resend.attachments
    • Updated endpoints from /emails/sending/... to /emails/...
  • Migration

    • Replace calls: resend.attachments.sending.* → resend.emails.attachments.*
    • Replace calls: resend.attachments.receiving.* → resend.emails.receiving.attachments.*
    • Stop importing attachments interfaces from the top-level index.
    • Requires resend-api PR #2291 (for /emails/... endpoints).

@vieiralucas vieiralucas requested a review from a team as a code owner October 24, 2025 20:28
@pkg-pr-new
Copy link

pkg-pr-new bot commented Oct 24, 2025

Open in StackBlitz

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

commit: 5c5fca1

}

export type GetAttachmentResponseSuccess = {
object: 'attachment';
Copy link
Member

Choose a reason for hiding this comment

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

This need to be changed

Suggested change
object: 'attachment';
object: 'email';

Copy link
Member Author

Choose a reason for hiding this comment

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

Why? Isn't it an attachment? Am I missing something?

Copy link
Member

Choose a reason for hiding this comment

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

The entity is email, not attachment

Copy link
Member Author

Choose a reason for hiding this comment

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

The api does return attachment in this field. So'll just merge as it is, if you mean that we should also change the API let me know and we can talk about this.

Copy link
Contributor

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

Choose a reason for hiding this comment

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

cubic analysis

No issues found across 17 files

Linked issue analysis

Linked issue: PRODUCT-791: Rename sdk methods to follow final version

Status Acceptance criteria Notes
Moved resend.attachments.sending → resend.emails.attachments Renamed Sending → Attachments and wired under Emails
Moved resend.attachments.receiving → resend.emails.receiving.attachments Created Attachments under receiving and wired into Receiving
Removed top-level resend.attachments module Top-level attachments file removed and resend no longer exposes it
Updated API paths from /emails/sending/ to /emails/ HTTP paths updated to /emails/${emailId}/attachments in calls
Replace calls: resend.attachments.sending.* → resend.emails.attachments.* All sending attachment calls updated to resend.emails.attachments
Replace calls: resend.attachments.receiving.* → resend.emails.receiving.attachments.* All receiving attachment calls updated to resend.emails.receiving.attachments
Stop importing attachments interfaces from the top-level index Top-level export removed and imports updated to new paths
Move/rename attachments interfaces under emails/attachments and update imports Interfaces added/moved under emails/receiving/attachments and adjusted imports
Depends on resend-api PR #2291 (use /emails/ endpoints) External API PR referenced but not implemented here

- Moved resend.attachments.sending → resend.emails.attachments
- Moved resend.attachments.receiving → resend.emails.receiving.attachments
- Removed top-level resend.attachments module
- Updated API paths from /emails/sending/ to /emails/
@vieiralucas vieiralucas force-pushed the feature/product-791-rename-sdk-methods-to-follow-final-version branch from b60b625 to c957e51 Compare October 27, 2025 14:10
Copy link
Contributor

@lucasfcosta lucasfcosta left a comment

Choose a reason for hiding this comment

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

Code LGTM. Please confirm with Bu the entity name as we discussed on Slack.

@vieiralucas vieiralucas merged commit 72ea317 into canary Oct 27, 2025
11 checks passed
@vieiralucas vieiralucas deleted the feature/product-791-rename-sdk-methods-to-follow-final-version branch October 27, 2025 14:52
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.

4 participants