freme-project / freme-project.github.io

Apache License 2.0
2 stars 0 forks source link

can't retrieve token #299

Closed m1ci closed 8 years ago

m1ci commented 8 years ago

Im trying to authenticate (retrieve token) using FREME live documentation page at https://freme-project.github.io/api-doc/full.html#!/User/post_user but I get "no content" for response body and { "error": "no response from server" } as response header.

m1ci commented 8 years ago

via curl works, so probably there is CORS issue

jnehring commented 8 years ago

looks like a cors issue. The Javascript console reports

XMLHttpRequest cannot load https://api.freme-project.eu/current/authenticate. Request header field X-Auth-Password is not allowed by Access-Control-Allow-Headers in preflight response.
m1ci commented 8 years ago

yes, all sent/received headers should be allowed in the pre-flight request via Access-Control-Allow-Headers

jnehring commented 8 years ago

This is fixed on freme-dev. Will try in the next release if this will be fixed on freme-live also.

jnehring commented 8 years ago

fixed by https://github.com/freme-project/technical-discussion/issues/125