I get this error message when trying to add a new post using the User API key feature.
As discussed previously for different values, I think Content-Type
should be also added to Access-Control-Allow-Headers
header as defined in https://github.com/discourse/discourse/blob/master/config/initializers/008-rack-cors.rb#L42
Here is a PR that fixes this little bug.