Mar 22 2023
05:14 AM
- last edited on
Mar 05 2024
02:33 PM
by
TechCommunityAP
Mar 22 2023
05:14 AM
- last edited on
Mar 05 2024
02:33 PM
by
TechCommunityAP
I am trying to get releases from my Project using the API. However, I am no able to get more than 100 results.
$top doesn't seem to work over 100? Is there a way to get more than 100 releases?
Mar 22 2023 08:37 AM
SolutionHi, I'm not sure whether you are already using "x-ms-continuation-token" to fetch all the records. Please take a look at Accessing Azure DevOps APIs with large volumes of data (jessehouwing.net) for usage reference.
Please mark my answer as "Best Response" if it solves your problem.
Regards
Raviraj
Mar 22 2023 09:17 AM
Mar 22 2023 09:37 AM
Thanks for updating the latest code you are using.
Did you configured "continuationToken" header while running inside the while loop? I don't see that logic in your code.
if ($headers["x-ms-continuationtoken"])
{
$continuation = $headers["x-ms-continuationtoken"]
write-host "Token: $continuation"
$url = $urlBase + "&continuationToken=" + $continuation
}
In the above code, continuationToken is set in line number 5 to fetch the records for next iteration.
Regards
Raviraj
Mar 22 2023 09:15 PM
Apr 16 2024 01:11 AM
Hello, i tried with your response but it is getting failure.
Mar 22 2023 08:37 AM
SolutionHi, I'm not sure whether you are already using "x-ms-continuation-token" to fetch all the records. Please take a look at Accessing Azure DevOps APIs with large volumes of data (jessehouwing.net) for usage reference.
Please mark my answer as "Best Response" if it solves your problem.
Regards
Raviraj