@finda-co/novu-framework
Version:
The Code-First Notifications Workflow SDK.
2 lines (1 loc) • 663 B
JavaScript
import{b as H,c as t,d as S}from"../chunk-ZGHLT6HM.js";import{h as l}from"../chunk-J2MPR7MB.js";import{getHeader as o,getQuery as a,readBody as n,send as p,setHeaders as m}from"h3";var u="nuxt",g=d=>new t({frameworkName:u,...d,handler:r=>({queryString:e=>String(a(r)[e]),body:()=>n(r),headers:e=>o(r,e),url:()=>new URL(String(r.path),`${process.env.NODE_ENV==="development"?"http":"https"}://${String(o(r,"host"))}`),method:()=>r.method,transformResponse:e=>{let{res:s}=r.node;return s.statusCode=e.status,m(r,e.headers),p(r,e.body)}})}).createHandler();export{H as Client,l as CronExpression,t as NovuRequestHandler,u as frameworkName,g as serve,S as workflow};