Post

1 follower Follow
0
Avatar

Downloading Files using Java Client

I am having difficulties with downloading files attached to an Item using Java. The API provides a method called downloadFile(int fileID, java.io.File targetFile). However, instead of receiving the content of the requested file, Podio returns the html-code of the Login-Page, but just two lines above in my code I'm accessing the Fields of the item and everything works perfectly. So I can't find the error why Podio doesn't recognize my login information anymore.

Has anybody faced the same problem before? It seems that I have to resend my OAuth Authentication everytime I'm trying to access a File, but I can't figure out how to.

 

Looking forward to hearing from you.

Bests,

Christopher

 

PS: I'm using this line of code: getBaseAPI().getAPI(FileAPI.class).downloadFile(fileAktuell.getId(), file, null);

Christopher Kränzler

Please sign in to leave a comment.