Skip to content

Add lowcode JSON schema definitions#24893

Merged
berkansasmaz merged 4 commits intodevfrom
salihozkara/low-code-schema
Feb 18, 2026
Merged

Add lowcode JSON schema definitions#24893
berkansasmaz merged 4 commits intodevfrom
salihozkara/low-code-schema

Conversation

@salihozkara
Copy link
Member

No description provided.

Introduce a set of JSON Schema definitions for the ABP Low Code model. Adds schema files for entities, properties, property types, UI descriptors, form availability, enums, foreign keys, interceptors, command interceptors, validators, and custom HTTP endpoints, plus a top-level model.schema.json that references these definitions to validate model.json configuration files. These schemas enable validation and tooling for lowcode entity/config definitions and custom endpoint JavaScript payloads.
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds JSON Schema (draft 2020-12) files under lowcode/schema/ to validate ABP Low Code model.json configurations, including descriptors for entities, properties, enums, endpoints, interceptors, and validators.

Changes:

  • Introduces a root model.schema.json describing model.json structure.
  • Adds descriptor schemas for entities/properties/UI/enums/foreign keys/validators.
  • Adds schemas for custom endpoints and command interceptors (including interceptor timing/type).

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
lowcode/schema/model.schema.json Root schema for lowcode model.json referencing definition schemas.
lowcode/schema/definitions/validator-descriptor.schema.json Validator descriptor schema for property validators.
lowcode/schema/definitions/interceptor-type.schema.json Enum schema for interceptor execution timing.
lowcode/schema/definitions/foreign-key-descriptor.schema.json Schema for foreign key relationship configuration.
lowcode/schema/definitions/enum-descriptor.schema.json Schema for enum definitions used by entity properties.
lowcode/schema/definitions/entity-ui-descriptor.schema.json Schema for entity-level UI configuration.
lowcode/schema/definitions/entity-property-ui-form-availability.schema.json Enum schema for property form visibility/availability.
lowcode/schema/definitions/entity-property-ui-descriptor.schema.json Schema for property-level UI configuration.
lowcode/schema/definitions/entity-property-type.schema.json Enum schema for supported property data types.
lowcode/schema/definitions/entity-property-descriptor.schema.json Schema describing an entity property (type, FK, UI, validators).
lowcode/schema/definitions/entity-descriptor.schema.json Schema describing an entity (properties, UI, interceptors).
lowcode/schema/definitions/endpoint-descriptor.schema.json Schema for custom HTTP endpoints that execute JavaScript.
lowcode/schema/definitions/command-interceptor-descriptor.schema.json Schema for command interceptors (Create/Update/Delete + JS).

Comment on lines +7 to +24
"name": {
"type": "string",
"description": "Unique identifier for the endpoint"
},
"route": {
"type": "string",
"description": "URL route pattern (e.g., '/api/custom/products/{id}')"
},
"method": {
"type": "string",
"description": "HTTP method",
"enum": ["GET", "POST", "PUT", "DELETE", "PATCH"],
"default": "GET"
},
"javascript": {
"type": "string",
"description": "JavaScript code to execute. Has access to context object with request, db, currentUser, emailSender."
},
Copy link

Copilot AI Feb 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Required string fields (name, route, javascript) are not constrained to non-empty values. Elsewhere in these schemas, required names use minLength: 1; adding similar constraints here would prevent accepting empty strings that would break endpoint registration at runtime.

Copilot uses AI. Check for mistakes.
@berkansasmaz berkansasmaz merged commit 26e4a87 into dev Feb 18, 2026
2 checks passed
@berkansasmaz berkansasmaz deleted the salihozkara/low-code-schema branch February 18, 2026 13:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants