nginx / unit

NGINX Unit - universal web app server - a lightweight and versatile open source server that simplifies the application stack by natively executing application code across eight different programming language runtimes.
https://unit.nginx.org
Apache License 2.0
5.29k stars 325 forks source link

OpenAPI Specification errors #938

Closed Pavlusha311245 closed 9 months ago

Pavlusha311245 commented 10 months ago

I downloaded the OpenAPI specification and in some sample responses I get values like in the screenshot. For example, the /certificates/:bundle endpoint should have returned an error with the error key, but not two keys named sit_7 and incididuntdb2. The specification is taken from the official site. One possible reason for the incorrect display is the use of Postman, check if possible. On the first screenshot you can see that inside OpenAPI file is described kind of correctly Also OpenAPI does not contain an update of Nginx Unit 1.31.0 version

image image
tippexs commented 10 months ago

Thanks for sharing this with us! We will take a look and provide an updated version of the spec ASAP!

Pavlusha311245 commented 10 months ago

@tippexs In addition, you can create a public API in Postman. I'm not sure if this solution is free, so it's at your discretion.

image
tippexs commented 10 months ago

Thanks for this. He have not shared anything as a public Postman API yet, but this does not mean we are not able to explore this option. We will have a look on it.

ghost commented 9 months ago

hi! there's a lot reported here, so let's discuss each item separately:

  1. PUT @ /certificates/:bundle - can't reproduce; indeed, looks like something out of Postman itself, given the telling name "incididunt" is a part of lorem ipsum stubs that Postman uses

  2. 1.31.0 - updated recently, https://hg.nginx.org/unit/rev/cfd5bf6e4324 and https://hg.nginx.org/unit/rev/438271da6ff4 for instance.

  3. The Public API network is rather intended for singleton public APIs, not per-instance APIs, it seems.