2

I have created an Import.io API to replace the kimonoLabs API I had in my application, however as I try to connect, it never manages to, it keeps giving

com.android.volley.RedirectError any ideas??

 VolleySingleton.getInstance(getActivity()).addToRequestQueue(stringRequest);
    stringRequest = new StringRequest(Request.Method.GET, url,
            new Response.Listener<String>() {


                @Override
                public void onResponse(String response) {
                    database.insertMinutesPlayed(response);
                    if (getActivity() != null && isAdded()) {
                        initiate();
                        swipeRefreshLayout.setRefreshing(false);
                    }

                }
       new Response.ErrorListener() {

        @Override
        public void onErrorResponse(VolleyError error) {
            if (getActivity() != null && isAdded()) {
                initiate();
                swipeRefreshLayout.setRefreshing(false);
            }

        }
    });
    VolleySingleton.getInstance(getActivity()).addToRequestQueue(stringRequest);
RedEagle
  • 2,358
  • 3
  • 13
  • 18
  • 1
    perhaps this thread can help http://stackoverflow.com/questions/17481964/android-volley-to-handle-redirect – Bhargav Mar 02 '16 at 14:50
  • 1
    I think with volley you need to manually had redirects, the http status codes for that is 300, 301 – Bhargav Mar 02 '16 at 14:52

0 Answers0