node-red / node-red-node-swagger

A set of tools for generating Swagger api documentation based on the HTTP nodes deployed in a flow
Apache License 2.0
63 stars 48 forks source link

No host and schemes fields in swagger #78

Open kazuhitoyokoi opened 3 years ago

kazuhitoyokoi commented 3 years ago

What are the steps to reproduce?

  1. Install node-red-node-swagger on Node-RED flow editor.
  2. Create REST API using http-in, template, http response nodes.
  3. Import the generated swagger definition on Swagger Editor using the URL, http://localhost:1880/http-api/swagger.json .
  4. Access the endpoint from the Swagger Editor.

What happens?

"404 Not Found" error occurred because the Swagger Editor access the own URL, https://editor.swagger.io/

1

What do you expect to happen?

The swagger definition contains host and schemes fields. And the Swagger Editor can access the endpoint on Node-RED.

2

Please tell us about your environment:

kazuhitoyokoi commented 3 years ago

@knolleary @dceejay Could you review this pull request when you have time?

dceejay commented 3 years ago

HI - sorry - yes it looks good to me. Happy to merge. @knolleary ?