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

add --follow-next option. #15

Merged
merged 2 commits into from
May 23, 2024
Merged

add --follow-next option. #15

merged 2 commits into from
May 23, 2024

Conversation

fujiwara
Copy link
Owner

--follow-next option

--follow-next (-f) option set the output/input field name of the next token. This option is useful for paginated APIs.

For example, s3#ListObjectsV2Output has NextContinuationToken field, and s3#ListObjectsV2Input has ContinuationToken field. You can follow the next token by the following command.

{FieldInOutput}={FieldInInput} format is used for --follow-next option.

$ aws-sdk-client-go s3 list-objects-v2 '{"Bucket": "my-bucket"}' \
  --follow-next NextContinuationToken=ContinuationToken

If the same field name is used in the output and input, you can omit the input field name.

$ aws-sdk-client-go ecs list-tasks '{"Cluster":"default"}' \
  --follow-next NextToken

@fujiwara fujiwara merged commit 8fa4bb9 into main May 23, 2024
4 checks passed
@fujiwara fujiwara deleted the next-token branch May 23, 2024 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant