Snippet generation should lead to use with url for next and skip tokens parameters in url
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
Research direction
Start at graphClient.Users().Delta() and inspect DeltaRequestBuilderGetQueryParameters, then compare its available parameters with the linked Microsoft Delta Query documentation. Determine how the SDK should expose skip-token and delta-token handling; done means the documented Go delta-query flow is supported and can paginate successfully.
Written by the indexing model from the issue text.
Description
Describe the bug
I’m trying to query users with the Delta API in the Go SDK, but examples in Microsoft documentation don’t match available SDK entities.
Detailed Description:
From the Microsoft Delta Query Documentation:
// Documentation example for Delta queries
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
graphusers "github.com/microsoftgraph/msgraph-sdk-go/users"
)
requestSkiptoken := "oEBwdSP6uehIAxQOWq_3Ksh_TLol6KIm3stvdc6hGhZRi1hQ7Spe__dpvm3U4zReE4CYXC2zOtaKdi7KHlUtC2CbRiBIUwOxPKLa"
requestParameters := &graphusers.UsersDeltaWithRequestBuilderGetQueryParameters{
Skiptoken: &requestSkiptoken,
}
configuration := &graphusers.UsersDeltaWithRequestBuilderGetRequestConfiguration{
QueryParameters: requestParameters,
}
delta, err := graphClient.Users().Delta().GetAsDeltaGetResponse(context.Background(), configuration)
In the SDK, UsersDeltaWithRequestBuilderGetQueryParameters isn’t available. The closest alternative, DeltaRequestBuilderGetQueryParameters, lacks a Skiptoken field:
type DeltaRequestBuilderGetQueryParameters struct {
Count *bool `uriparametername:"%24count"`
Expand []string `uriparametername:"%24expand"`
Filter *string `uriparametername:"%24filter"`
Orderby []string `uriparametername:"%24orderby"`
Search *string `uriparametername:"%24search"`
Select []string `uriparametername:"%24select"`
Skip *int32 `uriparametername:"%24skip"`
Top *int32 `uriparametername:"%24top"`
}
Additional Attempt:
I tried direct request configuration using the following code, but without success:
response, err := graphClient.GetClient().GetAdapter().Send(ctx, requestInfo, models.CreateUserCollectionResponseFromDiscriminatorValue, nil)
if err != nil {
log.Fatalf("Error making direct request: %v", err)
}
Without access to Skiptoken or guidance on retrieving deltaToken, it’s challenging to perform delta queries effectively.
Expected behavior
The Go SDK should provide delta query support equivalent to the documentation examples, including options for Skiptoken and deltaToken handling. This would allow developers to correctly paginate through delta queries and manage state with each request, ensuring alignment with other Microsoft Graph SDKs.
How to reproduce
How to Reproduce:
- Set up a graphClient in Go using the Microsoft Graph Go SDK.
- Attempt a Delta query to list users using the following configuration in your code:
requestParameters := &graphusers.UsersDeltaWithRequestBuilderGetQueryParameters{
Skiptoken: &requestSkiptoken, // Expecting Skiptoken field here
}
configuration := &graphusers.UsersDeltaWithRequestBuilderGetRequestConfiguration{
QueryParameters: requestParameters,
}
delta, err := graphClient.Users().Delta().GetAsDeltaGetResponse(context.Background(), configuration)
- Observe that UsersDeltaWithRequestBuilderGetQueryParameters is missing in the SDK, and Skiptoken cannot be added.
SDK Version
1.51.0
Latest version known to work for scenario above?
No response
Known Workarounds
No response
Debug output
Click to expand log
```</details>
### Configuration
_No response_
### Other information
_No response_
- Dominant language
- Go
- Stars
- 335
- Forks
- 43
- Avg merge
- 12h 7m
- Merged PRs (30d)
- 2
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoftgraph/msgraph-sdk-go
-
ItemItemsItemPermanentDeleteRequestBuilderInternal.Post missing content body/content-type headersOpenstatus:waiting-for-triage type:bug
Difficulty 3/5 1-2 days Newbie friendliness 48/100
microsoftgraph/msgraph-sdk-go#980 ·
Maintainers usually reply within 1 day
-
status:waiting-for-triage type:bug
Difficulty 4/5 3-5 days Newbie friendliness 35/100
microsoftgraph/msgraph-sdk-go#972 ·
Maintainers usually reply within 1 day
-
status:waiting-for-triage type:bug
Difficulty 3/5 1-2 days Newbie friendliness 45/100
microsoftgraph/msgraph-sdk-go#969 · 1 comment ·
Maintainers usually reply within 1 day
-
status:waiting-for-triage type:feature
Difficulty 3/5 1-2 days Newbie friendliness 45/100
microsoftgraph/msgraph-sdk-go#964 ·
Maintainers usually reply within 1 day
-
status:waiting-for-triage type:feature
Difficulty 5/5 Over a week Newbie friendliness 20/100
microsoftgraph/msgraph-sdk-go#940 · 1 comment ·
Maintainers usually reply within 1 day
All issues in microsoftgraph/msgraph-sdk-go
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
golang/go#82033 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 1-3 hours Newbie friendliness 90/100
FootprintAI/Containarium#2338 ·
Maintainers usually reply within 1 day
-
[Bug]: core doesn't build standalone on dev since a17068054 (go-mp3 require dropped, go.sum pruned)Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
SagerNet/sing-openvpn#11 ·
-
priority: P3 type: devops
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
jiegui2025/hwspec#57 ·
Maintainers usually reply within 1 day