Class PayloadWrapperBase<TPayload>
Constructors
Properties
Methods
dataHash
- dataHash(): Promise<Lowercase<string>>
Returns Promise<Lowercase<string>>
getErrors
- getErrors(): Promise<Error[]>
Returns Promise<Error[]>
getValid
- getValid(): Promise<boolean>
Returns Promise<boolean>
schema
- schema(): string
Returns string
validate
- validate(): Promisable<Error[]>
Returns Promisable<Error[]>
Static
unwrap
- unwrap<
TPayload extends
DeepRestrictToStringKeys<{ schema: string }> = DeepRestrictToStringKeys<
{ schema: string },
>,
>(
payload?: TPayload,
): undefined | TPayload Returns undefined | TPayload
- unwrap<
TPayload extends
DeepRestrictToStringKeys<{ schema: string }> = DeepRestrictToStringKeys<
{ schema: string },
>,
TWrapper extends
PayloadWrapperBase<TPayload> = PayloadWrapperBase<TPayload>,
>(
payload: TPayload | TWrapper,
): TPayload - unwrap<
TPayload extends
DeepRestrictToStringKeys<{ schema: string }> = DeepRestrictToStringKeys<
{ schema: string },
>,
TWrapper extends
PayloadWrapperBase<TPayload> = PayloadWrapperBase<TPayload>,
>(
payload: (TPayload | TWrapper)[],
): TPayload[]
Static
unwrapSinglePayload