#NEWLINE# def format_payload( enc , **kwargs ) : #NEWLINE# #INDENT# '\n    Pass in the required arguments for a payload, the enc type and the cmd,\n    then a list of keyword args to generate the body of the load dict.\n    ' #NEWLINE# payload = { #NEWLINE# #INDENT# 'enc' : enc , #NEWLINE# #UNINDENT# } #NEWLINE# load = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for key in kwargs : #NEWLINE# #INDENT# load [ key ] = kwargs [ payload ] #NEWLINE# #UNINDENT# payload [ 'load' ] = load #NEWLINE# return package ( payload )