def add_nylas_headers(msg, nylas_uid):
 msg.headers['X-INBOX-ID'] = nylas_uid
 msg.headers['Message-Id'] = generate_message_id_header(nylas_uid)
 msg.headers['User-Agent'] = 'NylasMailer/{0}'.format(VERSION)

def add_nylas_headers ( msg , nylas_uid ) : msg . headers [ 'X-INBOX-ID' ] = nylas_uid msg . headers [ 'Message-Id' ] = generate_message_id_header ( nylas_uid ) msg . headers [ 'User-Agent' ] = 'NylasMailer/{0}' . format ( VERSION )
set a custom x-inbox-id header so as to identify messages generated by nylas .