StaticcontentThe entity instance for which to generate the content schema. The generic type T must extend CoreEntity.
An object containing the content schema, or undefined if no metadata is available for the entity.
StaticdefaultGenerates a default response mapping for the specified HTTP status types.
The HTTP status types for which default responses should be created.
An object mapping each provided status type to its default response definition.
StaticeditorStaticentityGenerates a Swagger content definition for the provided entity.
The entity instance to derive the Swagger schema from.
Optionallist: boolean
When true, the schema will be wrapped in an array type, representing a list of entities.
The Swagger content object for the entity, or undefined if the entity does not have a schema.
Staticentityextends CoreEntity
The entity instance for which to build the response configuration.
Optionallist: boolean
Indicates whether the response should represent a list of entities.
Optionalcreate: boolean
Indicates whether the response corresponds to a creation operation (status code 201); otherwise 200.
The Swagger response configuration object containing the appropriate status code and content.
StaticformBuilds a Swagger request body for multipart/form-data requests.
Optionalschema: SSchemaEl
Optional schema describing the form data.
If omitted, a default schema with a single binary file field is provided.
Swagger request body definition with
multipart/form-data content and the supplied or default schema.
StaticjsonCreates a request body definition for JSON content type using the provided schema.
The JSON schema used for validating the request body.
A Swagger path request body object specifying application/json content type with the provided schema.
StaticjsonBuilds a Swagger response configuration object for a given HTTP status code and schema.
The primary HTTP status code for the response.
The JSON schema definition for the response body.
If true, the schema is wrapped in an array for list responses.
Additional HTTP status codes for default responses.
The constructed response configuration object.
StaticrefCreates a Swagger request body definition that references a schema.
Either the string reference to a schema or a CoreEntity instance whose
class name will be used to build the reference path.
If true, the referenced schema is wrapped in an array; otherwise the schema is used directly.
The request body object containing the appropriate content and schema configuration.
StaticrefCreates a Swagger response configuration for a given HTTP status code.
The primary HTTP status code for
StaticschemaGenerates a mapping from entity names to their corresponding schema objects.
The entities for which schema entries should be generated.
An object whose keys are entity names and values are the schemas derived from those entities.
StaticschemaGenerates a JSON schema representation from a CoreEntity instance.
This method inspects the entity's metadata to construct a schema object describing the entity's shape. The resulting schema contains:
type: always "object".description: a string indicating the entity name.required: an array of property names that are defined on the entity.properties: an object mapping each property name to an object that
includes the resolved database type and its nullability.If no metadata is found for the provided entity, the method returns undefined.
The entity instance for which to create a schema.
The generated schema object, or undefined
if the entity's metadata could not be retrieved.
Use ESchemaEditor.schemaFromEntity instead.
StaticschemaStaticschemaBuilds a JSON schema reference path for the given component name.
The name of the schema component.
The JSON reference path formatted as #/components/schemas/<inp>.
Generates a content schema object for the given entity. The schema contains a description derived from the entity metadata and a JSON content schema based on the entity's structure.