Allow parsing of a two dimensional list for controlling the order of headers

Updated to use a generator with a default of None since we wouldn't want to append the actionid to message if it was already present in message.