Closed jacksmith15 closed 4 years ago
Currently, parsing JSONSchema's to DSL objects is supported, but not the other direction. DSL Elements should expose methods which produce the equivalent JSON Schema dictionaries.
class Choice(Object): choice_text: str = Property(String(maxLength=200), required=True) votes: int = Property(Integer(default=0)) class Poll(Object): question: str = Property(String(maxLength=200), required=True) choices: List[Choice] = Property(Array(Choice), required=True) Poll.serialize() == { "type": "object", "title": "Poll", "required": ["question", "choices"], "properties": { "question": {"type": "string", "maxLength": 200}, "choices": { "type": "array", "items": { "type": "object", "title": "Choice", "required": ["choice_text"], "properties": { "choice_text": {"type": "string", "maxLength": 200}, "votes": {"type": "integer", "default": 0}, } } } } }
Some problem areas will likely include:
Problem Statement
Currently, parsing JSONSchema's to DSL objects is supported, but not the other direction. DSL Elements should expose methods which produce the equivalent JSON Schema dictionaries.
Example
Technical notes
Some problem areas will likely include: