r_bakker_sping_nl

Signing sender documents by API

0 votes
Hi, We have been trying to sign all documents using the canadian REST API (e-signlive.ca/api) We tried creating a package with the code provided on https://developer.esignlive.com/guides/feature-guides/sign-documents/ . We added a role ('Sender') and approval for this role.
{
  "name":"Contract B J R",
  "description":"",
  "roles":[
     {
        "id":"SignerContract",
        "type":"SIGNER",
        "signers":[
           {
              "firstName":"B J",
              "lastName":"R",
              "email":"[email protected]",
              "delivery":{
                 "email":false
              },
              "auth":{
                 "scheme":"NONE"
              }
           }
        ]
     },
     {
        "id":"Sender",
        "type":"SIGNER",
        "signers":[
           {
              "firstName":"sender.firstname",
              "lastName":"sender.lastname",
              "email":"[email protected]"
           },
           {
              "auth":{
                 "scheme":"NONE"
              }
           }
        ],
        "name":"Sender"
     }
  ],
  "documents":[
     {
        "name":"Contract",
        "id":"Contract",
        "approvals":[
           {
              "role":"SignerContract",
              "fields":[

              ]
           },
           {
              "role":"Sender",
              "fields":[

              ]
           }
        ]
     }
  ],
  "settings":{
     "ceremony":{
        "inPerson":false
     }
  },
  "visibility":"ACCOUNT",
  "type":"PACKAGE",
  "due":null,
  "autocomplete":true,
  "emailMessage":"",
  "status":"DRAFT",
  "language":"nl"
}
Sending a POST to /api/packages/{packageId}/documents/signed_documents (using API key)
{
  "documents":[
     {
        "id":"Contract",
        "name":"Contract"
     }
  ]
}
Results in 200 OK response without content, but it doesn't seem to sign anything (for any recipients). What should we be doing?

Reply to: Signing sender documents by API

0 votes
Hi there, "Sign Documents" API only programmatically signed signatures for Sender of the package. In order to sign documents for a Signer (signer with id of "sender" in your case), you'd follow this guide "Bulk Sign For a Signer" in three steps: #1. generate an authentication token for signer #2. generate a session token out of this authentication token #3. call the same API as you did, but put session token in cookie header as credential in stead of api key. Hope this could help! Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Signing sender documents by API

0 votes
Hi Duo Liang, Thanks for the guidance - we managed to get is working. regards, Robert

Hello! Looks like you're enjoying the discussion, but haven't signed up for an account.

When you create an account, we remember exactly what you've read, so you always come right back where you left off