Skip to content

MethodsWithResponseType

MethodsWithResponseType<S, RT> = { [K in keyof S["methods"]]: S["methods"][K]["responseType"] extends RT ? K : never }[keyof S["methods"]]

Defined in: packages/core/src/schema-types.ts:111

Extract method names that have a specific response type.

Used to constrain stream() to only accept methods with responseType: "stream".

S extends Schema

RT extends string