I am trying to send two pdfs within an envelope to docusign. The pdfs were generated using iText library. This problem occurs only while using pdf generated by iText. Other (downloaded from web) pdfs are working fine in my application with docusign so there's no issue in the java code. Also there's no problem in sending a single (iText generated) pdf within the envelope. Problem occurs only when sending multiple (iText generated) pdf documents. While using docusign REST api to send this pdf I am receiving a http 400 Bad Request error. Could anyone point out the problem in my pdf.
Here are the links to the pdf which I am trying to send.
http://www.pdfhost.net/index.php?Action=Download&File=c8eeab729a8299e08e643d99afa00672 http://www.pdfhost.net/index.php?Action=Download&File=c8e0d2b8dfa9c2b82d10cc0503995310
Thanks in advance.
----- EDIT -----
I tried these two documents after using 'Save As a new PDF' option in Adobe Reader and saving the documents. After this the two pdfs successfully got uploaded to docusign. Can somebody help me with the changes that Adobe Reader made to my documents that made it work with docusign. Also the size of the pdfs increased and fast web view property got set to YES after using 'Save as new pdf' option.
----- EDIT -----
Here's is my request content to docusign. This time using a simple text pdf generated by iText. This request is also throwing a 400 Bad request error.
--BOUNDARY
Content-Type: application/json
Content-Disposition: form-data
{"status":"sent","emailBlurb":"email body","emailSubject":"email subject","documents":[{"documentId":"501","name":"cc5fda55_pdf","order":"1"},{"documentId":"502","name":"cc5fda56_pdf","order":"2"}],"recipients":{"signers":[{"recipientId":"74d5772d-6a5b-4fb0-b95d-947d8ecafd3c","returnUrl":null,"name":"Lucy Lu","email":"lucy.lu@gmail.com","clientUserId":"74d5772d-6a5b-4fb0-b95d-947d8ecafd3c","routingOrder":"1","tabs":{"signHereTabs":[{"documentId":"501","pageNumber":"1","anchorString":"ee_signature","anchorXOffset":"0","anchorYOffset":"0","anchorIgnoreIfNotPresent":"true","anchorUnits":"inches"},{"documentId":"502","pageNumber":"1","anchorString":"ee_signature","anchorXOffset":"0","anchorYOffset":"0","anchorIgnoreIfNotPresent":"true","anchorUnits":"inches"}]}}]}}
--BOUNDARY
Content-Type: application/pdf
Content-Disposition: file; filename="cc5fda55_pdf"; documentId=501
%PDF-1.4
%âãÏÓ
2 0 obj
<</Length 77/Filter/FlateDecode>>stream
<BYTE CONTENT HERE>
endstream
endobj
4 0 obj
<</Parent 3 0 R/Contents 2 0 R/Type/Page/Resources<</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]/Font<</F1 1 0 R>>>>/MediaBox[0 0 595 842]>>
endobj
1 0 obj
<</BaseFont/Helvetica/Type/Font/Encoding/WinAnsiEncoding/Subtype/Type1>>
endobj
3 0 obj
<</ITXT(5.0.6)/Type/Pages/Count 1/Kids[4 0 R]>>
endobj
5 0 obj
<</Type/Catalog/Pages 3 0 R>>
endobj
6 0 obj
<</Producer(iText 5.0.6 \(c\) 1T3XT BVBA)/ModDate(D:20140303192905+05'30')/CreationDate(D:20140303192905+05'30')>>
endobj
xref
0 7
0000000000 65535 f
0000000315 00000 n
0000000015 00000 n
0000000403 00000 n
0000000158 00000 n
0000000466 00000 n
0000000511 00000 n
trailer
<</Root 5 0 R/ID [<e5359ec2954ce59003907592ee9885c4><af4ec60043c4444d2e7f07c3286e29da>]/Info 6 0 R/Size 7>>
startxref
641
%%EOF
--BOUNDARY
Content-Type: application/pdf
Content-Disposition: file; filename="cc5fda56_pdf"; documentId=502
%PDF-1.4
%âãÏÓ
2 0 obj
<</Length 77/Filter/FlateDecode>>stream
<BYTE CONTENT HERE>
endstream
endobj
4 0 obj
<</Parent 3 0 R/Contents 2 0 R/Type/Page/Resources<</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]/Font<</F1 1 0 R>>>>/MediaBox[0 0 595 842]>>
endobj
1 0 obj
<</BaseFont/Helvetica/Type/Font/Encoding/WinAnsiEncoding/Subtype/Type1>>
endobj
3 0 obj
<</ITXT(5.0.6)/Type/Pages/Count 1/Kids[4 0 R]>>
endobj
5 0 obj
<</Type/Catalog/Pages 3 0 R>>
endobj
6 0 obj
<</Producer(iText 5.0.6 \(c\) 1T3XT BVBA)/ModDate(D:20140303192905+05'30')/CreationDate(D:20140303192905+05'30')>>
endobj
xref
0 7
0000000000 65535 f
0000000315 00000 n
0000000015 00000 n
0000000403 00000 n
0000000158 00000 n
0000000466 00000 n
0000000511 00000 n
trailer
<</Root 5 0 R/ID [<e5359ec2954ce59003907592ee9885c4><af4ec60043c4444d2e7f07c3286e29da>]/Info 6 0 R/Size 7>>
startxref
641
%%EOF
--BOUNDARY--