mcp-scraper 0.93.0 → 0.93.2
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/CHANGELOG.md +37 -25
- package/README.md +3 -3
- package/dist/bin/api-server.js +1 -1
- package/dist/bin/mcp-scraper-cli.js +1 -1
- package/dist/bin/mcp-scraper-core.js +1 -1
- package/dist/bin/mcp-scraper-install.js +1 -1
- package/dist/bin/mcp-stdio-server.js +1 -1
- package/dist/bin/paa-harvest.js +1 -1
- package/dist/chunk-2SP57VCG.js +15 -15
- package/dist/{chunk-PMOPJOSJ.js → chunk-5JKBFNYF.js} +1 -1
- package/dist/{chunk-35QGIWR6.js → chunk-5VB3I7UX.js} +4 -4
- package/dist/chunk-73LAMUS5.js +6 -0
- package/dist/{chunk-LBMRUR4E.js → chunk-AFFMCO7R.js} +2 -2
- package/dist/{chunk-4YLZR4OR.js → chunk-CG2FHIBA.js} +1 -1
- package/dist/chunk-DT2FYN6N.js +1 -1
- package/dist/{chunk-XG6GCEUE.js → chunk-EWR7BPPD.js} +1 -1
- package/dist/{chunk-H3SJLJYM.js → chunk-IJF4VXJ7.js} +1 -1
- package/dist/{chunk-IK5BG7MO.js → chunk-KPDNM7E7.js} +1 -1
- package/dist/{chunk-M5VZVMPC.js → chunk-MJ2OICVY.js} +3 -3
- package/dist/{chunk-5KQO27NH.js → chunk-NLKA6SHC.js} +1 -1
- package/dist/chunk-ORB4RHCK.js +4 -4
- package/dist/{chunk-VRVO4OQ3.js → chunk-QWSWHUOK.js} +150 -150
- package/dist/chunk-SH5KB4P7.js +1 -1
- package/dist/chunk-UN6FVDJQ.js +1 -0
- package/dist/{chunk-M5QHXNFZ.js → chunk-VVG7LFFF.js} +3 -3
- package/dist/chunk-WJ4XFLS4.js +15 -15
- package/dist/chunk-XJ6PJWT5.js +1 -0
- package/dist/chunk-Y6MKMSOC.js +1 -1
- package/dist/{extract-bundle-M2XM4BEW.js → extract-bundle-MQOAKQDV.js} +1 -1
- package/dist/{gmail-service-EGATZIBE.js → gmail-service-6V5MFBYH.js} +1 -1
- package/dist/index.cjs +21 -21
- package/dist/index.d.cts +15 -15
- package/dist/index.d.ts +15 -15
- package/dist/index.js +1 -1
- package/dist/{server-JLR2YJ7V.js → server-GRB6VNT6.js} +43 -43
- package/dist/{site-extract-repository-3NFFFPXQ.js → site-extract-repository-2LFDP6FZ.js} +1 -1
- package/dist/{stripe-event-worker-PUYXT5DS.js → stripe-event-worker-IJXA6T37.js} +1 -1
- package/dist/worker-US6CTFYG.js +1 -0
- package/package.json +136 -17
- package/THIRD_PARTY_NOTICES.html +0 -203
- package/dist/chunk-DUJ56SHU.js +0 -1
- package/dist/chunk-RZEZJAID.js +0 -1
- package/dist/chunk-XASDACRP.js +0 -6
- package/dist/worker-UG4OXZWR.js +0 -1
package/dist/chunk-Y6MKMSOC.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z as e}from"zod";var i="none",a="none";function c(t){switch(t){case"day":return"qdr:d";case"week":return"qdr:w";case"month":return"qdr:m";case"year":return"qdr:y";default:return}}var u=e.object({businessName:e.string().min(1),location:e.string().min(1),gl:e.string().length(2).default("us"),hl:e.string().length(2).default("en"),includeReviews:e.boolean().default(!1),maxReviews:e.number().int().min(1).max(500).default(50),includeServices:e.boolean().default(!1),includeImages:e.boolean().default(!1),imageScope:e.enum(["owner","all"]).default("all"),maxImages:e.number().int().min(1).max(250).default(100),maxInlineImages:e.number().int().min(0).max(5).default(3)
|
|
1
|
+
import{z as e}from"zod";var i="none",a="none";function c(t){switch(t){case"day":return"qdr:d";case"week":return"qdr:w";case"month":return"qdr:m";case"year":return"qdr:y";default:return}}var u=e.object({businessName:e.string().min(1),location:e.string().min(1),gl:e.string().length(2).default("us"),hl:e.string().length(2).default("en"),includeReviews:e.boolean().default(!1),maxReviews:e.number().int().min(1).max(500).default(50),includeServices:e.boolean().default(!1),includeImages:e.boolean().default(!1),imageScope:e.enum(["owner","all"]).default("all"),maxImages:e.number().int().min(1).max(250).default(100),maxInlineImages:e.number().int().min(0).max(5).default(3),kernelApiKey:e.string().optional(),kernelProxyId:e.string().optional(),headless:e.boolean().default(!0)}),g=e.object({query:e.string().min(1),location:e.string().optional(),gl:e.string().length(2).default("us"),hl:e.string().length(2).default("en"),maxResults:e.number().int().min(1).max(50).default(10),includeServices:e.boolean().default(!1),proxyMode:e.enum(["location","configured","none"]).default(a),proxyZip:e.string().regex(/^\d{5}$/).optional(),serpRedirect:e.boolean().optional(),forceDirectEgress:e.boolean().optional(),debug:e.boolean().default(!1),kernelApiKey:e.string().optional(),kernelProxyId:e.string().optional(),kernelProxyResolution:e.unknown().optional(),headless:e.boolean().default(!0)}),p=e.object({name:e.string().nullable(),rating:e.string().nullable(),reviewCount:e.string().nullable(),category:e.string().nullable(),address:e.string().nullable(),hoursSummary:e.string().nullable(),phone:e.string().nullable(),phoneDisplay:e.string().nullable(),website:e.string().nullable(),plusCode:e.string().nullable(),bookingUrl:e.string().nullable()}),d=e.object({day:e.string(),hours:e.string()}),b=e.object({reviewHistogram:e.array(e.object({stars:e.number(),count:e.string()})),reviewTopics:e.array(e.object({label:e.string(),count:e.string()}))}),m=e.object({reviewId:e.string(),author:e.string().nullable(),stars:e.string().nullable(),date:e.string().nullable(),text:e.string().nullable(),ownerResponse:e.string().nullable()}),f=e.object({section:e.string(),attribute:e.string()});async function R(t){if((process.env.NODE_ENV==="test"||process.env.VITEST)&&process.env.MCP_SCRAPER_ENABLE_MEMORY_LIBRARY_SINK_IN_TESTS!=="1")return;let r=process.env.MCP_SCRAPER_API_KEY?.trim(),s=(process.env.MCP_SCRAPER_BASE_URL??"https://mcpscraper.dev").replace(/\/$/,"");if(r)try{let n=await fetch(`${s}/memory/mcp-call`,{method:"POST",headers:{"content-type":"application/json","x-api-key":r},body:JSON.stringify({toolName:"libraryIngestTool",args:t})}),o=await n.json().catch(()=>null);(!n.ok||o?.ok===!1)&&console.warn("[memory-library-sink] ingest not accepted:",n.status,o?.error??"")}catch(n){console.warn("[memory-library-sink] ingest failed:",n?.message)}}export{i as a,a as b,c,u as d,g as e,p as f,d as g,b as h,f as i,R as j};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as Ge,h as ke,i as Qe,j as Ve,l as et}from"./chunk-
|
|
1
|
+
import{c as Ge,h as ke,i as Qe,j as Ve,l as et}from"./chunk-KPDNM7E7.js";import"./chunk-EWR7BPPD.js";import{b as Ye,c as Xe,h as Ze,j as Ke}from"./chunk-5JKBFNYF.js";import"./chunk-VVG7LFFF.js";import{c as ze,e as Fe,f as He,g as We}from"./chunk-W2BVJ7S2.js";import{c as Je}from"./chunk-RK2VCTZI.js";import"./chunk-ORB4RHCK.js";import"./chunk-TMB56NCA.js";import"./chunk-UN6FVDJQ.js";import"./chunk-6DTXIZY2.js";import"./chunk-HE45FFBU.js";import{t as qe}from"./chunk-WJ4XFLS4.js";import{createWriteStream as se,mkdirSync as ie,readFileSync as xt,readdirSync as kt,rmSync as _t,statSync as Pt,writeFileSync as g}from"fs";import{createHash as G}from"crypto";import{basename as Mt,join as a}from"path";import{tmpdir as It}from"os";import{createGzip as Ct}from"zlib";import{once as Y}from"events";import{finished as ae}from"stream/promises";import{ZipFile as At}from"yazl";import Rt from"p-limit";import{createHash as _e}from"crypto";var gt=500,ht=.9,ft=1e4,yt=5e4;function ge(r,s){let n=10**s;return Math.round(r*n)/n}function wt(r,s){if(r.length===0||r.length!==s.length)throw new Error("Similarity vectors must have the same non-zero dimension.");let n=0,c=0,b=0;for(let w=0;w<r.length;w++)n+=r[w]*s[w],c+=r[w]*r[w],b+=s[w]*s[w];return c===0||b===0?0:Math.max(-1,Math.min(1,n/(Math.sqrt(c)*Math.sqrt(b))))}function St(r){let s=_e("sha256");for(let n of[...r].sort((c,b)=>c.url.localeCompare(b.url)))s.update(n.url),s.update("\0"),s.update(n.contentHash),s.update("\0");return s.digest("hex")}function tt(r){let s=r.replace(/!\[([^\]]*)\]\([^)]*\)/g,"$1").replace(/\[([^\]]+)\]\([^)]*\)/g,"$1").replace(/https?:\/\/\S+/gi," ").replace(/&(?:amp|nbsp|quot|#39);/gi," ").replace(/[#>*_`~|\\-]+/g," ").replace(/[^\p{L}\p{N}]+/gu," ").replace(/\s+/g," ").trim().toLowerCase();return s.length>=12?s:null}function bt(r){let s=r.map(f=>f.bodyMarkdown.split(/\n{2,}/).map(M=>M.trim()).filter(Boolean)),n=r.length>=4?Math.max(3,Math.ceil(r.length*.5)):null,c=new Map;for(let f of s){let M=new Set(f.map(tt).filter(I=>!!I));for(let I of M)c.set(I,(c.get(I)??0)+1)}let b=new Set;if(n!=null)for(let[f,M]of c)M>=n&&b.add(f);let w=0;return{texts:r.map((f,M)=>{let I=[];for(let _ of s[M]){let T=tt(_);if(T&&b.has(T)){w+=_.length;continue}I.push(_)}let A=I.join(`
|
|
2
2
|
|
|
3
3
|
`).trim(),C=A.length>=60?A:f.bodyMarkdown;return`${f.title?.trim()||"Untitled page"}
|
|
4
4
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as a,f as b,g as c,h as d,i as e,j as f,k as g,l as h}from"./chunk-
|
|
1
|
+
import{e as a,f as b,g as c,h as d,i as e,j as f,k as g,l as h}from"./chunk-NLKA6SHC.js";import"./chunk-IJF4VXJ7.js";import"./chunk-QTDLZTQ7.js";import"./chunk-HUV2WTRW.js";import"./chunk-UN6FVDJQ.js";import"./chunk-2SP57VCG.js";import"./chunk-6DTXIZY2.js";import"./chunk-WJ4XFLS4.js";export{d as GMAIL_ATTACHMENT_REF_TTL_MS,c as GMAIL_INLINE_BODY_BYTES,b as GMAIL_MAIN_CONTRACT_HASH,a as GMAIL_MAIN_CONTRACT_VERSION,h as GmailService,e as GmailServiceError,g as normalizeGmailMessage,f as parseGmailAddresses};
|