You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to use a pool to query multiple paginated endpoints at the same time. I haven't found anything in the documentation regarding this matter. I wonder how I could solve this (if possible) using the pool function.
Example:
I have a request IndexUserPosts that takes userId as input parameter. The response to that request is paginated.
I want to fetch all posts of users 10, 11and 12.
Without paginated endpoints the solution would be simple:
$pool = $connector->pool(
requests: function () use ($userIds) {
foreach ($userIdsas$userId) {
yield newIndexUserPosts($userId);
}
}
);
$pool->send()->wait();
But since the endpoints are paginated I would only get the first page for each user. Is there a way to solve this using saloon or do I have to implement it myself?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I want to use a pool to query multiple paginated endpoints at the same time. I haven't found anything in the documentation regarding this matter. I wonder how I could solve this (if possible) using the pool function.
Example:
IndexUserPosts
that takesuserId
as input parameter. The response to that request is paginated.10
,11
and12
.Without paginated endpoints the solution would be simple:
But since the endpoints are paginated I would only get the first page for each user. Is there a way to solve this using saloon or do I have to implement it myself?
Beta Was this translation helpful? Give feedback.
All reactions