Skip to content

Conversation

@Tietew
Copy link
Contributor

@Tietew Tietew commented May 2, 2024

Illuminate\Mail\Transport\SesV2Transport calls SESv2's SendEmail API but passes v1's Tags argument. The call doesn't fail but the tags are not attached to the sent email.
(ConfigurationSet events don't include specified tags)

This PR fixes the parameter name to correct EmailTags.

Notes:

  • Please don't confuse that SesTransport uses SES v1, which argument name is Tags.
  • Laravel 10.x has same issue. Backport will be needed.

Reference:

Steps:

class TestMail extends Mailable
{
    public function envelope(): Envelope
    {
        return new Envelope(subject: 'blah blah blah', metadata: ['Foo' => 'Bar']);
    }
}

The ConfigurationSet event Before:

{
    "eventType": "Delivery",
    "mail": {
        ...
        "tags": {
            "ses:operation": ["SendRawEmail"],
            ...
        }
    }, ...
}

After:

{
    "eventType": "Delivery",
    "mail": {
        ...
        "tags": {
            "ses:operation": ["SendRawEmail"],
            ...
            "Foo": ["Bar"] // <- HERE
        }
    }, ...
}

Related PR: #42390

@taylorotwell taylorotwell merged commit 4dcd347 into laravel:11.x May 2, 2024
func0der pushed a commit to func0der/framework that referenced this pull request May 6, 2024
@Tietew Tietew deleted the ses-transport-tags-argument branch May 9, 2024 07:27
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