@factorialco/api-client 3.0.0-beta.2026100108 → 3.0.0-beta.2026100110

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -153,6 +153,23 @@ const all = await client.employees.employees.all({ maxItems: 500 });
153
153
 
154
154
  Both `paginate()` and `all()` are available on every list endpoint.
155
155
 
156
+ ### High-volume retrieval
157
+
158
+ Pages are capped at **100 items** — a server-side hard max
159
+ ([pagination docs](https://apidoc.factorialhr.com/docs/pagination)); a larger
160
+ `limit` has no effect. Cursor pagination is sequential, so `all()` on a large
161
+ dataset issues one request per 100 records. For big pulls:
162
+
163
+ - Filter with the endpoint's query params (date ranges, `ids`, `employee_ids`, …)
164
+ instead of pulling everything.
165
+ - Sync incrementally where `updated_at`-style filters exist, and cache locally.
166
+ - Split one large query into filtered sub-queries (date windows, id chunks) and
167
+ run them concurrently with `Promise.all` — faster wall-clock, same total
168
+ request count, so mind rate limits.
169
+ - Pass `maxItems` as a safety cap.
170
+
171
+ There is no server-side aggregation endpoint; compute totals client-side.
172
+
156
173
  ## Error handling
157
174
 
158
175
  The client is configured with `throwOnError: true`, so any non-2xx response