title: Post request over JSON RPC in Angular 4
body: <p>Trying to receive JSON RPC data from the server using Angular 4 HttpClient.
  The received error is
  <code>{code: -32600, message: "INVALID_JSON_REQUEST: The JSON sent is not a valid JSON-RPC Request object"}</code>.</p>
  
  <p>The command is:</p>
  
  <pre><code>curl -i -X POST -d '{"jsonrpc": "2.0", "id": "1", "method": "command", "params": {"name":"get names","parameters": {"datasets": null},"destination":"http://172.16.106210:9100","source":"TESTER"}}' http://172.16.106.210:9100
  </code></pre>
  
  <p>Implementation on Angular application:</p>
  
  <pre><code>getDataset(dataset?: string): Observable&lt;any[]&gt;
    {
      const url = 'http://172.16.106.210:9100';
      let headers = new Headers();
      headers.append('Content-Type', 'application/json');
  
      let params = new URLSearchParams();
      params.append("jsonrpc", "2.0");
      params.append("id", "3");
      params.append("method", "command");
      params.append("params", '{"name":"get names","parameters": {"datasets": null},"destination":"http://172.16.106.210:9100", "source":"TESTER"}');
  
      const options = new RequestOptions({ headers: headers, params: params });
  
      return this.httpClient.post(url, options)
        .map((response: any[]) =&gt; response)
        .do(response =&gt; console.log(response))
        .catch(error =&gt; Observable.throw(error));
    }
  </code></pre>
  
  <p>What is wrong in this JSON request?</p>
  
  <p>Thank you in advance,</p>