You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Does anyone have any examples of how to page through memberentitlementmanagementSearchUserEntitlements() results? According to the docs a ContinuationToken should be used for paging, but that's not exposed in return value that I can see. I originally posted a thread here and was redirected to the github issues for this project. Thanks!
package main
import (
"context"
"os"
"github.com/microsoft/azure-devops-go-api/azuredevops/v7"
"github.com/microsoft/azure-devops-go-api/azuredevops/v7/memberentitlementmanagement"
)
func main() {
org := os.Getenv("AZURE_DEVOPS_ORGANIZATION_URL")
pat := os.Getenv("AZURE_DEVOPS_PERSONAL_ACCESS_TOKEN")
// Initialize the client
connection := azuredevops.NewPatConnection(org, pat)
client, _ := memberentitlementmanagement.NewClient(context.Background(), connection)
// Create search args
options := memberentitlementmanagement.SearchUserEntitlementsArgs{ContinuationToken: nil}
// Get the current page of results
response, _ := client.SearchUserEntitlements(context.Background(), options)
// This is an invalid parameter. Where can I get it?
if response.ContinuationToken != nil {
// we have all responses
} else {
// need to get the next page
}
}
The text was updated successfully, but these errors were encountered:
jbiel
changed the title
How to page through github.com/microsoft/azure-devops-go-api/azuredevops/v7/memberentitlementmanagement results?
How to page through memberentitlementmanagement SearchUserEntitlements() results?
Feb 18, 2025
Does anyone have any examples of how to page through
memberentitlementmanagement
SearchUserEntitlements()
results? According to the docs aContinuationToken
should be used for paging, but that's not exposed in return value that I can see. I originally posted a thread here and was redirected to the github issues for this project. Thanks!The text was updated successfully, but these errors were encountered: