linkedin-secret-sauce 0.3.25 → 0.3.26

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.
@@ -289,10 +289,18 @@ async function searchSalesLeads(keywords, options) {
289
289
  // Extract metadata.totalDisplayCount (LinkedIn's display string like "500K+")
290
290
  const metadataVal = rrec && 'metadata' in rrec ? rrec.metadata : undefined;
291
291
  const metadata = (metadataVal && typeof metadataVal === 'object') ? metadataVal : undefined;
292
+ // Calculate hasMore: if we got a full page of results, there may be more
293
+ // This is more reliable than relying on total, which is often undefined
294
+ const hasMore = items.length === count;
292
295
  const result = options
293
296
  ? {
294
297
  items,
295
- page: { start: Number(paging.start ?? start), count: Number(paging.count ?? count), total: paging?.total },
298
+ page: {
299
+ start: Number(paging.start ?? start),
300
+ count: Number(paging.count ?? count),
301
+ total: paging?.total,
302
+ hasMore
303
+ },
296
304
  metadata: metadata?.totalDisplayCount ? { totalDisplayCount: metadata.totalDisplayCount } : undefined,
297
305
  _meta: { sessionId } // Return sessionId to consumer
298
306
  }
package/dist/types.d.ts CHANGED
@@ -153,6 +153,7 @@ export interface SearchSalesResult {
153
153
  start: number;
154
154
  count: number;
155
155
  total?: number;
156
+ hasMore?: boolean;
156
157
  };
157
158
  metadata?: {
158
159
  totalDisplayCount?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "linkedin-secret-sauce",
3
- "version": "0.3.25",
3
+ "version": "0.3.26",
4
4
  "description": "Private LinkedIn Sales Navigator client with automatic cookie management",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",