Basic authentication to access assembla rest apis from android
<p>I want to use assembla apis from android environment for my project.
I am trying to do basic authentication as follow :</p>

<pre><code>String authentication = "username:password";
String encoding = Base64.encodeToString(authentication.getBytes(), 0);    

     URL url = new URL("https://www.assembla.com/");

        conn = (HttpURLConnection) url.openConnection();

        conn.setRequestMethod("GET");

        conn.setRequestProperty("Authorization", "Basic " + encoding);
        conn.setDoOutput(true);

        conn.connect();
        System.out.println(conn.getResponseCode());

        System.out.println(conn.getResponseMessage());
</code></pre>

<p>I am getting 400 and Bad Request in output.
is there something wrong with URL that i am using or some other thing is going wrong?</p>
