"use strict";(()=>{var e={};e.id=4260,e.ids=[4260],e.modules={20399:e=>{e.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},30517:e=>{e.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},56681:e=>{e.exports=require("playwright")},36529:(e,t,r)=>{r.r(t),r.d(t,{originalPathname:()=>g,patchFetch:()=>x,requestAsyncStorage:()=>c,routeModule:()=>d,serverHooks:()=>m,staticGenerationAsyncStorage:()=>w});var a={};r.r(a),r.d(a,{POST:()=>l});var o=r(49303),i=r(88716),s=r(60670),n=r(87070),p=r(56681),u=r.n(p);async function l(e){let t;try{let{url:r,headless:a}=await e.json();if(!r)return n.NextResponse.json({error:"URL is required"},{status:400});t=await u().chromium.launch({headless:a});let o=await t.newPage();await o.route("**/*",e=>{let t=e.request().url();/\.(png|jpg|jpeg|svg|woff2?|ttf|webp)$/i.test(t)?e.abort():e.continue()}),await o.goto(r,{waitUntil:"domcontentloaded",timeout:6e4}),await o.waitForTimeout(5e3);let i=await o.evaluate(()=>({seller:document.querySelector("#pdp-seller-info-rp a")?.innerText||"N/A",about_bullets:"",product_info:""}));return await t.close(),n.NextResponse.json({...i,url:r})}catch(e){return console.error("❌ Scraping Error:",e),n.NextResponse.json({error:"Failed to scrape website"},{status:500})}finally{await t.close()}}let d=new o.AppRouteRouteModule({definition:{kind:i.x.APP_ROUTE,page:"/api/snapdeal_detail_scraper/route",pathname:"/api/snapdeal_detail_scraper",filename:"route",bundlePath:"app/api/snapdeal_detail_scraper/route"},resolvedPagePath:"C:\\Users\\Design Collection\\OneDrive\\Desktop\\Jitendra Vishwakarma\\Next Dashboard\\web crawler for user dev\\Scrape Genius\\app\\api\\snapdeal_detail_scraper\\route.js",nextConfigOutput:"",userland:a}),{requestAsyncStorage:c,staticGenerationAsyncStorage:w,serverHooks:m}=d,g="/api/snapdeal_detail_scraper/route";function x(){return(0,s.patchFetch)({serverHooks:m,staticGenerationAsyncStorage:w})}}};var t=require("../../../webpack-runtime.js");t.C(e);var r=e=>t(t.s=e),a=t.X(0,[8948,5972],()=>r(36529));module.exports=a})();