I'm trying to download completed document(s) from a Docusign Envelope sing the below code:
byte[] fileData = envelopesApi.getDocument(accountId, envelopeId, documentId);
However, I think the problem lies with how I'm sending the documents in compositeTemplates that make up the envelope. I'm assigning both documents an ID that corresponds to a custom POJO object's ID in my application. The above envelopesApi.getDocument(accountId, envelopeId, documentId)
code worked great until I implemented the compositeTemplate design describe here.
Do I need to use a different ID for each document?
Should I be using a different API call to get back these documents? There will likely be more than two compositeTemplates in the future. So I'll need a way to download all documents in a given envelope.
Thanks for your help.