mcp-scraper 0.95.2 → 0.96.0

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.
Files changed (121) hide show
  1. package/CHANGELOG.md +48 -1
  2. package/README.md +19 -3
  3. package/dist/actions-YCMJY3PF.js +1 -0
  4. package/dist/artifacts-4ZDNP2JW.js +1 -0
  5. package/dist/artifacts-N62OPIT5.js +1 -0
  6. package/dist/artifacts-PSADD5OC.js +1 -0
  7. package/dist/artifacts-RUR3OHAK.js +1 -0
  8. package/dist/bin/api-server.js +1 -1
  9. package/dist/bin/mcp-scraper-cli.js +22 -22
  10. package/dist/bin/mcp-scraper-core.js +1 -1
  11. package/dist/bin/mcp-scraper-install.js +1 -1
  12. package/dist/bin/mcp-stdio-server.js +1 -1
  13. package/dist/bin/paa-harvest.js +1 -1
  14. package/dist/blob-store-GIH26EDO.js +1 -0
  15. package/dist/bundle-TTJP6DHU.js +1 -0
  16. package/dist/chunk-24YDQ3EO.js +5 -0
  17. package/dist/chunk-2PRH4Z3N.js +181 -0
  18. package/dist/chunk-3F7AFM53.js +1 -0
  19. package/dist/chunk-4HZXATHB.js +27 -0
  20. package/dist/chunk-55ZANTHL.js +3 -0
  21. package/dist/chunk-5BKSKLHX.js +1 -0
  22. package/dist/chunk-63VWBMYR.js +3 -0
  23. package/dist/chunk-6N5EC7ZO.js +1 -0
  24. package/dist/chunk-6SNOUSSZ.js +182 -0
  25. package/dist/chunk-7POHNTVW.js +1 -0
  26. package/dist/chunk-7SR7MEU5.js +62 -0
  27. package/dist/chunk-7UHDOIUE.js +1 -0
  28. package/dist/chunk-ARSQZCTJ.js +945 -0
  29. package/dist/chunk-B3JRL45T.js +1 -0
  30. package/dist/chunk-B4ZKPLSP.js +1 -0
  31. package/dist/chunk-C7MGJUTU.js +1 -0
  32. package/dist/{chunk-W2BVJ7S2.js → chunk-CNSVZTTT.js} +4 -4
  33. package/dist/chunk-DGAW7FD7.js +12 -0
  34. package/dist/chunk-FRXKMOXI.js +41 -0
  35. package/dist/chunk-GVYGAZV7.js +1 -0
  36. package/dist/chunk-HCK6PLM3.js +3 -0
  37. package/dist/{chunk-Y3Q4FIKK.js → chunk-HJIOH7HF.js} +199 -84
  38. package/dist/chunk-HNNYXMSI.js +1 -0
  39. package/dist/chunk-HUNSEGUN.js +57 -0
  40. package/dist/chunk-IFPION5D.js +121 -0
  41. package/dist/{chunk-MC4W6TZT.js → chunk-JAV5V3JT.js} +41 -8
  42. package/dist/chunk-JMZIDHYQ.js +2 -0
  43. package/dist/{chunk-ENZUJEIM.js → chunk-JW4GDY7S.js} +1 -1
  44. package/dist/chunk-KXJCGV3H.js +1 -0
  45. package/dist/chunk-LFRAA3MY.js +4 -0
  46. package/dist/chunk-MVMWPKRC.js +2 -0
  47. package/dist/chunk-NALXKTUU.js +1 -0
  48. package/dist/chunk-NNOX3FYG.js +198 -0
  49. package/dist/chunk-OB6E6UTD.js +1 -0
  50. package/dist/chunk-OILOHQNL.js +2 -0
  51. package/dist/chunk-OLYPLX5C.js +1 -0
  52. package/dist/chunk-QER2ELZP.js +1 -0
  53. package/dist/chunk-QWE7VKIX.js +1 -0
  54. package/dist/chunk-R5LJL6IR.js +225 -0
  55. package/dist/chunk-RDHGQ2WZ.js +1 -0
  56. package/dist/chunk-SDQW7IJN.js +1 -0
  57. package/dist/chunk-SEZETSB3.js +1 -0
  58. package/dist/chunk-SNJR5N36.js +1 -0
  59. package/dist/chunk-TPN25AFZ.js +159 -0
  60. package/dist/chunk-UIOSADPB.js +1718 -0
  61. package/dist/{chunk-ZH75KWBI.js → chunk-UNEJYZ4T.js} +1 -1
  62. package/dist/chunk-VAC3SQ5T.js +16 -0
  63. package/dist/{chunk-VREXSMC6.js → chunk-VVSHZV5S.js} +5 -5
  64. package/dist/chunk-WNUXMPVX.js +1 -0
  65. package/dist/chunk-WP3QS4CJ.js +1 -0
  66. package/dist/chunk-ZPQNY5TI.js +1 -0
  67. package/dist/contracts-GUXGFCVV.js +1 -0
  68. package/dist/core-schema-423BSTE6.js +936 -0
  69. package/dist/dispatch-3HY4735M.js +1 -0
  70. package/dist/index.cjs +104 -214
  71. package/dist/index.d.cts +181 -169
  72. package/dist/index.d.ts +181 -169
  73. package/dist/index.js +1 -1
  74. package/dist/media-artifacts-67CJWI7O.js +1 -0
  75. package/dist/metering-ZH2P62IC.js +1 -0
  76. package/dist/migrations-3AKEC5QE.js +1 -0
  77. package/dist/queue-HUP2GNXF.js +1 -0
  78. package/dist/reconciliation-ANXNJWME.js +1 -0
  79. package/dist/report-artifact-offload-6OOY2PTM.js +1 -0
  80. package/dist/repository-4EC5EXVN.js +1 -0
  81. package/dist/{location-data-repository-A2QZVP7O.js → repository-CYXVMYAI.js} +1 -1
  82. package/dist/server-VQU6S24A.js +5825 -0
  83. package/dist/settlement-6CCE2PDH.js +1 -0
  84. package/dist/worker-5G5BK23B.js +1 -0
  85. package/package.json +2 -2
  86. package/dist/analytics-repository-DZZKDZL6.js +0 -1
  87. package/dist/chunk-6DRKDSXY.js +0 -182
  88. package/dist/chunk-6ND5AFV5.js +0 -27
  89. package/dist/chunk-7XDBGQDY.js +0 -6
  90. package/dist/chunk-7YOXSMHG.js +0 -1565
  91. package/dist/chunk-BLVBUMH5.js +0 -21
  92. package/dist/chunk-EDQ57S4P.js +0 -1
  93. package/dist/chunk-GLTECY3U.js +0 -1282
  94. package/dist/chunk-GPSPSJBJ.js +0 -1
  95. package/dist/chunk-HE45FFBU.js +0 -1
  96. package/dist/chunk-HUV2WTRW.js +0 -1
  97. package/dist/chunk-IXJQHXDC.js +0 -2595
  98. package/dist/chunk-K3D2S36Q.js +0 -16
  99. package/dist/chunk-KFOFU3LA.js +0 -1
  100. package/dist/chunk-LMWU7VPZ.js +0 -63
  101. package/dist/chunk-O4LUUIYG.js +0 -4
  102. package/dist/chunk-OLSW4AN4.js +0 -19
  103. package/dist/chunk-RLFCJGHA.js +0 -100
  104. package/dist/chunk-T4VTJNDZ.js +0 -84
  105. package/dist/chunk-TMB56NCA.js +0 -1
  106. package/dist/chunk-VXOXB3IB.js +0 -1
  107. package/dist/chunk-WO3N5FH2.js +0 -5
  108. package/dist/chunk-WO46LTBW.js +0 -1
  109. package/dist/chunk-XPEJB4BZ.js +0 -1
  110. package/dist/db-CDEZHBRN.js +0 -1
  111. package/dist/extract-bundle-SXC6EWJR.js +0 -26
  112. package/dist/gmail-service-EWR76XE7.js +0 -1
  113. package/dist/lead-list-enrichment-repository-SIWGXWQV.js +0 -1
  114. package/dist/operation-metering-UJ53YX7S.js +0 -1
  115. package/dist/server-QVEKDIDQ.js +0 -5014
  116. package/dist/site-extract-repository-23ND4N77.js +0 -1
  117. package/dist/stripe-event-worker-LPXTITVC.js +0 -1
  118. package/dist/worker-EDN2TJH3.js +0 -1
  119. /package/dist/{chunk-YGBTTW5D.js → chunk-2IATUJO6.js} +0 -0
  120. /package/dist/{chunk-6DTXIZY2.js → chunk-4ZVO6GX4.js} +0 -0
  121. /package/dist/{chunk-XG6GCEUE.js → chunk-U4WIJZCX.js} +0 -0
