def export_text(self, filename=None):
        """
        Export in text format. Optionally provide a filename to
        save to.
        
        :param str filename: path including filename (optional)
        :return: None
        """
        result = self.make_request(
            resource='export',
            params={'format': 'txt'},
            filename=filename,
            raw_result=True, 
            headers = {'accept': 'text/plain'})

        if not filename:
            return result.content
def export_text ( self , filename = None ) : result = self . make_request ( resource = 'export' , params = { 'format' : 'txt' } , filename = filename , raw_result = True , headers = { 'accept' : 'text/plain' } ) if not filename : return result . content
Export in text format. Optionally provide a filename to
        save to.
        
        :param str filename: path including filename (optional)
        :return: None