Title
#fleet
e

Edward

05/09/2021, 9:19 PM
Is there sample code (preferably in golang) available somewhere, on how to properly consume all pages/results from an api endpoint like
GET /api/v1/fleet/hosts?page=0&per_page=100&order_key=host_name
?
sundsta

sundsta

05/10/2021, 7:30 PM
The
fleetctl
utility would be a good example
Noah Talerman

Noah Talerman

05/11/2021, 3:16 PM
@Edward what do you mean by “consume?” Are you trying to place the results in some sort of datastore?
e

Edward

05/11/2021, 3:31 PM
yes, that's correct, I want to get all hosts place their information in a datastore. So I would need to make http get request calls page by page right?