Discourse SMTP "X-MSYS-API 'campaign_id' is limited to 64 bytes"

change this line of code:

Or it can be solved from within line #143 at file : discourse/lib/email/sender.rb
@message.header[‘X-MSYS-API’] = { campaign_id: @message.message_id }.to_json

to this:

@message.header['X-MSYS-API'] = { campaign_id: @message.message_id[0..63] }.to_json

notice that i simply added the [0..63] keyword to cast the campaign id into 63 chars max. so it cannot be longer.

once u change that line, simply restart your discourse ./launcher restart app

and it should be working :slight_smile:

hope that helps.