How to add multiple images/files on a same parameter along with other textual data using retrofit?
Single image is uploading perfectly using following interf
You can use the @MultiPart Post with @PartMap as parameter
Map files = new HashMap();
files.put("my file number one", new TypedFile("image/jpg", new File(filename)));
files.put("my file number two", new TypedFile("image/jpg", new File(filename)));
apiInterface.updateProfileWithImage("first name here", files);
private interface ApiInterface{
@Multipart
@POST("/users/updateProfile/")
Response updateProfileWithImage(
@Part("user_id") TypedString first_name,
@PartMap Map Files
);
}