Questions tagged [android-ion]

Asynchronous networking and image loading library for Android. Use with the [android] tag

179 questions
0
votes
1 answer

Request returned result is null after Cloudflare installation on domain

i am developing an android application which is using a Laravel RESTful API, the problem is with Cloudflare. when ever the cloudflare being installed on server, i can't connect to the API and any sent request returns NULL Note: i'm using ion khushi…
mahan
  • 53
  • 1
  • 6
0
votes
1 answer

How send key value in addMultipartParts Ion Koush library?

I'm using the Ion Koush Library in my android project, it is working fine but I don't know how to specify the key request when I use the addMultipartParts function. My code: Ion.with(this) .load("POST", UPLOADIMAGESTG_URL) .setTimeout(5000) …
Wavrik
  • 61
  • 9
0
votes
1 answer

Android: How To Access await() method in Ion Library

I am using ion, a library for Android. As shown in ion-kotlin, one can use a method called await() like so: fun getFiles(files: Array) = async { for (file in files) { Ion.with(context) .load(file) .asString() …
Foobar
  • 7,458
  • 16
  • 81
  • 161
0
votes
1 answer

Kotlin - Avoid nested callbacks when fetching multiple JSON files with ION

I have some code that 1] fetches a JSON file and 2] depending on the content of that JSON file, fetches another JSON file. It uses the ion library. The code roughly looks like this (Sidenote - this code is on the onCreate method of my activity and e…
Foobar
  • 7,458
  • 16
  • 81
  • 161
0
votes
1 answer

Old json data is fetched even after json file is modified

I am using Ion (Android Asynchronous Networking and Image Loading) to fetch json data stored in gist.github.com. Whenever I add new data to the JSON file in github and restart the android app, the new data is not loaded but when I clear the cache of…
0
votes
1 answer

Android file uploading using Ion, but upload file was empty

My uploading with Ion returned success. But uploaded file was empty. As packet dump from wireshark, Ion didn't send file contents. What did I mistake? Here are my codes. MyFragment.java Ion.with(getContext()) .load(uploadUrl) …
sungyong
  • 2,267
  • 8
  • 38
  • 66
0
votes
1 answer

Ion Android sending multipart/form-data

I'm trying to upload an image to my server by the code below. button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { Ion.with(getContext()) …
Tom
  • 173
  • 2
  • 13
0
votes
0 answers

Ion.with(context) get E/AndroidRuntime when call

i cant run this ion.eith(context) in this project but it s run in another project please help me icant solv this problem MainActivity.java package com.example.a123.scanner; import android.app.ProgressDialog; import android.content.Context; import…
0
votes
0 answers

How to handle different error exception in network service hit using networking KOUSH ION

I am using koush ion for service hit in my project as written below Ion.asString().setCallback(new FutureCallback() { @Override public void onCompleted(Exception error, String result){} } During API hit there can be success as well…
Harshit
  • 41
  • 1
  • 6
0
votes
1 answer

Send double value as body parameter to url using ion library?

I am trying to send a double value via Ion Library call. I can't seem to send a double value and this messes up my code. I am trying to convert INR to USD and vice versa via an api call. My double value is 'amount'. Ion.with(context) …
Varun Joshi
  • 97
  • 1
  • 6
0
votes
2 answers

Uploading a File (Multipart/Form data) to Server Failed in Android using ion library

I am new in android ,and am trying to upload a file to server using ion library ion library but the file crashes. with this error. FATAL EXCEPTION: Thread-55725 …
jhild stack
  • 11
  • 1
  • 6
0
votes
0 answers

Java android REST Api login

I have a endpoint which look like this in SOAPI : And I try to login there in android: I did this : Ion.with(getApplicationContext()) .load("https://mobile.***.net.pl:447/***MobileProxy/proxy/sessions") .setBodyParameter("company",…
user7652543
0
votes
1 answer

Throw exception if response code isn't 20x

I'm using Koush Ion library, and I want to know if there is an option to throw an exception if the response code is not 20x (like if it's 400, 401 etc).
Shalev Moyal
  • 644
  • 5
  • 12
0
votes
1 answer

Where to insert API key into POST request in Android studio

Just want to know where do I insert the API key for the server in my code below: public class GetCurrentJob extends Job { Context context; GetFeedback feedback; protected GetCurrentJob(Context context, GetFeedback fb) { super(new…
Positive-One
  • 89
  • 1
  • 12
0
votes
2 answers

Ion Koush Library - Response is not cacheable

I'm trying to get some jsons from my backend API using Ion Koush Library. I could do it with sucess in one of the API routes, but at the other I'm having the following answer : Response is not cacheable. For a better understanding of the problem…