feat: make new attachments API conform to updated spec#174
Merged
Conversation
drish
approved these changes
Oct 29, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This updates the API for the inbound methods on this SDK to conform to the new specification.
Note that I also fixed an incorrect wrapping in
datathat I ended up missing from the first review.This is as per @vieiralucas message's from Monday:
In Python, that means we now have:
What I need from you
Please review/test my changes carefully. I have already created a test file locally to test all these functions, but please do test it too.
If you need to make any changes, please go ahead and make commits to this PR.
Once done, please let's release a new version with these changes. I'm not sure if you have already released a version with this, but please do once you merge this (let's avoid releasing the old SDK API if it's not released yet just to avoid a major bump if possible).
Summary by cubic
Updated the attachments API to match the new spec. Attachment methods are now under resend.Emails and responses return the attachment object directly (no data wrapper).
Refactors
Migration