feat: add received_for to received email type#122
Merged
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
1 issue found across 3 files
Confidence score: 4/5
- In
tests/Fixtures/Emails/Receiving.php,inboundEmails()is missingreceived_forwhileinboundEmail()includes it, so list-vs-single fixtures no longer model the same resource and tests can silently miss response-shape regressions—addreceived_fortoinboundEmails()before merging.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="tests/Fixtures/Emails/Receiving.php">
<violation number="1" location="tests/Fixtures/Emails/Receiving.php:17">
P2: inboundEmails() fixture is missing the 'received_for' field that was just added to inboundEmail(). These fixtures represent the same email resource; omitting it creates an inconsistency that can mask bugs in list-response handling.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
| 'bcc' => [], | ||
| 'cc' => [], | ||
| 'reply_to' => [], | ||
| 'received_for' => ['forwarded@example.com'], |
Contributor
There was a problem hiding this comment.
P2: inboundEmails() fixture is missing the 'received_for' field that was just added to inboundEmail(). These fixtures represent the same email resource; omitting it creates an inconsistency that can mask bugs in list-response handling.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At tests/Fixtures/Emails/Receiving.php, line 17:
<comment>inboundEmails() fixture is missing the 'received_for' field that was just added to inboundEmail(). These fixtures represent the same email resource; omitting it creates an inconsistency that can mask bugs in list-response handling.</comment>
<file context>
@@ -14,6 +14,7 @@ function inboundEmail(): array
'bcc' => [],
'cc' => [],
'reply_to' => [],
+ 'received_for' => ['forwarded@example.com'],
'message_id' => '<example+123>',
'attachments' => [
</file context>
jayanratna
approved these changes
Jun 26, 2026
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.
Adds the received_for field to the received email response type, matching the API.
Summary by cubic
Add
received_forto the received email response to match the API and expose forwarding recipients. Updated fixtures and service tests to include and assertreceived_for.Written for commit 14c361a. Summary will update on new commits.