diff --git a/code/python/models/commands-schema.yaml b/code/python/models/commands-schema.yaml index 097c3a0..de589b5 100644 --- a/code/python/models/commands-schema.yaml +++ b/code/python/models/commands-schema.yaml @@ -2,7 +2,8 @@ openapi: 3.0.3 info: version: 0.1.0 title: Schemata for command instructions -servers: [] +servers: + - url: "." paths: {} components: schemas: @@ -22,9 +23,10 @@ components: Command: description: |- Instructions for command to call + type: object required: - name - properties: &ref_command_properties + properties: name: $ref: '#/components/schemas/EnumAlgorithmNames' additionalProperties: true @@ -40,16 +42,26 @@ components: - nodes - edges properties: - <<: *ref_command_properties + name: + $ref: '#/components/schemas/EnumAlgorithmNames' nodes: type: array + items: + anyOf: + - type: integer + - type: number + - type: string edges: type: array items: - # $ref: '#/components/schemas/Edge' type: array minItems: 2 maxItems: 2 + items: + anyOf: + - type: integer + - type: number + - type: string # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # Command - Algorithm: TSP # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -62,7 +74,8 @@ components: - optimise - dist properties: - <<: *ref_command_properties + name: + $ref: '#/components/schemas/EnumAlgorithmNames' dist: type: array items: @@ -83,7 +96,8 @@ components: - word1 - word2 properties: - <<: *ref_command_properties + name: + $ref: '#/components/schemas/EnumAlgorithmNames' word1: description: Word that gets placed vertically in algorithm. type: string diff --git a/code/python/models/config-schema.yaml b/code/python/models/config-schema.yaml index afac7bd..1bb0551 100644 --- a/code/python/models/config-schema.yaml +++ b/code/python/models/config-schema.yaml @@ -2,7 +2,8 @@ openapi: 3.0.3 info: version: 0.1.0 title: Schemata for config models -servers: [] +servers: + - url: "." paths: {} components: schemas: @@ -10,7 +11,7 @@ components: # Config # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Config: - descripton: |- + description: |- Data model for all parts of the configuration. type: object required: