Android studio, How to send data over http?
<p>Developing my first basic android app, Below is how i am opening a connection and it works good.</p>

<pre><code>URL url = new URL("http://www.mocky.io/v2/568e3d730f0000da3fd1831b");
HttpURLConnection con = (HttpURLConnection) url.openConnection();
</code></pre>

<p>Now, how to send data or json object on this connection? This just opens a connection, where comes the authentication? does the authentication code be before opening the connection or how does it work?</p>

<p>Thanks.</p>

<p>Regards,</p>