Skip to content

openapi message_type is defined as an enum instead of a const #17

Description

@lfse-slafleur

The field message_type is currently defined as an enum in openapi.yml.

Example from line 807:

      properties:
        message_type:
          type: string
          enum: [ "DDBC.TimerStatus" ]

Rather a constant is expected such as:

        message_type:
          const: DDBC.TimerStatus
          type: string

A const is generated differently by generators such as datamodel-codegen. An enum will be generated to its own type and it is harder to use while a const will remain a simple string.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions