▲ Top

Authentication Tokens

The system supports four kinds of authentication tokens:

This guide’s REST API chapter provides an overview of certain basic API calls. If you want to view all existing calls, see the REST API Object Model. Additional information about the calls can be found on the Developer Community website. That site’s Feature Guides may be especially helpful when you’re building your solution.

Tokens for Users

POST /authenticationTokens/user

Description

Creates a token that can be used to obtain a valid session for a particular user of the system. This token is single-use, and expires after 30 minutes.

Resource Information

HTTP Method POST
Resource Family userAuthenticationTokens
Content-type application/json
Accept application/json

Authentication

Either a Cookie header or an Authorization header is required.

Cookie ESIGNLIVE_SESSION_ID=108259418ff689fc
Authorization Basic WVdECUMScUZGGGBGOlhVODdGNXFkR253SA==

Example Request

POST https://sandbox.esignlive.com/api/authenticationTokens/user
Cookie: ESIGNLIVE_SESSION_ID=cdf5b882667d24a2

Response Payload

{
   "value": "MjY0MjQ4MzgtMTJlOS00MzhjLTgzODMtMzJmMGNiZTg3ODBl"
}

Tokens for Senders

POST /authenticationTokens/sender

Description

Creates a token that can be used to obtain a valid session for the owner of an existing package, so they can edit the package using the Designer view, and then distribute it for signing. This token is restricted to a single package. It is single-use, and expires after 30 minutes.

Resource Information

HTTP Method POST
Resource Family senderAuthenticationTokens
Content-type application/json
Accept application/json

Authentication

Either a Cookie header or an Authorization header is required. The person who creates the token can be either the package owner, or an account manager (who can create packages on behalf of other users of the account).

Cookie ESIGNLIVE_SESSION_ID=108259418ff689fc
Authorization Basic WVdECUMScUZGGGBGOlhVODdGNXFkR253SA==

Required Payload Content

packageId ID of the package

Example Request

POST https://sandbox.esignlive.com/api/authenticationTokens/sender
Cookie: ESIGNLIVE_SESSION_ID=cdf5b882667d24a2

Request Payload

{
  "packageId": "e937fc75-3c3b-4506-b270-cc7e43f4cf78"
}

Response Payload

{
   "value": "MjY0MjQ4MzgtMTJlOS00MzhjLTgzODMtMzJmMGNiZTg3ODBl"
}

Single-Use Tokens for Signers

POST /authenticationTokens/signer/singleUse

Description

Creates a token that can be used to obtain a valid session for a particular signer of an existing package, so they can sign the package. This token is restricted to a single package. It is single-use, and expires after 30 minutes.

Resource Information

HTTP Method POST
Resource Family signerAuthenticationTokens
Content-type application/json
Accept application/json

Authentication

Either a Cookie header or an Authorization header is required.

Cookie ESIGNLIVE_SESSION_ID=108259418ff689fc
Authorization Basic WVdECUMScUZGGGBGOlhVODdGNXFkR253SA==

Required Payload Content

signerId ID of the signer
packageId ID of the package

Example Request

POST https://sandbox.esignlive.com/api/authenticationTokens/signer/singleUse
Cookie: ESIGNLIVE_SESSION_ID=cdf5b882667d24a2

Request Payload

{
   "packageId":"s-wy6PFASBlAKfnLJjcbzoaMyTg=",
   "signerId":"cd9lbzvjgblygdncdz3x@onespan.com",
   "sessionFields":{  
      "Bulk Signing on behalf of":"cd9lbzvjgblygdncdz3x@onespan.com",
      "signer =session field &key 2":"signer session field value 2",
      "signer session field key 3":"signer session field value 3"
   },
   "value":""
}

Response Payload

{
   "packageId":"s-wy6PFASBlAKfnLJjcbzoaMyTg=",
   "sessionFields":{  
      "Bulk Signing on behalf of":"cd9lbzvjgblygdncdz3x@onespan.com",
      "signer =session field &key 2":"signer session field value 2",
      "signer session field key 3":"signer session field value 3"
   },
   "signerId":"cd9lbzvjgblygdncdz3x@onespan.com",
   "value":"ZDNmMDNiNGUtNGYxOC00YWZiLTkwMmUtNWE5YmIwZTRjZDg1"
}

Multiple-Use Tokens for Signers

POST /authenticationTokens/signer/multiUse

Description

Creates a token that can be used to obtain a valid session for a particular signer of an existing package, so they can sign the package. This token is restricted to a single package, and expires after 30 minutes. However, it can be used multiple times.

Resource Information

HTTP Method POST
Resource Family signerAuthenticationTokens
Content-type application/json
Accept application/json

Authentication

Either a Cookie header or an Authorization header is required.

Cookie ESIGNLIVE_SESSION_ID=108259418ff689fc
Authorization Basic WVdECUMScUZGGGBGOlhVODdGNXFkR253SA==

Required Payload Content

signerId ID of the signer
packageId ID of the package

Example Request

POST https://sandbox.esignlive.com/api/authenticationTokens/signer/multiUse
Cookie: ESIGNLIVE_SESSION_ID=cdf5b882667d24a2

Request Payload

{
   "packageId":"s-wy6PFASBlAKfnLJjcbzoaMyTg=",
   "signerId":"cd9lbzvjgblygdncdz3x@onespan.com",
   "sessionFields":{  
      "Bulk Signing on behalf of":"cd9lbzvjgblygdncdz3x@onespan.com",
      "signer =session field &key 2":"signer session field value 2",
      "signer session field key 3":"signer session field value 3"
   },
   "value":""
}

Response Payload

{
   "packageId":"s-wy6PFASBlAKfnLJjcbzoaMyTg=",
   "sessionFields":{  
      "Bulk Signing on behalf of":"cd9lbzvjgblygdncdz3x@onespan.com",
      "signer =session field &key 2":"signer session field value 2",
      "signer session field key 3":"signer session field value 3"
   },
   "signerId":"cd9lbzvjgblygdncdz3x@onespan.com",
   "value":"ZDNmMDNiNGUtNGYxOC00YWZiLTkwMmUtNWE5YmIwZTRjZDg1"
}