Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for paging using az devops invoke when continuation token is in header #1112

Closed
Tiberriver256 opened this issue Mar 22, 2021 · 3 comments · Fixed by #1243
Closed
Assignees
Labels
Feature Feature Work required. Requires API upgrade The fix for the issue requires the new higher version of Rest APIs.

Comments

@Tiberriver256
Copy link

Example command:

az devops invoke --area distributedtask --resource jobrequests --route-parameters poolId={myPoolId} --organization {myOrg} --query-parameters `$top=1

will translation to the following URL:

{myOrg}/_apis/distributedtask/pools/{myPoolId}/jobrequests?$top=1

This works as expected and returns a JSON response to the console. The problem is that, if I need to get to the next page, the server sends the continuation token as a header instead of embedded in the JSON body response and az devops invoke doesn't expose response headers at all, that I can see.

@Tiberriver256 Tiberriver256 added the Feature Feature Work required. label Mar 22, 2021
@roshan-sy roshan-sy added Requires API upgrade The fix for the issue requires the new higher version of Rest APIs. and removed Requires API upgrade The fix for the issue requires the new higher version of Rest APIs. labels Jan 18, 2022
@roshan-sy
Copy link
Contributor

Looks like API do not support continuation token.

@Tiberriver256
Can you please check

@roshan-sy roshan-sy added the Requires API upgrade The fix for the issue requires the new higher version of Rest APIs. label Jan 24, 2022
@Tiberriver256
Copy link
Author

Hi roshan, sorry for the confusion. Could you use the build definitions list endpoint as an example?

https://docs.microsoft.com/en-us/rest/api/azure/devops/build/definitions/list?view=azure-devops-rest-6.0

There are several endpoints that use the continuation token in the header as a paging mechanism so I can pick another if you like.

@roshan-sy
Copy link
Contributor

Fixed.

Will be available after next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Feature Work required. Requires API upgrade The fix for the issue requires the new higher version of Rest APIs.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants