Error due to - 'Internal Exception' when uploading Sign-generated PDF file to workdrive via Deluge in Zoho CRM

Error due to - 'Internal Exception' when uploading Sign-generated PDF file to workdrive via Deluge in Zoho CRM

Hi

I wasnt getting this error a few days ago and my code had not changed, so I'm wondering if there's a Zoho bug somewhere?

I am downloading a PDF file from a Zoho Sign url using invokeurl and then uploading it to a Workdrive folder using zoho.workdrive.uploadFile. 

I can upload a PDF I get from a public URL to the Workdrive folder using this code, but I get an Internal Exception when I retrieve the file from the Sign url eg. https://sign.zoho.com.au/api/v1/requests/[REQUEST NO]/pdf"

The file is successfully retrieved from the Sign url (I can email it to myself as an attachment).

I've isolated the part of my code that's giving me the error:

// Get the file from the Zoho Sign url
pdfAttachmentTest = invokeurl
[
type :GET
connection:"workdrive_oath_connection"
response-format:FILE

];
// Confirm I have retrieved the file by emailing it to myself.
sendmail
[
from :zoho.adminuserid
to :"EMAILHERE"
subject :"pdfAttachmentTest"
message :pdfAttachmentTest
Attachments :file:pdfAttachmentTest
]
// Try to save the PDF to a folder
response = zoho.workdrive.uploadFile(pdfAttachmentTest,"folderid","test.pdf",true,"workdrive_oath_connection");

Thanks.

Marcus