Question: How do I construct the delta research query ?
This library looks like lacking many more examples of less simplistic queries using graph api for Python .
I am trying to understand how I can delta sync the data using DeltaRequestBuilder that is advocated so much in the documentation, but after installing this package I cannot even find how to import this module from msgraph.
I know I can use another library msgraph-core but it is not ideal either and most examples in Microsoft docs exemplify this library. They do not, however, direct to some comprehensive documentation (or I did not find this).
Beyond that, for my pipeline I need to know how do I rewrite the following HTTP call in the modules of this library:
f"/users/{user_principal_name}/drive/root:/{FolderName}:/children".
Thanks in advance for any response.
I had the same problem as you. If we look at the following example in the API docs:
graph_client = GraphServiceClient(credentials, scopes)
request_configuration = DeltaRequestBuilder.DeltaRequestBuilderGetRequestConfiguration()
request_configuration.headers.add("Prefer", "odata.maxpagesize=2")
result = await graph_client.me.mail_folders.by_mail_folder_id('mailFolder-id').messages.delta.get(request_configuration = request_configuration)
For me changing this to the following works:
graph_client = GraphServiceClient(credentials, scopes)
request_configuration = graph_client.me.mail_folders.delta.DeltaRequestBuilderGetRequestConfiguration()
request_configuration.headers.add("Prefer", "odata.maxpagesize=2")
result = await graph_client.me.mail_folders.by_mail_folder_id('mailFolder-id').messages.delta.get(request_configuration = request_configuration)
Thanks for the specific case.
The biggest problem in my case (what prevents me on elaborating on your case) is that my access is permissionless,
so if I get it correctly I cannot use just me.
Btw, my particular case was resolved by constructing a request via link with msgraph-core ÷÷÷