def prepare_headers(self, http_headers, soap_action):
        """Prepare the http headers for sending.

        Add the SOAPACTION header to the others.

        Args:
            http_headers (dict): A dict in the form {'Header': 'Value,..}
                containing http headers to use for the http request.
            soap_action (str): The value of the SOAPACTION header.

        Returns:
            dict: headers including the SOAPACTION header.
        """

        headers = {'Content-Type': 'text/xml; charset="utf-8"'}
        if soap_action is not None:
            headers.update({'SOAPACTION': '"{}"'.format(soap_action)})
        if http_headers is not None:
            headers.update(http_headers)
        return headers
def prepare_headers ( self , http_headers , soap_action ) : headers = { 'Content-Type' : 'text/xml; charset="utf-8"' } if soap_action is not None : headers . update ( { 'SOAPACTION' : '"{}"' . format ( soap_action ) } ) if http_headers is not None : headers . update ( http_headers ) return headers
Prepare the http headers for sending.

        Add the SOAPACTION header to the others.

        Args:
            http_headers (dict): A dict in the form {'Header': 'Value,..}
                containing http headers to use for the http request.
            soap_action (str): The value of the SOAPACTION header.

        Returns:
            dict: headers including the SOAPACTION header.