(()=>{var e={};e.id=693,e.ids=[693],e.modules={3037:(e,s,t)=>{var r={"./app":7193,"./app.jsx":7193,"./auth/[...auth0]":9174,"./auth/[...auth0].js":9174,"./claim-code":8924,"./claim-code.ts":8924,"./db":1427,"./db.ts":1427,"./download-tracking":5034,"./download-tracking.ts":5034,"./public-tags":866,"./public-tags.ts":866,"./qb/[fn]":7953,"./qb/[fn].ts":7953,"./resources":4698,"./resources.ts":4698,"./send-mail":3150,"./send-mail.ts":3150,"./ssh/ssh-exec":6080,"./ssh/ssh-exec.ts":6080,"./threat-detection":6641,"./threat-detection.ts":6641,"./token-gen":7269,"./token-gen.ts":7269,"./warp":960,"./warp.ts":960,"./warptest":9730,"./warptest.ts":9730,"./workflows":872,"./workflows.ts":872};function webpackContext(e){return t(webpackContextResolve(e))}function webpackContextResolve(e){if(!t.o(r,e)){var s=Error("Cannot find module '"+e+"'");throw s.code="MODULE_NOT_FOUND",s}return r[e]}webpackContext.keys=function(){return Object.keys(r)},webpackContext.resolve=webpackContextResolve,e.exports=webpackContext,webpackContext.id=3037},93:e=>{"use strict";e.exports=require("@auth0/nextjs-auth0")},3697:e=>{"use strict";e.exports=require("ical-toolkit")},145:e=>{"use strict";e.exports=require("next/dist/compiled/next-server/pages-api.runtime.prod.js")},5184:e=>{"use strict";e.exports=require("nodemailer")},9271:e=>{"use strict";e.exports=require("popsicle")},9967:e=>{"use strict";e.exports=require("ssh2")},9648:e=>{"use strict";e.exports=import("axios")},7147:e=>{"use strict";e.exports=require("fs")},7438:(e,s,t)=>{"use strict";t.r(s),t.d(s,{config:()=>c,default:()=>i,routeModule:()=>d});var r={};t.r(r),t.d(r,{default:()=>handler});var a=t(9150),n=t(1631),o=t(6835);async function handler(e,s,r,a){let n=e.query.slug,o=Array.isArray(n)?n.join("/"):n;n.includes("auth")?(o="auth/[...auth0]",e.query.auth0=n.slice(1)):n.includes("qb")&&(o="qb/[fn]",e.query.fn=n[1]);let i=t(3037)("./"+o).default;return await i(e,s,r,a)}let i=(0,o.l)(r,"default"),c=(0,o.l)(r,"config"),d=new a.PagesAPIRouteModule({definition:{kind:n.x.PAGES_API,page:"/api/[...slug]",pathname:"/api/[...slug]",bundlePath:"",filename:""},userland:r})},7193:(e,s,t)=>{"use strict";function handler(e,s){var t=e.query,r=t.nginxuri;delete t.nginxuri,r=r?r.split("?")[0]:"";var a=t.scheme?t.scheme:t.application??"whiteStarChat";delete t.scheme;var n=a+"://"+r,o=Object.entries(t);for(let e=0;e<o.length;e++)n+=(0===e?"?":"&")+o[e][0]+"="+o[e][1];console.log(n);var i=`
        <html>
            <head>
                <meta http-equiv="refresh" content=0;url=`+n+` />
            </head>
            <body style="height: 100vh; background-color: #ddd; display:flex; justify-content: center; align-items: center;">
                <h2 style="margin-bottom: 40px; padding-x: 40px; max-width: 1000px; margin-x: auto; text-align:center; font-family: helvetica neue, open sans, sans sarif">
                    Thank you for verifying your WhiteStar application. Please accept the redirect or click the link below \
                    to return to your application.
                    <br />
                    <br />
                    <a style="color: #466FF4;" href=`+n+`> Click Here </a>
                </h2>
            </body>
        </html>`;s.status(207).send(i)}t.r(s),t.d(s,{default:()=>handler})},9174:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>n});var r=t(93),a=t(5305);async function afterCallback(e,s,t,r){let n=await (0,a.Z)({query:"SELECT * FROM Users WHERE email = ? AND ISNULL(date_canceled)",values:[t.user.email]}),o=n?.[0],i=await (0,a.Z)({query:`SELECT User_Accounts.type, COALESCE(User_Accounts.name, Orgs.name, Sales.name) as name,
    Orgs.id as org_id, Orgs.name as org_name, Rep.name as rep_name, Rep_User.email as rep_email,
    Orgs.max_licenses, Orgs.uuid, Orgs.assigned_licenses, Orgs.claimed_licenses, Orgs.sub_tenants, Orgs.replicators, Orgs.threat_detection, Orgs.parent_org, Orgs.onboarding_notifications,
    COALESCE(Sales.rate, Accounts.rate) as rate
    FROM User_Accounts
    LEFT JOIN Orgs ON Orgs.id = User_Accounts.id
    LEFT JOIN Accounts ON Accounts.id = Orgs.id
    LEFT JOIN Sales AS Rep ON Rep.id = Orgs.rep_id
    LEFT JOIN Users AS Rep_User ON Rep_User.id = Orgs.rep_id
    LEFT JOIN Sales ON Sales.id = User_Accounts.id
    WHERE User_Accounts.user_id = ? AND ISNULL(Orgs.date_canceled)`,values:[o?.id]}),c=await (0,a.Z)({query:`SELECT User_Accounts.type, COALESCE(User_Accounts.name, Orgs.name, Sales.name) as name,
    Orgs.id as org_id, Orgs.name as org_name, Rep.name as rep_name, Rep_User.email as rep_email,
    Orgs.max_licenses, Orgs.uuid, Orgs.assigned_licenses, Orgs.claimed_licenses, Orgs.sub_tenants, Orgs.replicators, Orgs.threat_detection, Orgs.parent_org, Orgs.onboarding_notifications,
    COALESCE(Sales.rate, Accounts.rate) as rate
    FROM Orgs
    LEFT JOIN User_Accounts ON (Orgs.id = User_Accounts.id AND User_Accounts.type = 'org')
    LEFT JOIN Accounts ON Accounts.id = Orgs.id
    LEFT JOIN Sales AS Rep ON Rep.id = Orgs.rep_id
    LEFT JOIN Users AS Rep_User ON Rep_User.id = Orgs.rep_id
    LEFT JOIN Sales ON Sales.id = User_Accounts.id
    WHERE Orgs.rep_id = ? AND ISNULL(Orgs.date_canceled)
    GROUP BY org_id`,values:[o?.id]});return t.user.loginData=o,t.user.accounts=[...i,...c],t}let n=(0,r.handleAuth)({async login(e,s){try{await (0,r.handleLogin)(e,s,{returnTo:"/dashboard"})}catch(e){s.status(e.status||400).end(e.message)}},async callback(e,s){try{await (0,r.handleCallback)(e,s,{afterCallback})}catch(e){s.status(e.status||500).end(e.message)}}})},8924:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>claimCode});var r=t(5305),a=t(7147),n=t.n(a);async function claimCode(e,s){let a=e.body.code??"",o=e.body.mode??"get_org";if("get_org"===o)await (0,r.Z)({query:"SELECT Claim_Codes.org_id, Claim_Codes.app_id, Orgs.name, Orgs.max_licenses, Orgs.assigned_licenses FROM Claim_Codes         LEFT JOIN Orgs ON Orgs.id = Claim_Codes.org_id WHERE code=? AND Claim_Codes.date_canceled IS NULL",values:[a]}).then(e=>{s.status(200).json(e)}).catch(e=>s.status(500).send(e));else if("claim"===o){let o=e.body.name??"",i=e.body.email;if(!i){s.status(200).send("Error: No email set");return}await (0,r.Z)({query:"SELECT Claim_Codes.org_id, Claim_Codes.app_id, Claim_Codes.enabled, Claim_Codes.used, Claim_Codes.max_uses, Orgs.name, Orgs.max_licenses, Orgs.assigned_licenses           FROM Claim_Codes           LEFT JOIN Orgs ON Orgs.id = Claim_Codes.org_id           WHERE code=? AND Claim_Codes.date_canceled IS NULL",values:[a]}).then(async e=>{if(!e.length){s.status(200).send("Error: Code not found");return}let c=e[0],d=c.org_id,l=c.app_id??0;if(c.enabled){if(c.max_uses&&c.used>=c.max_uses){s.status(200).send("Error: This code has been claimed the max number of times");return}await (0,r.Z)({query:"SELECT * FROM `Application_Users` AS a LEFT JOIN `Application_Licenses` AS b               ON a.id = b.user_id AND b.date_unassigned IS NULL               WHERE a.email=aes_encrypt(?, ?) AND a.date_canceled IS NULL",values:[i,d]}).then(async u=>{if(0===u.length){if(await (0,r.Z)({query:"INSERT INTO `Application_Users` (`org_id`, `email`, `name`, `date_created`) VALUES (?,aes_encrypt(?,?),aes_encrypt(?,?),CURRENT_DATE)",values:[d,i,d,o,d]}).then(async e=>{(0,r.Z)({query:"INSERT INTO `Application_Licenses` (user_id, application_id, date_assigned)                   SELECT id as user_id, ?, CURRENT_DATE FROM `Application_Users` WHERE id = ?",values:[l,e.insertId]})}),u.some(e=>e.application_id===l)){s.status(200).send("Error: A license has already been claimed by a user with this email!");return}s.status(200).send("Code Claimed Successfully!")}else{if(await (0,r.Z)({query:"UPDATE `Claim_Codes` SET `used`=? WHERE code=?",values:[parseInt(c.used)+1,a]}).catch(e=>{s.status(500).send(e+"cmd2")}),await (0,r.Z)({query:"INSERT INTO `Application_Licenses` (user_id, application_id, claimed, date_created)                     VALUES (?, ?, '0', CURRENT_DATE)",values:[u[0].user_id,l]}).catch(e=>{s.status(500).send(e+"cmd3")}),i){let{Client:r}=t(9967),a=new r;a.on("ready",()=>{console.log("Client :: ready"),a.exec(`(echo "addEmail [${i.replaceAll("'","")}]"; sleep 1; echo "exit" ) | telnet 127.0.0.1 42426`,(t,r)=>{if(t)throw t;r.on("close",(t,r)=>{console.log("Stream :: close :: code: "+t+", signal: "+r),a.end(),e.includes("MCP>")||s.status(501).send("Error: No Response from MCP"),s.status(200).send(e.split("MCP>")[1]?.trim())}).on("data",s=>{console.log("STDOUT: "+s),e+=Buffer.from(s).toString()}).stderr.on("data",e=>{console.log("STDERR: "+e)})})}).connect({host:process.env.MCP_HOST,port:process.env.MCP_POST,username:"whitestar",privateKey:n().readFileSync("/root/.ssh/id_rsa"),hostHash:"sha1",hostVerifier:e=>e===process.env.MCP_HOSTKEY||(console.log("HostKey Mistmatch!"),!1)})}s.status(200).send("Success!")}})}else{s.status(200).send("Error: This code is no longer valid");return}}).catch(e=>s.status(500).send(e+"cmd1"))}else s.status(500).send("Err: Mode not set")}},1427:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>n});var r=t(5305),a=t(245);let n=(0,a.g)(async function(e,s){await (0,r.Z)({query:e.body.query,values:e.body.values}).then(e=>{s.status(200).send(e)}).catch(e=>s.status(500).send(e))})},5034:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>downloadTracking});var r=t(5305);async function downloadTracking(e,s){let t=e.body.website??null,a=e.body.product??null,n=e.body.platform??null,o=e.body.arch??null,i=e.body.mode??"fetch";"increment"===i&&await (0,r.Z)({query:"INSERT INTO `Download_Tracking` (`website`, `product`, `platform`, `arch`, `date`) VALUES (?, ?, ?, ?, CURRENT_TIMESTAMP)",values:[t,a,n,o]}).then(e=>{s.send(e)}).catch(()=>s.status(200).json([])),"fetch"===i&&await (0,r.Z)({query:"SELECT COUNT(*) AS total FROM `Download_Tracking`",values:[]}).then(e=>{s.status(200).json(e)}).catch(()=>s.status(200).json([]))}},866:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>query});var r=t(5305);let a=require("nextjs-cors");var n=t.n(a);async function query(e,s){await n()(e,s,{methods:["GET"],origin:"*",optionsSuccessStatus:200}),await (0,r.Z)({query:"SELECT b.name as org_name, a.org_id, a.uuid, a.name, a.color FROM `Tags` as a LEFT JOIN `Orgs` as b ON a.org_id = b.id WHERE a.public = 1 AND b.trusted_support = 1"}).then(e=>{s.send(e)}).catch(()=>s.status(200).json([]))}},7953:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>handler});let r=require("intuit-oauth");var a=t.n(r);let n=require("cookies");var o=t.n(n);let i=process.env.QB_REALM_ID,c=new(a())({clientId:process.env.QB_CLIENT_ID,clientSecret:process.env.QB_CLIENT_SECRET,environment:process.env.QB_ENV,redirectUri:process.env.AUTH0_BASE_URL+"/api/qb/callback",logging:!1});var d=["whitestar!"];async function handler(e,s){var r=new(o())(e,s,{keys:d});async function safeSetToken(e){let t=r.get("qb_token",{signed:!0});return t?(e.getToken().setToken(JSON.parse(t)),r.get("qb_token_fresh",{signed:!0}))?(console.log("The access token is valid"),!0):void await e.refresh().then(function(s){return e.getToken().setToken(s.getJson()),r.set("qb_token",JSON.stringify(s.getJson()),{signed:!0}),r.set("qb_token_fresh","true",{signed:!0,maxAge:3e6}),console.log("Refreshed access token"),!0}).catch(function(e){return console.log("Token refresh error"),s.status(423).end(),!1}):(s.status(423).end(),!1)}async function apiCall(r){var n=t(9271);let o=await safeSetToken(c).then(async()=>{console.log("Running query...");let t="sandbox"==c.environment?a().environment.sandbox:a().environment.production,o=e.headers["x-api-content-type"]??"application/json",d="application/pdf"===o?await c.makeApiCall({headers:{Accept:o,ContentType:o},transport:n.createTransport({type:"buffer"}),url:`${t}v3/company/${i}/${r}`}).then(function(e){return s.status(200),e.body}).catch(function(e){return s.status(500),console.log("API call error"),console.error(e),e}):await c.makeApiCall({url:`${t}v3/company/${i}/${r}`,method:e.method,headers:{Accept:o,ContentType:o},body:e.body}).then(function(e){return(s.status(200),"application/json"===o||"application/text"===o)?e.getJson():e}).catch(function(e){return s.status(500),console.log("API call error"),console.error(e),e});return d}).catch(function(e){return console.log("Error in safeSetToken: "+e),!1});return o}switch(console.log(e.query),e.query.fn){case"connect":let n=c.authorizeUri({scope:[a().scopes.Accounting],state:"intuit-test"});s.redirect(n);break;case"callback":let l=e.url;c.createToken(l).then(function(e){r.set("qb_token",JSON.stringify(e.getJson()),{signed:!0,maxAge:87264e5}),r.set("qb_token_fresh","true",{signed:!0,maxAge:3e6}),console.log("The Token is  "+JSON.stringify(e.getJson())),s.redirect("/dashboard/invoices")}).catch(function(e){console.error("The error message is: "+e.originalMessage),console.error(e.intuit_tid),s.end()});break;case"get_company_info":let u=await apiCall(`companyinfo/${i}`);s.send(u);break;case"query":let p=await apiCall(e.query.q);s.send(p);break;default:s.end("Invalid Mode")}}},4698:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>getResource});var r=t(7147),a=t.n(r);let n=require("path");var o=t.n(n);async function getResource(e,s){let t=o().join(process.cwd(),e.body.file),r=a().readFileSync(t);s.setHeader("Content-Type","arraybuffer"),s.status(200).send(r)}},3150:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>sendMail});let r=require("crypto"),a=t(3697);async function sendMail(e,s){if(!process.env.MAIL_PORT||!process.env.MAIL_HOST||!process.env.MAIL_USER||!process.env.MAIL_PASS){console.error("One or more env variables not set for mail.");return}let n=t(5184),o=n.createTransport({port:process.env.MAIL_PORT??465,host:process.env.MAIL_HOST,auth:{user:process.env.MAIL_USER,pass:process.env.MAIL_PASS},secure:!0}),i=Array.isArray(e.body.to_address)?e.body.to_address:`${e.body.to_name??"WhiteStar Support"} <${e.body?.to_address??"support@whitestar.io"}>`,c={from:`${e.body?.from_name??"WhiteStar Support"} <${e.body?.from_address??"no_reply@whitestar-vortex.com"}>`,to:i,subject:`${e.body?.subject??"no subject"}`,html:`<div>${e.body?.body??""}</div>`,textEncoding:"base64"};if(e?.body.calendar){var d=a.createIcsFileBuilder();d.method="REQUEST",d.events.push({start:new Date(e.body.calendar.startTime),end:new Date(e.body.calendar.endTime),timestamp:new Date,summary:"WhiteStar Demo",uid:(0,r.randomUUID)(),categories:[{name:"MEETING"}],attendees:[{rsvp:!0,name:"WhiteStar Communications Inc.",email:"WhiteStar Support <support@whitestar.io>"},{rsvp:!0,name:e.body.to_name,email:`${e.body.to_name} <${e.body.to_address}>`}],organizer:{name:"WhiteStar Communications Inc.",email:"support@whitestar.io"}});var l=d.toString();l instanceof Error&&console.error("ics Calendar Invite Creation Returned Error"),c.alternatives=[{contentType:'text/calendar; charset="utf-8"; method=REQUEST',content:l.toString()}]}o.sendMail(c,function(e){e&&console.error(e)}),s.status(200).send({})}},6080:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>a});var r=t(245);let a=(0,r.g)(async function(e,s){return process.env.MCP_HOST&&process.env.MCP_PORT||e?.body?.options?.url&&(e?.body?.options?.localProxyPort||e?.body?.options?.port)||s.status(501).send("MCP env params not set"),new Promise((t,r)=>{fetch(`http://${e?.body?.options?.url??process.env.MCP_HOST}:${e?.body?.options?.localProxyPort??e?.body?.options?.port??process.env.MCP_PORT}/api/command/${e.body.cmd}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e.body.params)}).then(a=>{if(!a.ok){s.status(502).send("Bad response from MCP"),console.log(e.body),console.log(a),r(Error("Bad response from MCP"));return}a.text().then(e=>{s.status(200).send(e),t()})}).catch(e=>{console.error("Error connecting to MCP:",e),s.status(502).send("MCP is not running"),r(Error("MCP is not running"))})})})},6641:()=>{},7269:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>o});var r=t(7147),a=t.n(r),n=t(245);let o=(0,n.g)(async function(e,s){if(process.env.WARP_HOST&&process.env.WARP_PORT||s.status(501).send("WARP env params not set"),"POST"!==e.method){s.status(405).send({message:"Only POST requests allowed"});return}return new Promise((e,r)=>{let{Client:n}=t(9967),o="",i=new n;i.on("ready",()=>{console.log("Client :: ready");try{i.exec("./bin/warp10.sh tokengen tokens/whitestar-tokengen.mc2",(t,r)=>{if(t)throw t;r.on("close",(t,r)=>{console.log("Stream :: close :: code: "+t+", signal: "+r),i.end(),s.status(200).send(o),e()}).on("data",e=>{console.log("STDOUT: "+e),o+=Buffer.from(e).toString()}).stderr.on("data",e=>{console.log("STDERR: "+e)})})}catch(e){console.error("Error in ssh-exec:",e)}}).connect({host:process.env.WARP_HOST,username:"warp10",privateKey:a().readFileSync("/root/.ssh/id_ed25519"),hostHash:"sha1",hostVerifier:e=>(console.log(e),e===process.env.WARP_HOSTKEY||(console.log("HostKey Mistmatch!","Expected: ",process.env.WARP_HOSTKEY,"Recieved: ",e),!1))})})})},960:(e,s,t)=>{"use strict";t.a(e,async(e,r)=>{try{t.r(s),t.d(s,{default:()=>warp});var a=t(9648),n=e([a]);async function warp(e,s){let t="";if("object"==typeof e.body){let{classes:s,labels:r,cmd:a}=e.body;t=`[ '${process.env.WARP_MCP_READ_TOKEN}' '~${s??".*"}' {${r??""}} ] ${a}`}else t=e.body;await a.default.post(`http://${process.env.WARP_HOST}:${process.env.WARP_PORT}/api/v0/exec`,t,{headers:{"Content-Type":"text/plain"}}).then(e=>s.send(e.data)).catch(e=>{console.error(e),s.end(e.message)})}a=(n.then?(await n)():n)[0],r()}catch(e){r(e)}})},9730:(e,s,t)=>{"use strict";t.a(e,async(e,r)=>{try{t.r(s),t.d(s,{default:()=>warp});var a=t(9648),n=e([a]);async function warp(e,s){let t=`'data' {
    'token' "${process.env.WARP_MCP_READ_TOKEN}"
    'class'  '~.*'
    'labels' {}
    'end' NOW
    'count' 100
  } FETCH`;await a.default.post(`http://${process.env.WARP_HOST}:${process.env.WARP_PORT}/api/v0/exec`,t,{headers:{"Content-Type":"text/plain"}}).then(e=>s.send(e.data)).catch(e=>{console.error(e),s.end(e.message)})}a=(n.then?(await n)():n)[0],r()}catch(e){r(e)}})},872:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>workflows});var r=t(5305);async function workflows(e,s){let t=e.body.uuid??"",a=e.body.mode??"";if(""===t){s.status(500).send("Error: No UUID set");return}if(""===a){s.status(500).send("Error: No mode set");return}let n=await (0,r.Z)({query:"SELECT * FROM Workflows_Progress WHERE uuid=? AND date_canceled IS NULL",values:[t]}).catch(e=>s.status(500).send(e));"get"===a?s.status(200).json(n):"approve"===a?(await (0,r.Z)({query:"UPDATE Workflows_Progress SET active_step=? WHERE uuid=?",values:[n.active_step+1,t]}).catch(e=>s.status(500).send(e)),s.status(200).send("Workflow approved")):"reject"===a&&(await (0,r.Z)({query:"UPDATE Workflows_Progress SET date_completed=NOW() WHERE uuid=?",values:[t]}).catch(e=>s.status(500).send(e)),s.status(200).send("Workflow rejected"))}},5305:(e,s,t)=>{"use strict";t.d(s,{Z:()=>excuteQuery}),require("serverless-mysql");let r=require("better-sqlite3");var a=t.n(r);let n=new(a())("dashboard.db",{verbose:console.log});async function excuteQuery({query:e,values:s=[]}){try{{e=(e=(e=(e=(e=(e=(e=e.replace(/CONVERT\(/g,"").replace(/USING utf8\)/g,"")).replace(/aes_encrypt\(([^,]+),\s*([^\)]+)\)/g,"COALESCE($1, $2)")).replace(/aes_decrypt\(([^,]+),\s*([^\)]+)\)/g,"COALESCE($1, $2)")).replace(/ISNULL\(([^\)]+)\)/g,"$1 IS NULL")).replace(/\'\?\'/g,"?")).replace(/JSON_MERGE\((.+),\s*\?\)/g,"json_insert($1, '$[#]', CAST(? AS INTEGER))")).replace(/JSON_CONTAINS\((.+),\s*([^\)]+)\)/g,"EXISTS (SELECT 1 FROM json_each($1) WHERE value = $2)"),console.log("\x1b[34m%s\x1b[0m","Executing query: ",e),console.log("\x1b[34m%s\x1b[0m","With values: ",s),s.forEach(s=>{if(Array.isArray(s)){let t=s.map(()=>"?").join(",");e=e.replace("IN (?)",`IN (${t})`)}}),s=s.flat().map(e=>"boolean"==typeof e?e?1:0:e);let t=null;if(e.trim().toLowerCase().startsWith("select"))t=n.prepare(e).all(s);else{let r=n.prepare(e);t=r.run(s)}return t}}catch(s){return console.log("\x1b[31m%s\x1b[0m","Error in query: ",e),console.error(s),{error:s}}}},245:(e,s,t)=>{"use strict";t.d(s,{g:()=>withApiAuthRequired}),require("@auth0/nextjs-auth0/client"),t(93);let withApiAuthRequired=e=>e}};var s=require("../../webpack-api-runtime.js");s.C(e);var __webpack_exec__=e=>s(s.s=e),t=s.X(0,[471],()=>__webpack_exec__(7438));module.exports=t})();