title: Github API error "Problems parsing JSON" when using curl but works fine with Postman
body: <p>I am trying to create a release using Github's API.</p>
  
  <p>My request works fine in Postman but no matter what I've tried it always fails with curl, including if I just translate my Postman request into curl using Postman.</p>
  
  <p>This is the body of my Postman POST request:</p>
  
  <pre><code>{
      "tag_name": "4.2.0",
      "target_commitish": "master",
      "name": "4.2.0",
      "body": "test"
  }
  </code></pre>
  
  <p>I've included an authorization header of type "Basic", where I input my username and a token I have created for this purpose.
  <br/>I am executing the request against <code>https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases</code>.</p>
  
  <p>As I said - it works fine, but when I translate it into curl I get the error "Problems parsing JSON".</p>
  
  <p>The translated curl command is:</p>
  
  <pre><code>curl --location --request POST 'https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases' \
  --header 'Authorization: Basic &lt;someHashOrSomething&gt;' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "tag_name": "4.2.0",
      "target_commitish": "master",
      "name": "4.2.0",
      "body": "test"
  }'
  </code></pre>
  
  <p>which I reformat into <code>curl --location --request POST 'https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases' --header 'Authorization: Basic &lt;someHashOrSomething&gt;' --header 'Content-Type: application/json' --data-raw '{   "tag_name": "4.2.0",    "target_commitish": "master",   "name": "4.2.0",    "body": "test"}'</code> to be on one line.</p>
  
  <p>I also tried (since only the "tag_name" parameter is required):
  <br/><code>curl -i -H 'Authorization: token &lt;myToken&gt;' -d '{"tag_name":"4.2.0"}' https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases</code>
  <br/><code>curl -i -H 'Authorization: token &lt;myToken&gt;' -d '{"tag_name":"4.2.0"}' https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases --header Content-Type:application/json</code>
  <br/><code>curl -d '{"tag_name":"4.2.0"}' -u &lt;myUsername&gt;:&lt;myToken&gt; https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases --header "Content-Type:application/json"</code>
  <br/><code>curl -d "tag_name=4.2.0" -u &lt;myUsername&gt;:&lt;myToken&gt; https://api.github.com/repos/&lt;myUsername&gt;/&lt;myRepo&gt;/releases --header "Content-Type:application/json"</code></p>
  
  <p>Every curl request fails with the "Problems parsing JSON" error.</p>