Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/http-api/swagger.json is not CORS enabled #36

Open
chameleonbr opened this issue Jan 20, 2016 · 2 comments
Open

/http-api/swagger.json is not CORS enabled #36

chameleonbr opened this issue Jan 20, 2016 · 2 comments

Comments

@chameleonbr
Copy link

I have swagger UI on other server and I try to link with my node-red swagger API but CORS headers are not found on /http-api/swagger.json

curl -I http://myhost:1880/http-api/swagger.json
HTTP/1.1 200 OK
X-Powered-By: Express
Content-Type: application/json; charset=utf-8
Content-Length: 921
ETag: W/"399-O+kHybLKLLCZ4lh4LITBaw"
Date: Wed, 20 Jan 2016 19:58:17 GMT
Connection: keep-alive

Placing the configuration:

httpNodeCors: {
        origin: "*",
        methods: "GET,PUT,POST,DELETE"
    },

it still happens

@knolleary
Copy link
Member

Thanks for raising. The httpNodeCors configuration only gets applies to the HTTP In nodes - other things don't get it 'for free'. Will need to add in the proper handling for it in this node.

@tonykambo
Copy link

It doesn't look like CORS support has been added yet. This would greatly be appreciated.

(Allowing external access to the swagger UI tab instead would be even better! Should I raise that asa feature request or is it unlikely to be implemented?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants