0

I am trying to upload a file to dropbox programmatically. Basically file can be uploaded through dropbox api. But the question is how could I upload it by java rest based web service. The program to get the file is:

@Path("/file")
public class UploadFile {

    @POST
    @Path("/upload")
    @Consumes(MediaType.MULTIPART_FORM_DATA)
    public Response uploadFile(
            @FormDataParam("file") InputStream uploadedInputStream,
            @FormDataParam("file") FormDataContentDisposition fileDetail) {

        Stringfilename = fileDetail.getFileName();
        .
        .
        .
    }
}

its good to have any links which describe about this topic.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Ravi Kumar
  • 339
  • 2
  • 11
  • 24

0 Answers0