How can I upload pdf files in Egnyte using Rest API and Java Priyadarsini on October 31, 2019 Having the PDF files in local drive(D:). Need to upload those PDF files in Egnyte with the help of Rest API and Java
This is a very specific question. Could I ask why you need to do this? What progress toward a solution do you have so far?
public static void main(String[] args) {
File testupload=new File("C:\Users\MSTSYS0\renamedfile\a.png");
RestAssured.baseURI="apidemo.egnyte.com/pubapi/v1/fs/Sh...";
Response response=given()
.multiPart(testupload)
.when().
post("/Uploads");
System.out.println(response.getStatusCode());
System.out.println(response.asString());
}
Did you get this to work? if yes, can you please share some sample code?