MCPcopy Create free account
hub / github.com/middleapi/orpc / toOpenAPISchema

Function toOpenAPISchema

packages/openapi/src/openapi-utils.ts:161–167  ·  view source on GitHub ↗
(schema: JSONSchema)

Source from the content-addressed store, hash-verified

159 * @internal
160 */
161export function toOpenAPISchema(schema: JSONSchema): OpenAPI.SchemaObject & object {
162 return schema === true
163 ? {}
164 : schema === false
165 ? { not: {} }
166 : schema as OpenAPI.SchemaObject
167}
168
169const OPENAPI_JSON_SCHEMA_REF_PREFIX = /* @__PURE__ */ '#/components/schemas/'
170

Callers 6

#resolveCommonSchemasMethod · 0.90
#successResponseMethod · 0.90
toOpenAPIContentFunction · 0.85
toOpenAPIParametersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected