SendGrid addHeader X-SMTPAPI

My PHP version is: 7.4.33
My problem is: Using the official SendGrid PHP Library on GitHub, I can not seem to send the header: X-SMTPAPI.

I have tried setting the basic PHP header(), The API’s addHeader() and the API’s addGlobalHeader() with no luck.

My php line is a very simply json string that looks like this:
$email->addHeader(‘X-SMTPAPI’, ‘{“unique_args”:{“id1”:"’.$id1.‘“,“id2”:”’.$id2.‘“,“id3”:”’.$id3.‘"}}’);

I get no errors, but for some reason SendGrid does not seem to process the header so I can use those variables later from the SendGrid Webhook.

Passing X-SMTPAPI this way from Ruby’s mailer works fine.

Note: I’m not 100% sure Muatic has anything to do with this I stumbled across a note somewhere suggesting to try here. Apologies if not your product.

Steps I have tried to fix the problem: There is very little help on the internet for this particular problem, other than one post I stumbled across suggesting it doesn’t work, but not specific as to why not.

Thanks in advance!