Forum Discussion

discard's avatar
discard
Occasional Visitor
6 years ago

Can we describe the json inside a zip file in swagger.

I have an API  (/report) which returns zip file in response. I can describe the output in the swagger using schema.format=binary. Is it possible to describe the contents of the zip file in the swagger ?

Zip file contains a report folder and report folder cotains report.json.

 

  • Hi discard,

     

    OpenAPI Specification does not have a way to define the contents of ZIP files, but you can provide any additional information in the "description" key of the operation or response.

  • HKosova's avatar
    HKosova
    SmartBear Alumni (Retired)

    Hi discard,

     

    OpenAPI Specification does not have a way to define the contents of ZIP files, but you can provide any additional information in the "description" key of the operation or response.