Skip to main content

ResolverContract

@h4ad/serverless-adapter > ResolverContract

(interface) ResolverContract

The interface that represents the contract used to send the response to the client

Signature:

export interface ResolverContract<TEvent, TContext, TCallback, TResponse, TReturn> 

(method) createResolver

Create the resolver based on the context, callback or promise

Signature:

createResolver(props: ResolverProps<TEvent, TContext, TCallback, TResponse>): Resolver<TResponse, TReturn>;

Parameters

ParameterTypeDescription
propsResolverProps <TEvent, TContext, TCallback, TResponse>The props used to create the resolver

Returns:

Resolver <TResponse, TReturn>