0

I have this list and I need the client to choose none or one or both of them and include it in the body post request with OpenApi 3.0:

[none, apple, banana, [apple, banana]]

this is what I did so far but not sure

 frut_type:
          type: string
          nullable: true
          enum:
            - null
            - apple
            - banana
            - enum: [ apple, banana ]
    enter code here
    ```
MadCodex
  • 35
  • 7
  • 1
    You probably need to define `fruit_type` as an "array of enums" - see [the 1st example in this question](https://stackoverflow.com/q/36888626/113116). – Helen Jun 28 '22 at 13:30
  • yeah that what i did and it's worked fine – MadCodex Jun 29 '22 at 10:36

0 Answers0