Skip to content

feat: return response headers on all responses - #713

Merged
gabrielmfern merged 8 commits into
canaryfrom
feat/response-headers
Oct 27, 2025
Merged

gabrielmfern merged 8 commits into
canaryfrom
feat/response-headers

Conversation

@gabrielmfern

@gabrielmfern gabrielmfern commented Oct 24, 2025 •

Copy link
Copy Markdown
Member

Most of this is updating tests, the actual main changes are to resend.ts and interfaces.ts


Summary by cubic

Return HTTP response headers on all SDK responses to improve debugging and integration visibility. Adds a headers field to response objects and unifies types via a new Response generic.

  • New Features

    • Every response now includes headers: Record<string, string> | null (e.g., authorization, content-type).
  • Refactors

    • Introduced Response type and replaced per-endpoint unions with this shared type.
    • Updated fetchRequest to attach headers on success and error responses.
    • Revised all interfaces and tests to use the new response shape.

@gabrielmfern
gabrielmfern marked this pull request as ready for review October 24, 2025 16:48
@gabrielmfern
gabrielmfern requested a review from a team as a code owner October 24, 2025 16:48

@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 80 files

@pkg-pr-new

pkg-pr-new Bot commented Oct 24, 2025 •

Copy link
Copy Markdown

Open in StackBlitz

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

commit: 29cc01d

@gabrielmfern
gabrielmfern requested review from joaopcm and removed request for Cisneiros October 24, 2025 18:01
@gabrielmfern
gabrielmfern force-pushed the feat/response-headers branch from 4c7b95c to 5913a4f Compare October 27, 2025 19:51
@gabrielmfern
gabrielmfern force-pushed the feat/response-headers branch from 5913a4f to 3d814fb Compare October 27, 2025 20:02
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.

2 participants