The custom_headers envelope documentation is misleading. Its not actually an "associative array", its a regular array of headers.
This is wrong:
<?php
$envelope = [
//...
"custom_headers" => [
"X-SES-CONFIGURATION-SET" => "example",
"X-SES-MESSAGE-TAGS" => "emailType=example"
]
];
?>
This is right:
<?php
$envelope = [
//...
"custom_headers" => [
"X-SES-CONFIGURATION-SET: example",
"X-SES-MESSAGE-TAGS: emailType=example"
]
];
?>