cli/pkg/cmd/api
Mislav Marohnić 63a4319f6c
api: output a single JSON array in REST pagination mode (#7190)
When fetching N pages, avoid printing N separate JSON arrays to the output stream. Instead, massage the output so that the N pages of data are merged into a single JSON array. This is achieved by omitting the final `]` for the first page, and omitting the initial `[` for all subsequent pages.
2023-06-09 20:55:06 +02:00
..
api.go api: output a single JSON array in REST pagination mode (#7190) 2023-06-09 20:55:06 +02:00
api_test.go api: output a single JSON array in REST pagination mode (#7190) 2023-06-09 20:55:06 +02:00
fields.go Supported passing nested JSON arrays/objects to api command via fields (#6614) 2022-12-22 20:12:00 +01:00
fields_test.go Supported passing nested JSON arrays/objects to api command via fields (#6614) 2022-12-22 20:12:00 +01:00
http.go force method to uppercase (#7514) 2023-06-01 13:54:56 +00:00
http_test.go force method to uppercase (#7514) 2023-06-01 13:54:56 +00:00
pagination.go api: output a single JSON array in REST pagination mode (#7190) 2023-06-09 20:55:06 +02:00
pagination_test.go Automatically add per_page=100 to paginated REST requests 2020-06-23 18:42:57 +02:00