fix(emails): flatten metrics filter query params - #1052
Merged
dielduarte merged 1 commit intoAug 7, 2026
Conversation
domain_id/email_id are now sent as flat query params instead of filter[domain_id]/filter[email_id], matching the public-api's updated contract. The public filter.domainId/filter.emailId option shape is unchanged. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
klotty
approved these changes
Aug 6, 2026
klotty
left a comment
There was a problem hiding this comment.
No issues found across 2 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Auto-approved: Focused fix aligning SDK wire format with the updated /emails/metrics API; the public SDK option shape is unchanged and tests pin the new flat params. No product, security, or operational tradeoff remains for human review.
Re-trigger cubic
gabrielmfern
approved these changes
Aug 7, 2026
gabrielmfern
pushed a commit
that referenced
this pull request
Aug 7, 2026
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
gabrielmfern
pushed a commit
that referenced
this pull request
Aug 7, 2026
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
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.
Summary
/emails/metricsendpoint now acceptsdomain_id/email_idas flat query params instead offilter[domain_id]/filter[email_id](resend/resend-monorepo#7974).buildMetricsQueryinsrc/emails/emails.tsto send the flat params. The public SDK option shape (filter: { domainId, emailId }) is unchanged — only the wire format sent to the API changed.Test plan
emails.spec.tsexpected request URLs to the flat param formatvitest run src/emails/emails.spec.ts— 33 passingbiome check— cleanSummary by cubic
Flattened
/emails/metricsquery params to usedomain_idandemail_idinstead offilter[domain_id]andfilter[email_id], matching the public API contract. UpdatedbuildMetricsQueryto send the flat params; the SDK option shape (filter: { domainId, emailId }) remains unchanged.Written for commit 2c23260. Summary will update on new commits.