controller.utilities.configuration.SubmoduleModel.model_json_schema
- classmethod SubmoduleModel.model_json_schema(by_alias=True, ref_template='#/$defs/{model}', schema_generator=<class 'pydantic.json_schema.GenerateJsonSchema'>, mode='validation')
Generates a JSON schema for a model class.
- Parameters:
by_alias (
bool, default:True) – Whether to use attribute aliases or not.ref_template (
str, default:'#/$defs/{model}') – The reference template.schema_generator (
type[GenerateJsonSchema], default:<class 'pydantic.json_schema.GenerateJsonSchema'>) – To override the logic used to generate the JSON schema, as a subclass of GenerateJsonSchema with your desired modificationsmode (
Literal['validation','serialization'], default:'validation') – The mode in which to generate the schema.
- Return type:
dict[str,Any]- Returns:
The JSON schema for the given model class.