From ca4951dfc5e2f230c621f6de0f806f8bf7806b58 Mon Sep 17 00:00:00 2001 From: Nathan Thorpe Date: Mon, 28 Jul 2025 11:19:19 -0700 Subject: [PATCH] add public method to get json schema --- cirro/models/form_specification.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cirro/models/form_specification.py b/cirro/models/form_specification.py index 1b35f739..dd16bdbb 100644 --- a/cirro/models/form_specification.py +++ b/cirro/models/form_specification.py @@ -28,6 +28,13 @@ def __init__(self, form_schema: FormSchema): self._form_spec_ui: Dict = form_schema.ui.additional_properties self.form_spec = _get_fields_in_schema(self._form_spec_raw.get('properties') or {}) + @property + def form_spec_json(self) -> dict: + """ + Returns the JSON schema of the form specification + """ + return self._form_spec_raw + def validate_params(self, params: Dict): """ Validates that the given parameters conforms to the specification