mconf/api-mate

Send POST request is being sent as an OPTIONS HTTP method

Opened this issue · 1 comments

Sending a POST request for the "create" API is sent as an OPTIONS instead. Please find HTTP headers below:

Status Complete
Response Code 200 OK
Protocol HTTP/1.1
SSL -
Method OPTIONS
Kept Alive Yes
Content-Type text/xml;charset=utf-8
Client Address /127.0.0.1

This is not necessarily an error. It is done automatically by the browser because we set the request as cross domain. So it does an OPTIONS request to check if cross domain requests are possible and then it will do the proper request.

This is where the ajax request is made in the code.

Take a look at this question on stack overflow http://stackoverflow.com/a/21783145