I have an instance of AsyncHttpClient and i want to print the complete request that goes to the Server.
private static AsyncHttpClient client = new AsyncHttpClient();
public static void post(String url, RequestParams params, AsyncHttpResponseHandler responseHandler) {
String urlToSend = getAbsoluteUrl(url);
client.addHeader("Authorization","Basic "+ Base64.encodeToString((BuildConfig.BASIC_AUTH_USER+":"+BuildConfig.BASIC_AUTH_PWD).getBytes(),Base64.NO_WRAP));
client.setLoggingLevel(Log.ERROR);
client.setTimeout(DEFAULT_TIMEOUT);
client.post(urlToSend, params, responseHandler);
}
I am able to get response and is able to see header and other stuff while debugging. But i want to print complete request made to the server in logger i.e url appended with header and body.