Unexpected end of JSON input when sending an HTTP post request

How to post code.

Do you see any OPTIONS requests in your server logs? Do they succeed?