@novu/framework 2.10.1-alpha.2 → 2.10.1-alpha.3

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.
Files changed (48) hide show
  1. package/dist/cjs/{health-check.types-Nhsa_lGZ.d.cts → health-check.types-S8oS3AQZ.d.cts} +138 -138
  2. package/dist/cjs/{index-gi0_Wcu3.d.cts → index-C5CigDlK.d.cts} +88 -13
  3. package/dist/cjs/index.cjs +58 -58
  4. package/dist/cjs/index.d.cts +3 -3
  5. package/dist/cjs/internal/index.d.cts +3 -3
  6. package/dist/cjs/servers/express.cjs +58 -58
  7. package/dist/cjs/servers/express.d.cts +4 -4
  8. package/dist/cjs/servers/h3.cjs +58 -58
  9. package/dist/cjs/servers/h3.d.cts +4 -4
  10. package/dist/cjs/servers/lambda.cjs +58 -58
  11. package/dist/cjs/servers/lambda.d.cts +5 -5
  12. package/dist/cjs/servers/nest.cjs +58 -58
  13. package/dist/cjs/servers/nest.d.cts +6 -6
  14. package/dist/cjs/servers/next.cjs +58 -58
  15. package/dist/cjs/servers/next.d.cts +4 -4
  16. package/dist/cjs/servers/nuxt.cjs +58 -58
  17. package/dist/cjs/servers/nuxt.d.cts +4 -4
  18. package/dist/cjs/servers/remix.cjs +58 -58
  19. package/dist/cjs/servers/remix.d.cts +4 -4
  20. package/dist/cjs/servers/sveltekit.cjs +58 -58
  21. package/dist/cjs/servers/sveltekit.d.cts +4 -4
  22. package/dist/cjs/step-resolver.d.cts +2 -2
  23. package/dist/esm/{chunk-FURRAVE4.js → chunk-CBVFNQC3.js} +56 -56
  24. package/dist/esm/{health-check.types-zMcfbkrA.d.ts → health-check.types-C5lg4csi.d.ts} +138 -138
  25. package/dist/esm/{index-DBjXwxNK.d.ts → index-DCSlowxV.d.ts} +88 -13
  26. package/dist/esm/index.d.ts +3 -3
  27. package/dist/esm/index.js +1 -1
  28. package/dist/esm/internal/index.d.ts +3 -3
  29. package/dist/esm/servers/express.d.ts +4 -4
  30. package/dist/esm/servers/express.js +1 -1
  31. package/dist/esm/servers/h3.d.ts +4 -4
  32. package/dist/esm/servers/h3.js +1 -1
  33. package/dist/esm/servers/lambda.d.ts +5 -5
  34. package/dist/esm/servers/lambda.js +1 -1
  35. package/dist/esm/servers/nest.d.ts +6 -6
  36. package/dist/esm/servers/nest.js +1 -1
  37. package/dist/esm/servers/next.d.ts +4 -4
  38. package/dist/esm/servers/next.js +1 -1
  39. package/dist/esm/servers/nuxt.d.ts +4 -4
  40. package/dist/esm/servers/nuxt.js +1 -1
  41. package/dist/esm/servers/remix.d.ts +4 -4
  42. package/dist/esm/servers/remix.js +1 -1
  43. package/dist/esm/servers/sveltekit.d.ts +4 -4
  44. package/dist/esm/servers/sveltekit.js +1 -1
  45. package/dist/esm/step-resolver.d.ts +2 -2
  46. package/package.json +2 -2
  47. package/dist/cjs/{subscriber.types-CNLicO8m.d.cts → subscriber.types-DgRgSKMw.d.cts} +77 -77
  48. package/dist/esm/{subscriber.types-B0sKq6v3.d.ts → subscriber.types-CbMgjzR-.d.ts} +77 -77
@@ -1,8 +1,8 @@
1
1
  import { NextRequest } from 'next/server';
2
- import { S as ServeHandlerOptions } from '../index-DBjXwxNK.js';
3
- export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentEventEnum, g as AgentHandlers, h as AgentHistoryEntry, i as AgentMessage, j as AgentMessageAuthor, k as AgentPlatformContext, l as AgentReaction, m as AgentReplyPayload, n as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, o as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, p as ReplyHandle, q as SentMessageInfo, r as Signal, T as TriggerSignal, s as agent, w as workflow } from '../index-DBjXwxNK.js';
4
- export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-zMcfbkrA.js';
5
- export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-B0sKq6v3.js';
2
+ import { S as ServeHandlerOptions } from '../index-DCSlowxV.js';
3
+ export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentDeliveryError, g as AgentEventEnum, h as AgentHandlers, i as AgentHistoryEntry, j as AgentMessage, k as AgentMessageAuthor, l as AgentPlatformContext, m as AgentReaction, n as AgentReplyPayload, o as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, p as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, q as ReplyHandle, r as SentMessageInfo, s as Signal, T as TriggerSignal, t as agent, w as workflow } from '../index-DCSlowxV.js';
4
+ export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-C5lg4csi.js';
5
+ export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-CbMgjzR-.js';
6
6
  import { S as SupportedFrameworkName } from '../server.types-BRWsA1CA.js';
7
7
  export { Actions, Button, Card, CardChild, CardElement, CardLink, CardText, Divider, Select, SelectOption, TextInput } from 'chat';
8
8
  export { AnyStepResolver, ChatStepResolver, EmailStepResolver, InAppStepResolver, PushStepResolver, SmsStepResolver, StepResolverContext, step } from '../step-resolver.js';
@@ -1 +1 @@
1
- import{a as l,b as x,c as q,d as S,e as T,f as w,g as P,h as A,i as E,j as b,k as v,l as g,m as F,n as c,o as G}from"../chunk-FURRAVE4.js";import"../chunk-T2VIX2ZH.js";import{a as I}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as k}from"../chunk-6GCCKYZC.js";import{a as j}from"../chunk-CBLKARLC.js";import{f as O}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="next",N=o=>typeof o=="object"&&o!==null&&typeof o.setHeader=="function"&&typeof o.status=="function"&&typeof o.send=="function",$=o=>{let p=new c({frameworkName:m,...o,handler:(h,R,d)=>{let n=R,i=e=>{let t=typeof n.headers.get=="function"?n.headers.get(e):n.headers[e];return Array.isArray(t)?t[0]:t};return{body:()=>typeof n.json=="function"?n.json():n.body,headers:i,method:()=>h||n.method||"",queryString:(e,t)=>{var a;let r=((a=n.query)==null?void 0:a[e])||t.searchParams.get(e);return Array.isArray(r)?r[0]:r},url:()=>{let e;try{e=new URL(n.url)}catch{}if(e){let s=i("host");if(s){let u=new URL(s.includes("://")?s:`${e.protocol}//${s}`);e.protocol=u.protocol,e.host=u.host,e.port=u.port,e.username=u.username,e.password=u.password}return e}let t="https",r=i("host")||"";try{(process.env.NODE_ENV==="development"||process.env.NODE_ENV==="dev")&&(t="http")}catch{}return new URL(n.url,`${t}://${r}`)},transformResponse:({body:e,headers:t,status:r})=>{if(N(d)){Object.entries(t).forEach(([s,u])=>{d.setHeader(s,u)}),d.status(r).send(e);return}let a=l();return new a(e,{status:r,headers:t})}}}}).createHandler(),f=p.bind(null,void 0);return Object.defineProperties(f,{GET:{value:p.bind(null,"GET")},POST:{value:p.bind(null,"POST")},OPTIONS:{value:p.bind(null,"OPTIONS")}})};export{q as Actions,F as AgentEventEnum,S as Button,T as Card,w as CardLink,P as CardText,x as Client,O as CronExpression,A as Divider,c as NovuRequestHandler,E as Select,b as SelectOption,k as SeverityLevelEnum,v as TextInput,g as agent,m as frameworkName,j as providerSchemas,$ as serve,I as step,G as workflow};
1
+ import{a as l,b as x,c as q,d as S,e as T,f as w,g as P,h as A,i as E,j as b,k as v,l as g,m as F,n as j,o as c,p as I}from"../chunk-CBVFNQC3.js";import"../chunk-T2VIX2ZH.js";import{a as U}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as G}from"../chunk-6GCCKYZC.js";import{a as k}from"../chunk-CBLKARLC.js";import{f as O}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="next",N=o=>typeof o=="object"&&o!==null&&typeof o.setHeader=="function"&&typeof o.status=="function"&&typeof o.send=="function",D=o=>{let p=new c({frameworkName:m,...o,handler:(h,R,d)=>{let n=R,i=e=>{let t=typeof n.headers.get=="function"?n.headers.get(e):n.headers[e];return Array.isArray(t)?t[0]:t};return{body:()=>typeof n.json=="function"?n.json():n.body,headers:i,method:()=>h||n.method||"",queryString:(e,t)=>{var a;let r=((a=n.query)==null?void 0:a[e])||t.searchParams.get(e);return Array.isArray(r)?r[0]:r},url:()=>{let e;try{e=new URL(n.url)}catch{}if(e){let s=i("host");if(s){let u=new URL(s.includes("://")?s:`${e.protocol}//${s}`);e.protocol=u.protocol,e.host=u.host,e.port=u.port,e.username=u.username,e.password=u.password}return e}let t="https",r=i("host")||"";try{(process.env.NODE_ENV==="development"||process.env.NODE_ENV==="dev")&&(t="http")}catch{}return new URL(n.url,`${t}://${r}`)},transformResponse:({body:e,headers:t,status:r})=>{if(N(d)){Object.entries(t).forEach(([s,u])=>{d.setHeader(s,u)}),d.status(r).send(e);return}let a=l();return new a(e,{status:r,headers:t})}}}}).createHandler(),f=p.bind(null,void 0);return Object.defineProperties(f,{GET:{value:p.bind(null,"GET")},POST:{value:p.bind(null,"POST")},OPTIONS:{value:p.bind(null,"OPTIONS")}})};export{q as Actions,g as AgentDeliveryError,j as AgentEventEnum,S as Button,T as Card,w as CardLink,P as CardText,x as Client,O as CronExpression,A as Divider,c as NovuRequestHandler,E as Select,b as SelectOption,G as SeverityLevelEnum,v as TextInput,F as agent,m as frameworkName,k as providerSchemas,D as serve,U as step,I as workflow};
@@ -1,9 +1,9 @@
1
1
  import * as h3 from 'h3';
2
2
  import { H3Event } from 'h3';
3
- import { S as ServeHandlerOptions } from '../index-DBjXwxNK.js';
4
- export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentEventEnum, g as AgentHandlers, h as AgentHistoryEntry, i as AgentMessage, j as AgentMessageAuthor, k as AgentPlatformContext, l as AgentReaction, m as AgentReplyPayload, n as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, o as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, p as ReplyHandle, q as SentMessageInfo, r as Signal, T as TriggerSignal, s as agent, w as workflow } from '../index-DBjXwxNK.js';
5
- export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-zMcfbkrA.js';
6
- export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-B0sKq6v3.js';
3
+ import { S as ServeHandlerOptions } from '../index-DCSlowxV.js';
4
+ export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentDeliveryError, g as AgentEventEnum, h as AgentHandlers, i as AgentHistoryEntry, j as AgentMessage, k as AgentMessageAuthor, l as AgentPlatformContext, m as AgentReaction, n as AgentReplyPayload, o as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, p as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, q as ReplyHandle, r as SentMessageInfo, s as Signal, T as TriggerSignal, t as agent, w as workflow } from '../index-DCSlowxV.js';
5
+ export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-C5lg4csi.js';
6
+ export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-CbMgjzR-.js';
7
7
  import { S as SupportedFrameworkName } from '../server.types-BRWsA1CA.js';
8
8
  export { Actions, Button, Card, CardChild, CardElement, CardLink, CardText, Divider, Select, SelectOption, TextInput } from 'chat';
9
9
  export { AnyStepResolver, ChatStepResolver, EmailStepResolver, InAppStepResolver, PushStepResolver, SmsStepResolver, StepResolverContext, step } from '../step-resolver.js';
@@ -1 +1 @@
1
- import{b as H,c as S,d as i,e as y,f,g,h as N,i as w,j as c,k as x,l as E,m as k,n as t,o as q}from"../chunk-FURRAVE4.js";import"../chunk-T2VIX2ZH.js";import{a as F}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as b}from"../chunk-6GCCKYZC.js";import{a as O}from"../chunk-CBLKARLC.js";import{f as l}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";import{getHeader as o,getQuery as a,readBody as n,send as p,setHeaders as m}from"h3";var u="nuxt",D=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{S as Actions,k as AgentEventEnum,i as Button,y as Card,f as CardLink,g as CardText,H as Client,l as CronExpression,N as Divider,t as NovuRequestHandler,w as Select,c as SelectOption,b as SeverityLevelEnum,x as TextInput,E as agent,u as frameworkName,O as providerSchemas,D as serve,F as step,q as workflow};
1
+ import{b as H,c as S,d as i,e as y,f,g,h as N,i as w,j as c,k as x,l as E,m as k,n as O,o as t,p as F}from"../chunk-CBVFNQC3.js";import"../chunk-T2VIX2ZH.js";import{a as $}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as q}from"../chunk-6GCCKYZC.js";import{a as b}from"../chunk-CBLKARLC.js";import{f as l}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";import{getHeader as o,getQuery as a,readBody as n,send as p,setHeaders as m}from"h3";var u="nuxt",L=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{S as Actions,E as AgentDeliveryError,O as AgentEventEnum,i as Button,y as Card,f as CardLink,g as CardText,H as Client,l as CronExpression,N as Divider,t as NovuRequestHandler,w as Select,c as SelectOption,q as SeverityLevelEnum,x as TextInput,k as agent,u as frameworkName,b as providerSchemas,L as serve,$ as step,F as workflow};
@@ -1,7 +1,7 @@
1
- import { S as ServeHandlerOptions } from '../index-DBjXwxNK.js';
2
- export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentEventEnum, g as AgentHandlers, h as AgentHistoryEntry, i as AgentMessage, j as AgentMessageAuthor, k as AgentPlatformContext, l as AgentReaction, m as AgentReplyPayload, n as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, o as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, p as ReplyHandle, q as SentMessageInfo, r as Signal, T as TriggerSignal, s as agent, w as workflow } from '../index-DBjXwxNK.js';
3
- export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-zMcfbkrA.js';
4
- export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-B0sKq6v3.js';
1
+ import { S as ServeHandlerOptions } from '../index-DCSlowxV.js';
2
+ export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentDeliveryError, g as AgentEventEnum, h as AgentHandlers, i as AgentHistoryEntry, j as AgentMessage, k as AgentMessageAuthor, l as AgentPlatformContext, m as AgentReaction, n as AgentReplyPayload, o as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, p as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, q as ReplyHandle, r as SentMessageInfo, s as Signal, T as TriggerSignal, t as agent, w as workflow } from '../index-DCSlowxV.js';
3
+ export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-C5lg4csi.js';
4
+ export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-CbMgjzR-.js';
5
5
  import { S as SupportedFrameworkName } from '../server.types-BRWsA1CA.js';
6
6
  export { Actions, Button, Card, CardChild, CardElement, CardLink, CardText, Divider, Select, SelectOption, TextInput } from 'chat';
7
7
  export { AnyStepResolver, ChatStepResolver, EmailStepResolver, InAppStepResolver, PushStepResolver, SmsStepResolver, StepResolverContext, step } from '../step-resolver.js';
@@ -1 +1 @@
1
- import{a as t,b as h,c as l,d as R,e as c,f as i,g as w,h as f,i as x,j as k,k as v,l as H,m as N,n as o,o as y}from"../chunk-FURRAVE4.js";import"../chunk-T2VIX2ZH.js";import{a as q}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as g}from"../chunk-6GCCKYZC.js";import{a as S}from"../chunk-CBLKARLC.js";import{f as u}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="remix",b=s=>new o({frameworkName:m,...s,handler:({request:e})=>({body:()=>e.json(),headers:r=>e.headers.get(r),method:()=>e.method,url:()=>new URL(e.url,`https://${e.headers.get("host")||""}`),transformResponse:({body:r,status:n,headers:p})=>{let a=t();return new a(r,{status:n,headers:p})}})}).createHandler();export{l as Actions,N as AgentEventEnum,R as Button,c as Card,i as CardLink,w as CardText,h as Client,u as CronExpression,f as Divider,o as NovuRequestHandler,x as Select,k as SelectOption,g as SeverityLevelEnum,v as TextInput,H as agent,m as frameworkName,S as providerSchemas,b as serve,q as step,y as workflow};
1
+ import{a as t,b as h,c as l,d as R,e as c,f as i,g as w,h as f,i as x,j as k,k as v,l as H,m as N,n as S,o,p as q}from"../chunk-CBVFNQC3.js";import"../chunk-T2VIX2ZH.js";import{a as F}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as y}from"../chunk-6GCCKYZC.js";import{a as g}from"../chunk-CBLKARLC.js";import{f as u}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="remix",j=s=>new o({frameworkName:m,...s,handler:({request:e})=>({body:()=>e.json(),headers:r=>e.headers.get(r),method:()=>e.method,url:()=>new URL(e.url,`https://${e.headers.get("host")||""}`),transformResponse:({body:r,status:n,headers:p})=>{let a=t();return new a(r,{status:n,headers:p})}})}).createHandler();export{l as Actions,H as AgentDeliveryError,S as AgentEventEnum,R as Button,c as Card,i as CardLink,w as CardText,h as Client,u as CronExpression,f as Divider,o as NovuRequestHandler,x as Select,k as SelectOption,y as SeverityLevelEnum,v as TextInput,N as agent,m as frameworkName,g as providerSchemas,j as serve,F as step,q as workflow};
@@ -1,8 +1,8 @@
1
1
  import { RequestEvent } from '@sveltejs/kit';
2
- import { S as ServeHandlerOptions } from '../index-DBjXwxNK.js';
3
- export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentEventEnum, g as AgentHandlers, h as AgentHistoryEntry, i as AgentMessage, j as AgentMessageAuthor, k as AgentPlatformContext, l as AgentReaction, m as AgentReplyPayload, n as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, o as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, p as ReplyHandle, q as SentMessageInfo, r as Signal, T as TriggerSignal, s as agent, w as workflow } from '../index-DBjXwxNK.js';
4
- export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-zMcfbkrA.js';
5
- export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-B0sKq6v3.js';
2
+ import { S as ServeHandlerOptions } from '../index-DCSlowxV.js';
3
+ export { A as Agent, a as AgentAction, b as AgentAttachment, c as AgentBridgeRequest, d as AgentContext, e as AgentConversation, f as AgentDeliveryError, g as AgentEventEnum, h as AgentHandlers, i as AgentHistoryEntry, j as AgentMessage, k as AgentMessageAuthor, l as AgentPlatformContext, m as AgentReaction, n as AgentReplyPayload, o as AgentSubscriber, C as Client, E as EditPayload, F as FileRef, M as MessageContent, p as MetadataSignal, N as NovuRequestHandler, R as ReplyContent, q as ReplyHandle, r as SentMessageInfo, s as Signal, T as TriggerSignal, t as agent, w as workflow } from '../index-DCSlowxV.js';
4
+ export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-C5lg4csi.js';
5
+ export { C as ContextResolved, E as EnvironmentSystemVariables, S as Subscriber, p as providerSchemas } from '../subscriber.types-CbMgjzR-.js';
6
6
  import { S as SupportedFrameworkName } from '../server.types-BRWsA1CA.js';
7
7
  export { Actions, Button, Card, CardChild, CardElement, CardLink, CardText, Divider, Select, SelectOption, TextInput } from 'chat';
8
8
  export { AnyStepResolver, ChatStepResolver, EmailStepResolver, InAppStepResolver, PushStepResolver, SmsStepResolver, StepResolverContext, step } from '../step-resolver.js';
@@ -1 +1 @@
1
- import{a as r,b as E,c as P,d as R,e as T,f as S,g as c,h as f,i as h,j as N,k as q,l as F,m as b,n as s,o as G}from"../chunk-FURRAVE4.js";import"../chunk-T2VIX2ZH.js";import{a as I}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as y}from"../chunk-6GCCKYZC.js";import{a as w}from"../chunk-CBLKARLC.js";import{f as v}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="sveltekit",g=o=>{let t=new s({frameworkName:m,...o,handler:(u,e)=>({method:()=>u||e.request.method||"",body:()=>e.request.json(),headers:n=>e.request.headers.get(n),url:()=>{let n=process.env.NODE_ENV==="development"||process.env.NODE_ENV==="dev"?"http":"https";return new URL(e.request.url,`${n}://${e.request.headers.get("host")||""}`)},transformResponse:({body:n,headers:d,status:a})=>{let l=r();return new l(n,{status:a,headers:d})}})}).createHandler(),p=t.bind(null,void 0);return Object.defineProperties(p,{GET:{value:t.bind(null,"GET")},POST:{value:t.bind(null,"POST")},OPTIONS:{value:t.bind(null,"OPTIONS")}})};export{P as Actions,b as AgentEventEnum,R as Button,T as Card,S as CardLink,c as CardText,E as Client,v as CronExpression,f as Divider,s as NovuRequestHandler,h as Select,N as SelectOption,y as SeverityLevelEnum,q as TextInput,F as agent,m as frameworkName,w as providerSchemas,g as serve,I as step,G as workflow};
1
+ import{a as r,b as E,c as P,d as R,e as T,f as S,g as c,h as f,i as h,j as N,k as q,l as F,m as b,n as w,o as s,p as I}from"../chunk-CBVFNQC3.js";import"../chunk-T2VIX2ZH.js";import{a as k}from"../chunk-2M25EATE.js";import"../chunk-U3IL7QCI.js";import{O as G}from"../chunk-6GCCKYZC.js";import{a as y}from"../chunk-CBLKARLC.js";import{f as v}from"../chunk-EWC7I6UD.js";import"../chunk-52LSX2V5.js";var m="sveltekit",x=o=>{let t=new s({frameworkName:m,...o,handler:(u,e)=>({method:()=>u||e.request.method||"",body:()=>e.request.json(),headers:n=>e.request.headers.get(n),url:()=>{let n=process.env.NODE_ENV==="development"||process.env.NODE_ENV==="dev"?"http":"https";return new URL(e.request.url,`${n}://${e.request.headers.get("host")||""}`)},transformResponse:({body:n,headers:d,status:a})=>{let l=r();return new l(n,{status:a,headers:d})}})}).createHandler(),p=t.bind(null,void 0);return Object.defineProperties(p,{GET:{value:t.bind(null,"GET")},POST:{value:t.bind(null,"POST")},OPTIONS:{value:t.bind(null,"OPTIONS")}})};export{P as Actions,F as AgentDeliveryError,w as AgentEventEnum,R as Button,T as Card,S as CardLink,c as CardText,E as Client,v as CronExpression,f as Divider,s as NovuRequestHandler,h as Select,N as SelectOption,G as SeverityLevelEnum,q as TextInput,b as agent,m as frameworkName,y as providerSchemas,x as serve,k as step,I as workflow};
@@ -1,5 +1,5 @@
1
- import { S as Subscriber, C as ContextResolved, E as EnvironmentSystemVariables, M as EmailOutputUnvalidated, g as Awaitable, p as providerSchemas, W as WithPassthrough, a2 as SmsOutputUnvalidated, l as ChatOutputUnvalidated, _ as PushOutputUnvalidated, Q as InAppOutputUnvalidated, u as DelayOutputUnvalidated, F as DigestOutputUnvalidated, a7 as ThrottleOutputUnvalidated } from './subscriber.types-B0sKq6v3.js';
2
- export { a9 as actionStepSchemas, aa as channelStepSchemas } from './subscriber.types-B0sKq6v3.js';
1
+ import { S as Subscriber, C as ContextResolved, E as EnvironmentSystemVariables, M as EmailOutputUnvalidated, g as Awaitable, p as providerSchemas, W as WithPassthrough, a2 as SmsOutputUnvalidated, l as ChatOutputUnvalidated, _ as PushOutputUnvalidated, Q as InAppOutputUnvalidated, u as DelayOutputUnvalidated, F as DigestOutputUnvalidated, a7 as ThrottleOutputUnvalidated } from './subscriber.types-CbMgjzR-.js';
2
+ export { a9 as actionStepSchemas, aa as channelStepSchemas } from './subscriber.types-CbMgjzR-.js';
3
3
  import { S as Schema, a as FromSchema } from './base.schema.types-BApIn9jr.js';
4
4
  import 'json-schema-to-ts';
5
5
  import 'zod';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@novu/framework",
3
- "version": "2.10.1-alpha.2",
3
+ "version": "2.10.1-alpha.3",
4
4
  "description": "The Code-First Notifications Workflow SDK.",
5
5
  "main": "./dist/cjs/index.cjs",
6
6
  "types": "./dist/cjs/index.d.cts",
@@ -267,7 +267,7 @@
267
267
  "cross-fetch": "^4.0.0",
268
268
  "json-schema-to-ts": "^3.0.0",
269
269
  "jsonrepair": "^3.13.1",
270
- "liquidjs": "^10.25.5",
270
+ "liquidjs": "^10.25.7",
271
271
  "pluralize": "^8.0.0",
272
272
  "sanitize-html": "^2.13.0"
273
273
  },
@@ -1,5 +1,82 @@
1
1
  import { F as FromSchemaUnvalidated, S as Schema, a as FromSchema } from './base.schema.types-BApIn9jr.cjs';
2
2
 
3
+ /**
4
+ * A type that represents either `A` or `B`. Shared properties retain their
5
+ * types and unique properties are marked as optional.
6
+ */
7
+ type Either<A, B> = Partial<A> & Partial<B> & (A | B);
8
+ /**
9
+ * A type that represents a value that may be a promise or a regular value.
10
+ */
11
+ type Awaitable<T> = T | Promise<T>;
12
+ /**
13
+ * A type that represents a type that is a prettified version of the original type.
14
+ * The prettified type has all generics removed from intellisense and displays a flat object.
15
+ */
16
+ type Prettify<T> = {
17
+ [K in keyof T]: T[K];
18
+ } & {};
19
+ /**
20
+ * Mark properties of T as optional if Condition is true
21
+ */
22
+ type ConditionalPartial<T extends Obj, Condition extends boolean> = Condition extends true ? Partial<T> : T;
23
+ /**
24
+ * Same as Nullable except without `null`.
25
+ */
26
+ type Optional<T> = T | undefined;
27
+ /**
28
+ * Types that can be used to index native JavaScript types, (Object, Array, etc.).
29
+ */
30
+ type IndexSignature = string | number | symbol;
31
+ /**
32
+ * An object of any index-able type to avoid conflicts between `{}`, `Record`, `object`, etc.
33
+ */
34
+ type Obj<O extends Record<IndexSignature, unknown> | object = Record<IndexSignature, unknown> | object> = {
35
+ [K in keyof O as K extends never ? never : K]: K extends never ? never : O[K] extends never ? never : O[K];
36
+ } & Omit<O, never>;
37
+ /**
38
+ * Any type that is indexable using `string`, `number`, or `symbol`.
39
+ */
40
+ type Indexable<ValueTypes = unknown> = {
41
+ [K: IndexSignature]: ValueTypes;
42
+ } | Obj;
43
+ /**
44
+ * Picks only the optional properties from a type, removing the required ones.
45
+ * Optionally, recurses through nested objects if `DEEP` is true.
46
+ */
47
+ type PickOptional<T, DEEP extends boolean = true> = {
48
+ [K in keyof T as undefined extends T[K] ? K : never]: DEEP extends false ? T[K] : T[K] extends Optional<Indexable> ? PickOptional<T[K], DEEP> : T[K];
49
+ };
50
+ /**
51
+ * Picks only the required fields out of a type, removing the optional ones.
52
+ * Optionally, recurses through nested objects if `DEEP` is true.
53
+ */
54
+ type PickRequired<T, DEEP extends boolean = true> = {
55
+ [K in keyof T as K extends keyof PickOptional<T, DEEP> ? never : K]: T[K] extends Indexable ? PickRequired<T[K], DEEP> : T[K];
56
+ };
57
+ /**
58
+ * Picks only the required keys out of a type, removing the optional ones.
59
+ * Optionally, recurses through nested objects if `DEEP` is true.
60
+ */
61
+ type PickRequiredKeys<T, DEEP extends boolean = true> = keyof PickRequired<T, DEEP>;
62
+ /**
63
+ * Picks only the optional keys out of a type, removing the required ones.
64
+ * Optionally, recurses through nested objects if `DEEP` is true.
65
+ */
66
+ type PickOptionalKeys<T, DEEP extends boolean = true> = keyof PickOptional<T, DEEP>;
67
+ /**
68
+ * Recursively make all properties of type `T` optional.
69
+ */
70
+ type DeepPartial<T> = T extends object ? {
71
+ [P in keyof T]?: DeepPartial<T[P]>;
72
+ } : T;
73
+ /**
74
+ * Recursively make all properties of type `T` required.
75
+ */
76
+ type DeepRequired<T> = T extends object ? {
77
+ [P in keyof T]-?: DeepRequired<T[P]>;
78
+ } : T;
79
+
3
80
  type ContextType = string;
4
81
  type ContextId = string;
5
82
  type ContextData = Record<string, unknown>;
@@ -112,83 +189,6 @@ declare enum ActionStepEnum {
112
189
  HTTP_REQUEST = "http_request"
113
190
  }
114
191
 
115
- /**
116
- * A type that represents either `A` or `B`. Shared properties retain their
117
- * types and unique properties are marked as optional.
118
- */
119
- type Either<A, B> = Partial<A> & Partial<B> & (A | B);
120
- /**
121
- * A type that represents a value that may be a promise or a regular value.
122
- */
123
- type Awaitable<T> = T | Promise<T>;
124
- /**
125
- * A type that represents a type that is a prettified version of the original type.
126
- * The prettified type has all generics removed from intellisense and displays a flat object.
127
- */
128
- type Prettify<T> = {
129
- [K in keyof T]: T[K];
130
- } & {};
131
- /**
132
- * Mark properties of T as optional if Condition is true
133
- */
134
- type ConditionalPartial<T extends Obj, Condition extends boolean> = Condition extends true ? Partial<T> : T;
135
- /**
136
- * Same as Nullable except without `null`.
137
- */
138
- type Optional<T> = T | undefined;
139
- /**
140
- * Types that can be used to index native JavaScript types, (Object, Array, etc.).
141
- */
142
- type IndexSignature = string | number | symbol;
143
- /**
144
- * An object of any index-able type to avoid conflicts between `{}`, `Record`, `object`, etc.
145
- */
146
- type Obj<O extends Record<IndexSignature, unknown> | object = Record<IndexSignature, unknown> | object> = {
147
- [K in keyof O as K extends never ? never : K]: K extends never ? never : O[K] extends never ? never : O[K];
148
- } & Omit<O, never>;
149
- /**
150
- * Any type that is indexable using `string`, `number`, or `symbol`.
151
- */
152
- type Indexable<ValueTypes = unknown> = {
153
- [K: IndexSignature]: ValueTypes;
154
- } | Obj;
155
- /**
156
- * Picks only the optional properties from a type, removing the required ones.
157
- * Optionally, recurses through nested objects if `DEEP` is true.
158
- */
159
- type PickOptional<T, DEEP extends boolean = true> = {
160
- [K in keyof T as undefined extends T[K] ? K : never]: DEEP extends false ? T[K] : T[K] extends Optional<Indexable> ? PickOptional<T[K], DEEP> : T[K];
161
- };
162
- /**
163
- * Picks only the required fields out of a type, removing the optional ones.
164
- * Optionally, recurses through nested objects if `DEEP` is true.
165
- */
166
- type PickRequired<T, DEEP extends boolean = true> = {
167
- [K in keyof T as K extends keyof PickOptional<T, DEEP> ? never : K]: T[K] extends Indexable ? PickRequired<T[K], DEEP> : T[K];
168
- };
169
- /**
170
- * Picks only the required keys out of a type, removing the optional ones.
171
- * Optionally, recurses through nested objects if `DEEP` is true.
172
- */
173
- type PickRequiredKeys<T, DEEP extends boolean = true> = keyof PickRequired<T, DEEP>;
174
- /**
175
- * Picks only the optional keys out of a type, removing the required ones.
176
- * Optionally, recurses through nested objects if `DEEP` is true.
177
- */
178
- type PickOptionalKeys<T, DEEP extends boolean = true> = keyof PickOptional<T, DEEP>;
179
- /**
180
- * Recursively make all properties of type `T` optional.
181
- */
182
- type DeepPartial<T> = T extends object ? {
183
- [P in keyof T]?: DeepPartial<T[P]>;
184
- } : T;
185
- /**
186
- * Recursively make all properties of type `T` required.
187
- */
188
- type DeepRequired<T> = T extends object ? {
189
- [P in keyof T]-?: DeepRequired<T[P]>;
190
- } : T;
191
-
192
192
  declare const providerSchemas: {
193
193
  readonly chat: {
194
194
  readonly 'chat-webhook': {
@@ -1,5 +1,82 @@
1
1
  import { F as FromSchemaUnvalidated, S as Schema, a as FromSchema } from './base.schema.types-BApIn9jr.js';
2
2
 
3
+ /**
4
+ * A type that represents either `A` or `B`. Shared properties retain their
5
+ * types and unique properties are marked as optional.
6
+ */
7
+ type Either<A, B> = Partial<A> & Partial<B> & (A | B);
8
+ /**
9
+ * A type that represents a value that may be a promise or a regular value.
10
+ */
11
+ type Awaitable<T> = T | Promise<T>;
12
+ /**
13
+ * A type that represents a type that is a prettified version of the original type.
14
+ * The prettified type has all generics removed from intellisense and displays a flat object.
15
+ */
16
+ type Prettify<T> = {
17
+ [K in keyof T]: T[K];
18
+ } & {};
19
+ /**
20
+ * Mark properties of T as optional if Condition is true
21
+ */
22
+ type ConditionalPartial<T extends Obj, Condition extends boolean> = Condition extends true ? Partial<T> : T;
23
+ /**
24
+ * Same as Nullable except without `null`.
25
+ */
26
+ type Optional<T> = T | undefined;
27
+ /**
28
+ * Types that can be used to index native JavaScript types, (Object, Array, etc.).
29
+ */
30
+ type IndexSignature = string | number | symbol;
31
+ /**
32
+ * An object of any index-able type to avoid conflicts between `{}`, `Record`, `object`, etc.
33
+ */
34
+ type Obj<O extends Record<IndexSignature, unknown> | object = Record<IndexSignature, unknown> | object> = {
35
+ [K in keyof O as K extends never ? never : K]: K extends never ? never : O[K] extends never ? never : O[K];
36
+ } & Omit<O, never>;
37
+ /**
38
+ * Any type that is indexable using `string`, `number`, or `symbol`.
39
+ */
40
+ type Indexable<ValueTypes = unknown> = {
41
+ [K: IndexSignature]: ValueTypes;
42
+ } | Obj;
43
+ /**
44
+ * Picks only the optional properties from a type, removing the required ones.
45
+ * Optionally, recurses through nested objects if `DEEP` is true.
46
+ */
47
+ type PickOptional<T, DEEP extends boolean = true> = {
48
+ [K in keyof T as undefined extends T[K] ? K : never]: DEEP extends false ? T[K] : T[K] extends Optional<Indexable> ? PickOptional<T[K], DEEP> : T[K];
49
+ };
50
+ /**
51
+ * Picks only the required fields out of a type, removing the optional ones.
52
+ * Optionally, recurses through nested objects if `DEEP` is true.
53
+ */
54
+ type PickRequired<T, DEEP extends boolean = true> = {
55
+ [K in keyof T as K extends keyof PickOptional<T, DEEP> ? never : K]: T[K] extends Indexable ? PickRequired<T[K], DEEP> : T[K];
56
+ };
57
+ /**
58
+ * Picks only the required keys out of a type, removing the optional ones.
59
+ * Optionally, recurses through nested objects if `DEEP` is true.
60
+ */
61
+ type PickRequiredKeys<T, DEEP extends boolean = true> = keyof PickRequired<T, DEEP>;
62
+ /**
63
+ * Picks only the optional keys out of a type, removing the required ones.
64
+ * Optionally, recurses through nested objects if `DEEP` is true.
65
+ */
66
+ type PickOptionalKeys<T, DEEP extends boolean = true> = keyof PickOptional<T, DEEP>;
67
+ /**
68
+ * Recursively make all properties of type `T` optional.
69
+ */
70
+ type DeepPartial<T> = T extends object ? {
71
+ [P in keyof T]?: DeepPartial<T[P]>;
72
+ } : T;
73
+ /**
74
+ * Recursively make all properties of type `T` required.
75
+ */
76
+ type DeepRequired<T> = T extends object ? {
77
+ [P in keyof T]-?: DeepRequired<T[P]>;
78
+ } : T;
79
+
3
80
  type ContextType = string;
4
81
  type ContextId = string;
5
82
  type ContextData = Record<string, unknown>;
@@ -112,83 +189,6 @@ declare enum ActionStepEnum {
112
189
  HTTP_REQUEST = "http_request"
113
190
  }
114
191
 
115
- /**
116
- * A type that represents either `A` or `B`. Shared properties retain their
117
- * types and unique properties are marked as optional.
118
- */
119
- type Either<A, B> = Partial<A> & Partial<B> & (A | B);
120
- /**
121
- * A type that represents a value that may be a promise or a regular value.
122
- */
123
- type Awaitable<T> = T | Promise<T>;
124
- /**
125
- * A type that represents a type that is a prettified version of the original type.
126
- * The prettified type has all generics removed from intellisense and displays a flat object.
127
- */
128
- type Prettify<T> = {
129
- [K in keyof T]: T[K];
130
- } & {};
131
- /**
132
- * Mark properties of T as optional if Condition is true
133
- */
134
- type ConditionalPartial<T extends Obj, Condition extends boolean> = Condition extends true ? Partial<T> : T;
135
- /**
136
- * Same as Nullable except without `null`.
137
- */
138
- type Optional<T> = T | undefined;
139
- /**
140
- * Types that can be used to index native JavaScript types, (Object, Array, etc.).
141
- */
142
- type IndexSignature = string | number | symbol;
143
- /**
144
- * An object of any index-able type to avoid conflicts between `{}`, `Record`, `object`, etc.
145
- */
146
- type Obj<O extends Record<IndexSignature, unknown> | object = Record<IndexSignature, unknown> | object> = {
147
- [K in keyof O as K extends never ? never : K]: K extends never ? never : O[K] extends never ? never : O[K];
148
- } & Omit<O, never>;
149
- /**
150
- * Any type that is indexable using `string`, `number`, or `symbol`.
151
- */
152
- type Indexable<ValueTypes = unknown> = {
153
- [K: IndexSignature]: ValueTypes;
154
- } | Obj;
155
- /**
156
- * Picks only the optional properties from a type, removing the required ones.
157
- * Optionally, recurses through nested objects if `DEEP` is true.
158
- */
159
- type PickOptional<T, DEEP extends boolean = true> = {
160
- [K in keyof T as undefined extends T[K] ? K : never]: DEEP extends false ? T[K] : T[K] extends Optional<Indexable> ? PickOptional<T[K], DEEP> : T[K];
161
- };
162
- /**
163
- * Picks only the required fields out of a type, removing the optional ones.
164
- * Optionally, recurses through nested objects if `DEEP` is true.
165
- */
166
- type PickRequired<T, DEEP extends boolean = true> = {
167
- [K in keyof T as K extends keyof PickOptional<T, DEEP> ? never : K]: T[K] extends Indexable ? PickRequired<T[K], DEEP> : T[K];
168
- };
169
- /**
170
- * Picks only the required keys out of a type, removing the optional ones.
171
- * Optionally, recurses through nested objects if `DEEP` is true.
172
- */
173
- type PickRequiredKeys<T, DEEP extends boolean = true> = keyof PickRequired<T, DEEP>;
174
- /**
175
- * Picks only the optional keys out of a type, removing the required ones.
176
- * Optionally, recurses through nested objects if `DEEP` is true.
177
- */
178
- type PickOptionalKeys<T, DEEP extends boolean = true> = keyof PickOptional<T, DEEP>;
179
- /**
180
- * Recursively make all properties of type `T` optional.
181
- */
182
- type DeepPartial<T> = T extends object ? {
183
- [P in keyof T]?: DeepPartial<T[P]>;
184
- } : T;
185
- /**
186
- * Recursively make all properties of type `T` required.
187
- */
188
- type DeepRequired<T> = T extends object ? {
189
- [P in keyof T]-?: DeepRequired<T[P]>;
190
- } : T;
191
-
192
192
  declare const providerSchemas: {
193
193
  readonly chat: {
194
194
  readonly 'chat-webhook': {