Forum Discussion

ssingh137's avatar
ssingh137
New Member
2 years ago

Does OpenAPI 3.0 supports enum as reusable component for Path Parameters?

Hi There, 

 

Does OpenAPI 3.0 supports enum as reusable component for Path Parameters?

Here is an example"

parameters:
- in: path
 name: status
 schema:
     type: string
     $ref: "#/components/schemas/Status"

 

Status:
    type: string
    enum:
         - Approved
         - Pending
         - Closed
         - New

is it valid syntax?