UNPKG

@novu/framework

Version:

The Code-First Notifications Workflow SDK.

31 lines (28 loc) 1.56 kB
import * as aws_lambda from 'aws-lambda'; import { APIGatewayProxyEventV2, APIGatewayProxyResult } from 'aws-lambda'; import { S as ServeHandlerOptions } from '../index-BTTxx1ad.cjs'; export { C as Client, N as NovuRequestHandler, w as workflow } from '../index-BTTxx1ad.cjs'; export { C as ClientOptions, a as CronExpression, E as ExecuteInput, S as SeverityLevelEnum, W as Workflow } from '../health-check.types-DwKatX-8.cjs'; import { E as Either } from '../subscriber.types-CftO3aFY.cjs'; export { C as ContextResolved, S as Subscriber, p as providerSchemas } from '../subscriber.types-CftO3aFY.cjs'; import { S as SupportedFrameworkName } from '../server.types-BRWsA1CA.cjs'; export { AnyStepResolver, ChatStepResolver, EmailStepResolver, InAppStepResolver, PushStepResolver, SmsStepResolver, StepResolverContext, step } from '../step-resolver.cjs'; import '../base.schema.types-BApIn9jr.cjs'; import 'json-schema-to-ts'; import 'zod'; declare const frameworkName: SupportedFrameworkName; /** * With AWS Lambda, serve and register any declared workflows with Novu, * making them available to be triggered by events. * * @example * * ```ts * import { serve } from "@novu/framework/lambda"; * import { myWorkflow } from "./src/novu/workflows"; * * export const handler = serve({ workflows: [myWorkflow] }); * ``` */ declare const serve: (options: ServeHandlerOptions) => (event: Either<aws_lambda.APIGatewayProxyEvent, APIGatewayProxyEventV2>) => Promise<Promise<APIGatewayProxyResult>>; export { ServeHandlerOptions, frameworkName, serve };