You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need to publish the completed to s3, in the callback response, I see the value of the document in req.body.envelopeDocuments[0].PDFBytes
Can someone help me with how to convert this to file? Tried using fs.writeFileSync('random.pdf',req.body.envelopeDocuments[0].PDFBytes) and fs.writeFileSync('random.pdf',Buffer.from(req.body.envelopeDocuments[0].PDFBytes)) and fs.writeFileSync('random.pdf',Buffer.from(req.body.envelopeDocuments[0].PDFBytes, 'base64'))
all of this seems to generate empty PDF only. how to get the actual completed document?
The text was updated successfully, but these errors were encountered:
That example shows you how to download the document. Remember that it is a binary file.
If you have trouble uploading it to S3, I suggest asking on StackOverflow.
Answer to original question is still needed. I do not need to implement downloading the file another way. I have the file contents, pushed via web hook. I tried decoding it as base64 and writing that as binary, but the file is not openable, says "damaged."
How does one take the string contents of the PDFBytes and convert and write to a file which can then be opened as PDF file?
We need to publish the completed to s3, in the callback response, I see the value of the document in
req.body.envelopeDocuments[0].PDFBytes
Can someone help me with how to convert this to file? Tried using
fs.writeFileSync('random.pdf',req.body.envelopeDocuments[0].PDFBytes)
andfs.writeFileSync('random.pdf',Buffer.from(req.body.envelopeDocuments[0].PDFBytes))
andfs.writeFileSync('random.pdf',Buffer.from(req.body.envelopeDocuments[0].PDFBytes, 'base64'))
all of this seems to generate empty PDF only. how to get the actual completed document?
The text was updated successfully, but these errors were encountered: