Interface: IRoute
Represents a generic API route configuration, encapsulating the types for request and response bodies, as well as any required headers. This interface serves as a template for defining the contract for a specific API endpoint, ensuring type safety and consistency in request/response handling.
request
: Specifies the expected structure of the request body, derived fromIRequest
.response
: Specifies the expected structure of the response body, derived fromIResponse
.headers
: Specifies the expected structure of the request/response headers, derived fromIHeaders
.IRoute
Hierarchy
Properties
headers
• headers: IHeaders
The type of the headers for the request/response.
Defined in
lib/types/common/index.ts:57
request
• request: IRequest
The type of the request data.
Defined in
lib/types/common/index.ts:55
response
• response: IResponse
The type of the response data.
Defined in
lib/types/common/index.ts:56