@upstash/qstash
Version:
Official Typescript client for QStash
23 lines (20 loc) • 985 B
TypeScript
import * as h3 from 'h3';
import { H3Event } from 'h3';
import { a9 as RouteFunction, aa as WorkflowServeOptions } from './client-DKNfczbM.js';
import 'neverthrow';
type VerifySignatureConfig = {
currentSigningKey?: string;
nextSigningKey?: string;
clockTolerance?: number;
};
declare const verifySignatureH3: (handler: (event: H3Event) => Promise<unknown>, config?: VerifySignatureConfig) => h3.EventHandler<h3.EventHandlerRequest, Promise<unknown>>;
/**
* @deprecated as of version 2.7.17. Will be removed in qstash-js 3.0.0.
* Please use https://github.com/upstash/workflow-js
* Migration Guide: https://upstash.com/docs/workflow/migration
*/
declare const serve: <TInitialPayload = unknown>(routeFunction: RouteFunction<TInitialPayload>, options?: Omit<WorkflowServeOptions<Response, TInitialPayload>, "onStepFinish">) => h3.EventHandler<h3.EventHandlerRequest, Promise<Response | {
status: number;
body: string;
}>>;
export { serve, verifySignatureH3 };