Add a document

You can add up to 20 documents to your transaction. We accept PDF, Word and images as input format in a maximum size limit of 25MB for each document. The output document (the document that is signed) is always a PDF.

Adding a document to a transaction is a two-step process.

Upload your file to Universign servers

Before you can add the document to your transaction, you must upload your it on our servers. To do so, send a multipart/form-data request to POST /v1/files and pass the document (in PDF, Word or image format) in the file argument:

curl
https://api.universign.com/v1/files \
-F file=@DocumentTest.pdf

You must send one document per request.

A file ID is returned:

{
  "object" : "file",
  "id" : "file_d0bDo8LgEkEA",
}

Note that we keep the file for 24 hours so you can reuse the file ID during this period.

Add the file ID to your transaction request

To add the file ID to your transaction, send a request to POST /v1/transactions/{transaction_id}/documents and pass the file ID as the document argument.

curl
https://api.universign.com/v1/transactions/tx_aA5g6yzYVYW8/documents \
-d document=file_0Y6rOeYJ6qOBxCZ012yY1LrBeg \
-d name=DocName

Note: You must send one request per document.

Import a document from a URL (Full transaction request only)

If you send a full transaction request, you can import a document directly from a URL. This feature allows you to bypass document uploads constraints.

Note that this feature needs to be activated on your workspace. If you wish to activate it, you must contact your account manager at Universign.

You need first to authorize the URL in your workspace. For more details, visit Document URLs.

Then, in your full transaction request, pass the URL in the URL argument. Note that the URL argument must not be passed if the document content or file_id is set.

Important: Make sure the URL leads to the document itself and not to its location.

"documents" : [{
    "url" : "https://getsamplefiles.com/download/pdf/sample-1.pdf",
    "name" : "MyDoc", 
    "fields" : [
        {
      "id" : "field_id_1",
      "name" : "signature field",
      "page" : 1,
      "x" : 150,
      "y" : 275,
      "type" : "signature",
      "consents" : [ "I hereby accept the terms and conditions stated in this document!" ],
      "optional_consents" : [ "I accept to fill a satisfaction form once the signature process is completed!" ] 
    },{
      "id" : "field_id_2",
      "name" : "signature field 2",
      "page" : 1,
      "x" : 175,
      "y" : 200,
      "type" : "signature"
    }]
  }],

Set sender name display
Delete a document
Developer tools
Guides
Services
API reference