// Path: app/src/main/java/com/designwall/moosell/config/Constant.java
// public static final String BASIC_AUTH = "Basic " + Base64.encodeToString((CONSUMER_KEY + ":" + CONSUMER_SECRET).getBytes(), Base64.NO_WRAP);


import android.os.AsyncTask;
import android.util.Log;
import java.io.IOException;
import java.util.concurrent.TimeUnit;
import okhttp3.MediaType;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.RequestBody;
import okhttp3.Response;
import static com.designwall.moosell.config.Constant.BASIC_AUTH;

    private OkHttpClient mClient;
    private String mMethod;
    private String mRequestBody;

    public GetDataTask(String method) {
        mMethod = method;
    }

    public GetDataTask(String method, String requestBody) {
        mMethod = method;
        mRequestBody = requestBody;
    }

    @Override
    protected void onPreExecute() {
        super.onPreExecute();
        mClient = new OkHttpClient.Builder()
                .connectTimeout(40, TimeUnit.SECONDS)
                .writeTimeout(40, TimeUnit.SECONDS)
                .writeTimeout(40, TimeUnit.SECONDS)
                .readTimeout(30, TimeUnit.SECONDS)
                .build();
    }

    @Override
    protected String[] doInBackground(String... urls) {
        String[] result = new String[urls.length];
        for (int i = 0; i < urls.length; i++) {
            Request request;
            //TODO: Remove this log

// Path: app/src/main/java/com/designwall/moosell/config/Constant.java
// public static final String BASIC_AUTH = "Basic " + Base64.encodeToString((CONSUMER_KEY + ":" + CONSUMER_SECRET).getBytes(), Base64.NO_WRAP);


// Path: app/src/main/java/com/designwall/moosell/task/GetDataTask.java
import android.os.AsyncTask;
import android.util.Log;
import java.io.IOException;
import java.util.concurrent.TimeUnit;
import okhttp3.MediaType;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.RequestBody;
import okhttp3.Response;
import static com.designwall.moosell.config.Constant.BASIC_AUTH;

    private OkHttpClient mClient;
    private String mMethod;
    private String mRequestBody;

    public GetDataTask(String method) {
        mMethod = method;
    }

    public GetDataTask(String method, String requestBody) {
        mMethod = method;
        mRequestBody = requestBody;
    }

    @Override
    protected void onPreExecute() {
        super.onPreExecute();
        mClient = new OkHttpClient.Builder()
                .connectTimeout(40, TimeUnit.SECONDS)
                .writeTimeout(40, TimeUnit.SECONDS)
                .writeTimeout(40, TimeUnit.SECONDS)
                .readTimeout(30, TimeUnit.SECONDS)
                .build();
    }

    @Override
    protected String[] doInBackground(String... urls) {
        String[] result = new String[urls.length];
        for (int i = 0; i < urls.length; i++) {
            Request request;
            //TODO: Remove this log

            Log.v("Test", BASIC_AUTH);
