(self)
return error.check_return_status(response, logger)
Commit the story to the server.
Commit the story to the server.
Commit the story to the server .
def commit(self):
        """Commit the story to the server."""
        content_list = [x.to_dict() for x in self._blocks]
        content = json.dumps(content_list)

        data = {
            'title': self.title,
            'content': content,
        }
        response = self._api.session.post(
            '{0:s}/{1:s}'.format(self._api.api_root, self.resource_uri),
            json=data)

        return error.check_return_status(response, logger)
def commit ( self ) : content_list = [ x . to_dict ( ) for x in self . _blocks ] content = json . dumps ( content_list ) data = { 'title' : self . title , 'content' : content , } response = self . _api . session . post ( '{0:s}/{1:s}' . format ( self . _api . api_root , self . resource_uri ) , json = data ) return error . check_return_status ( response , logger )