Esempio n. 1
0
	def changesetById (self, since ):
		postUri = "/_changesetById";
		__data__ = None
		queryParams = {  'since': since   };

		response = requests.get( self.base + postUri, params = queryParams, verify=False, headers = {'X-BM-ApiKey' : self.apiKey, 'Accept' : 'application/json', 'X-BM-ClientVersion' : IFolderHierarchy_VERSION}, data = json.dumps(__data__));
		from netbluemind.core.container.model.ContainerChangeset import ContainerChangeset
		from netbluemind.core.container.model.ContainerChangeset import __ContainerChangesetSerDer__
		return self.handleResult__(__ContainerChangesetSerDer__(serder.LONG), response)
Esempio n. 2
0
	def sync (self, since , changes ):
		postUri = "/_sync";
		__data__ = None
		from netbluemind.todolist.api.VTodoChanges import VTodoChanges
		from netbluemind.todolist.api.VTodoChanges import __VTodoChangesSerDer__
		__data__ = __VTodoChangesSerDer__().encode(changes)

		queryParams = {  'since': since    };

		response = requests.post( self.base + postUri, params = queryParams, verify=False, headers = {'X-BM-ApiKey' : self.apiKey, 'Accept' : 'application/json', 'X-BM-ClientVersion' : ITodoList_VERSION}, data = json.dumps(__data__));
		from netbluemind.core.container.model.ContainerChangeset import ContainerChangeset
		from netbluemind.core.container.model.ContainerChangeset import __ContainerChangesetSerDer__
		return self.handleResult__(__ContainerChangesetSerDer__(serder.STRING), response)