package/dist/index.d.cts CHANGED
@@ -3,6 +3,103 @@ import { z } from 'zod';
3
3
  declare const SERP_FEATURE_COMPLETENESS_STATES: readonly ["observed_present", "observed_absent", "incomplete", "not_requested", "unknown", "unsupported"];
4
4
  type SerpFeatureCompletenessState = typeof SERP_FEATURE_COMPLETENESS_STATES[number];
5
5
 
6
+ type SerpLinkType = 'plain' | 'google_url_redirect' | 'google_goto_redirect';
7
+ type SerpLinkResolutionStatus = 'not_needed' | 'resolved' | 'unresolved' | 'rejected';
8
+ interface SerpOutboundLink {
9
+ url: string;
10
+ rawUrl: string;
11
+ resolvedUrl: string | null;
12
+ linkType: SerpLinkType;
13
+ resolutionStatus: SerpLinkResolutionStatus;
14
+ }
15
+ interface VideoResult {
16
+ type: 'video' | 'short_video';
17
+ title: string;
18
+ channel: string;
19
+ platform: string;
20
+ duration: string;
21
+ url: string;
22
+ }
23
+ interface ForumResult {
24
+ title: string;
25
+ source: string;
26
+ url: string;
27
+ }
28
+ interface WhatPeopleSayingCard {
29
+ type: 'reddit' | 'facebook' | 'instagram' | 'tiktok' | 'youtube' | 'news' | 'unknown';
30
+ title: string;
31
+ url: string;
32
+ source: string;
33
+ platform: string;
34
+ popularComment: string | null;
35
+ engagement: string;
36
+ date: string;
37
+ duration: string | null;
38
+ authorNote: string | null;
39
+ }
40
+ interface AICitation {
41
+ text: string;
42
+ href: string;
43
+ rawUrl: string;
44
+ resolvedUrl: string | null;
45
+ linkType: SerpLinkType;
46
+ resolutionStatus: SerpLinkResolutionStatus;
47
+ }
48
+ interface AIOverviewResult {
49
+ detected: boolean;
50
+ text: string | null;
51
+ citations: AICitation[];
52
+ expanded?: boolean;
53
+ fullyExpanded?: boolean;
54
+ sections?: string[];
55
+ shareUrl?: string | null;
56
+ }
57
+ interface AIModeResult {
58
+ detected: boolean;
59
+ text: string | null;
60
+ citations: AICitation[];
61
+ }
62
+ type GoogleSurface = 'web' | 'aim' | 'unknown';
63
+ interface OrganicResult {
64
+ position: number;
65
+ title: string;
66
+ url: string;
67
+ rawUrl: string;
68
+ resolvedUrl: string | null;
69
+ linkType: SerpLinkType;
70
+ resolutionStatus: SerpLinkResolutionStatus;
71
+ domain: string;
72
+ cite: string | null;
73
+ snippet: string | null;
74
+ isRedditStyle: boolean;
75
+ inlineRating: {
76
+ value: string;
77
+ count: string;
78
+ } | null;
79
+ }
80
+ interface LocalPackBusiness {
81
+ position: number;
82
+ name: string;
83
+ cid: string | null;
84
+ rating: string | null;
85
+ reviewCount: string | null;
86
+ metadata: string[];
87
+ websiteUrl: string | null;
88
+ directionsUrl: string | null;
89
+ }
90
+ interface EntityRecord {
91
+ name: string;
92
+ kgId: string | null;
93
+ cid: string | null;
94
+ gcid: string | null;
95
+ }
96
+ interface EntityIds {
97
+ entities: EntityRecord[];
98
+ kgIds: string[];
99
+ cids: string[];
100
+ gcids: string[];
101
+ }
102
+
6
103
  interface SerpPreviewQuestion {
7
104
  question: string;
8
105
  answer: string | null;
@@ -49,9 +146,9 @@ declare const HarvestOptionsSchema: z.ZodObject<{
49
146
  mobile: "mobile";
50
147
  }>>;
51
148
  proxyMode: z.ZodDefault<z.ZodEnum<{
52
- none: "none";
53
149
  location: "location";
54
150
  configured: "configured";
151
+ none: "none";
55
152
  }>>;
56
153
  proxyZip: z.ZodOptional<z.ZodString>;
57
154
  keepDefaultProxy: z.ZodOptional<z.ZodBoolean>;
@@ -182,6 +279,8 @@ interface PaaProgressSnapshot {
182
279
  interface PaaSource extends SerpOutboundLink {
183
280
  title: string | null;
184
281
  site: string | null;
282
+ /** Description displayed in the Google source card, when observed. */
283
+ description?: string | null;
185
284
  }
186
285
  interface PAANode {
187
286
  questionId: string;
@@ -189,6 +288,8 @@ interface PAANode {
189
288
  googleEvidenceId: string | null;
190
289
  question: string;
191
290
  answer: string | null;
291
+ /** A remaining inner answer control could not be expanded within the capture budget. */
292
+ answerExpansionIncomplete?: boolean;
192
293
  sourceTitle: string | null;
193
294
  sourceSite: string | null;
194
295
  sourceCite: string | null;
@@ -204,6 +305,7 @@ interface FlatRow {
204
305
  google_evidence_id: string;
205
306
  question: string;
206
307
  answer: string;
308
+ answerExpansionIncomplete?: boolean;
207
309
  source_title: string;
208
310
  source_site: string;
209
311
  source_cite: string;
@@ -217,6 +319,7 @@ type HarvestOptions = z.infer<typeof HarvestOptionsSchema>;
217
319
  type CanonicalLocationName = string;
218
320
  type SerpDevice = 'desktop' | 'mobile';
219
321
  type ProxyMode = 'location' | 'configured' | 'none';
322
+
220
323
  interface \u004b\u0065\u0072\u006e\u0065\u006cLocationProxyTarget {
221
324
  canonicalLocation: CanonicalLocationName;
222
325
  level: 'zip' | 'city' | 'state';
@@ -244,6 +347,82 @@ interface \u004b\u0065\u0072\u006e\u0065\u006cProxyResolutionDebug {
244
347
  error: string | null;
245
348
  disposable?: boolean;
246
349
  }
350
+
351
+ interface BrowserNetworkLocationDebug {
352
+ source: 'ipapi.co' | 'ipwho.is' | 'api64.ipify.org';
353
+ ip: string | null;
354
+ city: string | null;
355
+ region: string | null;
356
+ country: string | null;
357
+ org: string | null;
358
+ timezone: string | null;
359
+ error: string | null;
360
+ }
361
+ interface \u004b\u0065\u0072\u006e\u0065\u006cSessionDebug {
362
+ sessionId: string | null;
363
+ proxyMode: ProxyMode;
364
+ requestedProxyIdPresent: boolean;
365
+ requestedProxyIdSuffix: string | null;
366
+ createdProxyIdPresent: boolean | null;
367
+ createdProxyIdSuffix: string | null;
368
+ retrievedProxyIdPresent: boolean | null;
369
+ retrievedProxyIdSuffix: string | null;
370
+ retrievedProxyIdMatchesRequested: boolean | null;
371
+ defaultProxyDisabled: boolean | null;
372
+ defaultProxyDisableError: string | null;
373
+ proxyResolution: \u004b\u0065\u0072\u006e\u0065\u006cProxyResolutionDebug | null;
374
+ timeoutSeconds: number | null;
375
+ stealth: boolean | null;
376
+ profilePresent: boolean | null;
377
+ poolPresent: boolean | null;
378
+ retrieveError: string | null;
379
+ }
380
+ interface BrowserContextDebug {
381
+ viewport: {
382
+ width: number;
383
+ height: number;
384
+ } | null;
385
+ locale: string | null;
386
+ device: SerpDevice;
387
+ requestedDevice?: SerpDevice;
388
+ userAgent: string | null;
389
+ deviceScaleFactor: number | null;
390
+ isMobile: boolean;
391
+ hasTouch: boolean;
392
+ }
393
+ interface SerpNavigationDebug {
394
+ requestedUrl: string;
395
+ finalUrl: string | null;
396
+ title: string | null;
397
+ bodySnippet: string | null;
398
+ hasPaa: boolean | null;
399
+ captchaDetected: boolean | null;
400
+ googleSorryUrl: boolean | null;
401
+ redirected: boolean | null;
402
+ }
403
+ interface BrowserDebugSnapshot {
404
+ \u006b\u0065\u0072\u006e\u0065\u006c: \u004b\u0065\u0072\u006e\u0065\u006cSessionDebug | null;
405
+ context: BrowserContextDebug | null;
406
+ networkLocation: BrowserNetworkLocationDebug | null;
407
+ serpNavigation: SerpNavigationDebug | null;
408
+ }
409
+
410
+ interface SerpLocationCandidate {
411
+ city: string;
412
+ regionCode: string;
413
+ count: number;
414
+ examples: string[];
415
+ }
416
+ interface SerpLocationEvidence {
417
+ status: 'not_requested' | 'matched' | 'mismatch' | 'unknown';
418
+ expected: {
419
+ city: string;
420
+ regionCode: string | null;
421
+ canonicalLocation: string;
422
+ } | null;
423
+ candidates: SerpLocationCandidate[];
424
+ }
425
+
247
426
  interface HarvestStats {
248
427
  seed: string;
249
428
  totalQuestions: number;
@@ -270,6 +449,7 @@ interface HarvestDiagnosticWarning {
270
449
  interface HarvestCompleteness {
271
450
  paaWithoutAnswer: number;
272
451
  paaWithoutSource: number;
452
+ paaIncompleteAnswers?: number;
273
453
  paaAnswersRecovered: number;
274
454
  aioShareCaptured: boolean | null;
275
455
  paaRequested?: number;
@@ -329,78 +509,6 @@ interface HarvestLinkDiagnostics {
329
509
  paaSourcesPreserved: number;
330
510
  aiOverviewLabelValidated: boolean;
331
511
  }
332
- interface BrowserNetworkLocationDebug {
333
- source: 'ipapi.co' | 'ipwho.is' | 'api64.ipify.org';
334
- ip: string | null;
335
- city: string | null;
336
- region: string | null;
337
- country: string | null;
338
- org: string | null;
339
- timezone: string | null;
340
- error: string | null;
341
- }
342
- interface \u004b\u0065\u0072\u006e\u0065\u006cSessionDebug {
343
- sessionId: string | null;
344
- proxyMode: ProxyMode;
345
- requestedProxyIdPresent: boolean;
346
- requestedProxyIdSuffix: string | null;
347
- createdProxyIdPresent: boolean | null;
348
- createdProxyIdSuffix: string | null;
349
- retrievedProxyIdPresent: boolean | null;
350
- retrievedProxyIdSuffix: string | null;
351
- retrievedProxyIdMatchesRequested: boolean | null;
352
- defaultProxyDisabled: boolean | null;
353
- defaultProxyDisableError: string | null;
354
- proxyResolution: \u004b\u0065\u0072\u006e\u0065\u006cProxyResolutionDebug | null;
355
- timeoutSeconds: number | null;
356
- stealth: boolean | null;
357
- profilePresent: boolean | null;
358
- poolPresent: boolean | null;
359
- retrieveError: string | null;
360
- }
361
- interface BrowserContextDebug {
362
- viewport: {
363
- width: number;
364
- height: number;
365
- };
366
- locale: string;
367
- device: SerpDevice;
368
- userAgent: string | null;
369
- deviceScaleFactor: number | null;
370
- isMobile: boolean;
371
- hasTouch: boolean;
372
- }
373
- interface SerpNavigationDebug {
374
- requestedUrl: string;
375
- finalUrl: string | null;
376
- title: string | null;
377
- bodySnippet: string | null;
378
- hasPaa: boolean | null;
379
- captchaDetected: boolean | null;
380
- googleSorryUrl: boolean | null;
381
- redirected: boolean | null;
382
- }
383
- interface BrowserDebugSnapshot {
384
- \u006b\u0065\u0072\u006e\u0065\u006c: \u004b\u0065\u0072\u006e\u0065\u006cSessionDebug | null;
385
- context: BrowserContextDebug | null;
386
- networkLocation: BrowserNetworkLocationDebug | null;
387
- serpNavigation: SerpNavigationDebug | null;
388
- }
389
- interface SerpLocationCandidate {
390
- city: string;
391
- regionCode: string;
392
- count: number;
393
- examples: string[];
394
- }
395
- interface SerpLocationEvidence {
396
- status: 'not_requested' | 'matched' | 'mismatch' | 'unknown';
397
- expected: {
398
- city: string;
399
- regionCode: string | null;
400
- canonicalLocation: string;
401
- } | null;
402
- candidates: SerpLocationCandidate[];
403
- }
404
512
  interface HarvestDebugSnapshot {
405
513
  enabled: true;
406
514
  request: {
@@ -423,102 +531,6 @@ interface HarvestDebugSnapshot {
423
531
  browser: BrowserDebugSnapshot;
424
532
  locationEvidence?: SerpLocationEvidence;
425
533
  }
426
- type SerpLinkType = 'plain' | 'google_url_redirect' | 'google_goto_redirect';
427
- type SerpLinkResolutionStatus = 'not_needed' | 'resolved' | 'unresolved' | 'rejected';
428
- interface SerpOutboundLink {
429
- url: string;
430
- rawUrl: string;
431
- resolvedUrl: string | null;
432
- linkType: SerpLinkType;
433
- resolutionStatus: SerpLinkResolutionStatus;
434
- }
435
- interface VideoResult {
436
- type: 'video' | 'short_video';
437
- title: string;
438
- channel: string;
439
- platform: string;
440
- duration: string;
441
- url: string;
442
- }
443
- interface ForumResult {
444
- title: string;
445
- source: string;
446
- url: string;
447
- }
448
- interface WhatPeopleSayingCard {
449
- type: 'reddit' | 'facebook' | 'instagram' | 'tiktok' | 'youtube' | 'news' | 'unknown';
450
- title: string;
451
- url: string;
452
- source: string;
453
- platform: string;
454
- popularComment: string | null;
455
- engagement: string;
456
- date: string;
457
- duration: string | null;
458
- authorNote: string | null;
459
- }
460
- interface AICitation {
461
- text: string;
462
- href: string;
463
- rawUrl: string;
464
- resolvedUrl: string | null;
465
- linkType: SerpLinkType;
466
- resolutionStatus: SerpLinkResolutionStatus;
467
- }
468
- interface AIOverviewResult {
469
- detected: boolean;
470
- text: string | null;
471
- citations: AICitation[];
472
- expanded?: boolean;
473
- fullyExpanded?: boolean;
474
- sections?: string[];
475
- shareUrl?: string | null;
476
- }
477
- interface AIModeResult {
478
- detected: boolean;
479
- text: string | null;
480
- citations: AICitation[];
481
- }
482
- type GoogleSurface = 'web' | 'aim' | 'unknown';
483
- interface OrganicResult {
484
- position: number;
485
- title: string;
486
- url: string;
487
- rawUrl: string;
488
- resolvedUrl: string | null;
489
- linkType: SerpLinkType;
490
- resolutionStatus: SerpLinkResolutionStatus;
491
- domain: string;
492
- cite: string | null;
493
- snippet: string | null;
494
- isRedditStyle: boolean;
495
- inlineRating: {
496
- value: string;
497
- count: string;
498
- } | null;
499
- }
500
- interface LocalPackBusiness {
501
- position: number;
502
- name: string;
503
- cid: string | null;
504
- rating: string | null;
505
- reviewCount: string | null;
506
- metadata: string[];
507
- websiteUrl: string | null;
508
- directionsUrl: string | null;
509
- }
510
- interface EntityRecord {
511
- name: string;
512
- kgId: string | null;
513
- cid: string | null;
514
- gcid: string | null;
515
- }
516
- interface EntityIds {
517
- entities: EntityRecord[];
518
- kgIds: string[];
519
- cids: string[];
520
- gcids: string[];
521
- }
522
534
  interface HarvestResult {
523
535
  seed: string;
524
536
  location: string | null;