def _loop_payload(params):
 payload = {}
 for (param, value) in six.iteritems(params):
  if (value is not None):
   payload[param] = value
 return payload

def _loop_payload ( params ) : payload = { } for ( param , value ) in six . iteritems ( params ) : if ( value is not None ) : payload [ param ] = value return payload
pass in a dictionary of parameters .