MCPcopy Index your code
hub / github.com/simstudioai/sim / defineRouteContract

Function defineRouteContract

apps/sim/lib/api/contracts/types.ts:81–92  ·  view source on GitHub ↗
(
  contract: ApiRouteContract<TParams, TQuery, TBody, THeaders, TResponse, TError>
)

Source from the content-addressed store, hash-verified

79>
80
81export function defineRouteContract<
82 TParams extends ApiSchema | undefined = undefined,
83 TQuery extends ApiSchema | undefined = undefined,
84 TBody extends ApiSchema | undefined = undefined,
85 THeaders extends ApiSchema | undefined = undefined,
86 TResponse extends ResponseMode = ResponseMode,
87 TError extends ApiSchema | undefined = undefined,
88>(
89 contract: ApiRouteContract<TParams, TQuery, TBody, THeaders, TResponse, TError>
90): ApiRouteContract<TParams, TQuery, TBody, THeaders, TResponse, TError> {
91 return contract
92}
93
94export type ContractParams<C extends AnyApiRouteContract> = C extends ApiRouteContract<
95 infer TParams,

Callers 15

request.test.tsFile · 0.90
skills.tsFile · 0.90
common.tsFile · 0.90
usage-limits.tsFile · 0.90
logs.tsFile · 0.90
admin.tsFile · 0.90
inbox.tsFile · 0.90
mcp.tsFile · 0.90
environment.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected