Content Transfer Encoding for /api/packages
Tuesday, October 17, 2017 at 10:13amI'm having trouble sending a PDF with text tags to the /api/packages endpoint. My PDF is sent as base-64 encoded, and that string is "pasted" into a document when it reaches my eSignLive account. I'd like for the string to be decoded, so that the new package contains a copy of my original PDF. Here's what the request looks like:
Request:
POST : https://sandbox.esignlive.com/api/packages
Accept: application/json
Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW
Authorization: Basic *obscured*
------WebKitFormBoundary7MA4YWxkTrZu0gW Content-Disposition: form-data; name="file"; filename="sample-contract.pdf" Content-Type: application/pdf JVBERi0xLjMKJcTl8uXrp/Og0MTGCjQgMCBvYmoKPDwgL0xlbmd0aCA1IDAgUiAvRmlsdGVyIC9GbGF0ZURlY29kZSA+PgpzdHJlYW0KeAGFkU1LAzEQhu/5FW+31ibqZiff6VXx4q0Q8OB6WupBqFD3/4PT3UrJYSkJJAPJPPPMnL
... etc.
------WebKitFormBoundary7MA4YWxkTrZu0gW Content-Disposition: form-data; name="payload" { "documents": [ { "id": "sample-contract", "name": "Test Document", "extract": true, "data": { "esl_doc_extract_type": 1 } } ], "status": "DRAFT", "type": "PACKAGE", "roles": [ { "id": "signer1", "type": "SIGNER", "signers": [ { "email": "[email protected]", "firstName": "Cam", "lastName": "Pierce", "id": "signer1" } ], "name": "signer1" } ], "name": "Text Tags Example Package" } ------WebKitFormBoundary7MA4YWxkTrZu0gW--
And the string within the name="file" boundary is what gets pasted into my new document.
Is the API expecting my PDF to arrive in a different format/encoding? How can I construct my call so that my new package contains the PDF as it looks before it's sent over?
Reply to: Content Transfer Encoding for /api/packages
Tuesday, October 17, 2017 at 10:21am