Skip to main content
zerotal

Documentation


Documentation / zerotal / client / BodyOf

Type Alias: BodyOf<Routes, Method, Path>

BodyOf<Routes, Method, Path> = `${Method} ${Path}` extends keyof Routes ? Routes[`${Method} ${Path}`] extends object ? B : Record<string, unknown> : Record<string, unknown>

Defined in: packages/client/src/types.ts:93

Get the body type for a specific method + path combination.

Type Parameters

Routes

Routes extends ApiRouteMap

Method

Method extends HttpMethod

Path

Path extends string