import type { SSMClient, SSMClientConfig } from "@aws-sdk/client-ssm"; import type middy from "@middy/core"; import type { Options as MiddyOptions } from "@middy/util"; import type { Context as LambdaContext } from "aws-lambda"; export type ParamType = string & { __returnType?: T }; export declare function ssmParam(path: string): ParamType; export interface SSMOptions extends Omit, "fetchData"> { fetchData?: { [key: string]: string | ParamType }; } export type Context = TOptions extends { setToContext: true } ? TOptions extends { fetchData: infer TFetchData } ? LambdaContext & { [Key in keyof TFetchData]: TFetchData[Key] extends ParamType ? T : unknown; } : never : LambdaContext; export type Internal = TOptions extends SSMOptions ? TOptions extends { fetchData: infer TFetchData } ? { [Key in keyof TFetchData]: TFetchData[Key] extends ParamType ? T : unknown; } : {} : {}; declare function ssm( options?: TOptions, ): middy.MiddlewareObj< unknown, any, Error, Context, Internal >; export default ssm;