"use strict";(()=>{var e={};e.id=693,e.ids=[693],e.modules={20145:e=>{e.exports=require("next/dist/compiled/next-server/pages-api.runtime.prod.js")},56249:(e,t)=>{Object.defineProperty(t,"l",{enumerable:!0,get:function(){return function e(t,r){return r in t?t[r]:"then"in t&&"function"==typeof t.then?t.then(t=>e(t,r)):"function"==typeof t&&"default"===r?t:void 0}}})},52831:(e,t,r)=>{r.r(t),r.d(t,{config:()=>s,default:()=>u,routeModule:()=>p});var n={};r.r(n),r.d(n,{default:()=>a});var o=r(71802),i=r(47153),d=r(56249);async function a(e,t){if(!e.headers["x-echo-url"])return t.status(404).send("No URL provided");let r=await fetch(`${e.headers["x-echo-url"]}?action=preview&workflowId=${e.query.workflowId}&stepId=${e.query.stepId}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({inputs:e.body.inputs||{}})}),n=await r.json();t.json(n)}let u=(0,d.l)(n,"default"),s=(0,d.l)(n,"config"),p=new o.PagesAPIRouteModule({definition:{kind:i.x.PAGES_API,page:"/api/workflows/[workflowId]/preview/[stepId]",pathname:"/api/workflows/[workflowId]/preview/[stepId]",bundlePath:"",filename:""},userland:n})},47153:(e,t)=>{var r;Object.defineProperty(t,"x",{enumerable:!0,get:function(){return r}}),function(e){e.PAGES="PAGES",e.PAGES_API="PAGES_API",e.APP_PAGE="APP_PAGE",e.APP_ROUTE="APP_ROUTE"}(r||(r={}))},71802:(e,t,r)=>{e.exports=r(20145)}};var t=require("../../../../../webpack-api-runtime.js");t.C(e);var r=t(t.s=52831);module.exports=r})();