nasa / api-docs

api.nasa.gov
http://nasa.github.io/api-docs/
450 stars 109 forks source link

Image API Not Respecting CORS #85

Closed andrewconnell closed 7 years ago

andrewconnell commented 7 years ago

The docs for the images.nasa.gov Image REST API says it supports CORS: https://images.nasa.gov/docs/images.nasa.gov_api_docs.pdf

However, client side calls are being kicked back:

XMLHttpRequest cannot load https://images-api.nasa.gov/search?q=Apollo%204&media_type=image. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:4200' is therefore not allowed access.

Oversight?

jasonduley commented 7 years ago

The APOD API is a different API from this API (which is the API to images.nasa.gov). I'll forward a note to that admin. Sorry for the confusion, I agree CORS should be enabled.

andrewconnell commented 7 years ago

Thanks @jasonduley. Is there a different repo to track that API? Had a hard time finding a spot to find more information on that API other than the single PDF.

jasonduley commented 7 years ago

just added a pointer for the API to api.nasa.gov. Please track it here!

charlescbeebe commented 7 years ago

@andrewconnell thanks for the heads up. Issue should be fixed, now.