How to control Videolan VLC through HTTP JSON requests?
<p>I am trying to build a web application to control a VLC media player.
Once enabled the web interface, I can successfully submit requests with Postman. Instead in my app, using jQuery to make AJAX calls, the XMLHttpRequest fails with a 501 during preflight.</p>

<p>This is the simple AJAX call i make:</p>

<pre><code>$.ajax({
    method: 'GET',
    url:     'http://127.0.0.1:8080/requests/status.json',
    headers: {
        "Authorization": "Basic " + btoa("" + ":" + "password")
    },
})
</code></pre>

<p>This is the answer:</p>

<blockquote>
  <p>XMLHttpRequest cannot load <a href="http://127.0.0.1:8080/requests/status.json" rel="nofollow">http://127.0.0.1:8080/requests/status.json</a>. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin '<a href="http://localhost:8081" rel="nofollow">http://localhost:8081</a>' is therefore not allowed access. The response had HTTP status code 501.</p>
</blockquote>

<p>VLC's internal server does not support CORS or am I doing something wrong?</p>