API versions

v2.4.0 API changes

Release date:2021-01-27

    Added

  • Organization configuration parameters.

  • DST extraData parameters.

  • User templateData parameters.

    Fixed

  • Resources draining fix.

  • Stability fix.

v2.0.0 API changes

Release date:2020-02-07

    Released stable version

Knowledge Base

This section represents the basic knowledge the integrator should have before starting the integration design and development.

Table of content

  1. Glossary

  2. Quick Start - Front end

    1. Login
    2. Create User Account
    3. Create Service Account
    4. Generate Service Token
    5. Create Template from Web
  3. Quick Start - Back end

    1. SDK Configuration
    2. Request Sample
    3. Create DST by Service Token
    4. Create DST from Template by Service Token
    5. Get DSTs Info
  4. Integration Tips

    1. Deactivate Emails for a DST
    2. Redict the signer after the signature

1. Glossary

Term Definition
ClauseForm The ClauseForm represents a portion of the document that has to be read and understood from the siger before actually performing the signature. The ClauseForm is always associated to a SignatureForm.
domain The organization subscripted in Signing Today. It is used in the login process.
form A form is one of the components of a DST. It can be of three types: TextForm, SignatureForm and ClauseForm.
DST DST stands for Digital Signature Transaction. A DST is the object that contains all the information needed in order to perform the signature flow, such as the documents to be signed, the signers and their order of signature, the signature locations, the type of signatures as well as other useful information.
Identity The Identity is the object that contains the X.509 certificate in PEM format used to perform a signature. It is accociated to the user. A user can have multiple identities.
Signature Ticket The Signature Ticket is a pre-authenticated link to the signature tray.
Signature Tray The Signature Tray is the place where the signature is actually performed. From here it is possible to associate one or more identities to your own wallet from a physical device and use it to sign the document. As an alternative you can choose an existing identity from the wallet and perform the signature.
SignatureForm The SignatureForm represents the signature that has to be performed. It is assigned to a user or to an occasional signer.
Template An admin or instructor user is able to create a Template. A Template allows to create a DST more easily and faster because it already contains the documents to be signed and the forms flow. You just need to add the signers.
TextForm The TextForm represents a form that has to be filled or left blank, if not mandatory, then the signatures flow starts.
Wallet The Wallet is the object where the identities of a user are stored.

2. Quick Start - Front end

2.1. Login

Type the following url in a browser of your choice:

You will be redirected to a login form with three fields:

  • Organization
  • Username
  • Password

The Organization field represents the organization (domain - slug) where the the user belongs.

The Username field has to be filled with the username associated to your account.

The Password field is the password associated to the user account.

2.2. Create User Account

In order to create a user account, the logged account needs to be an admin. From the homepage, press the menu icon in the left upper corner; a side menu will open. Press Users in order to be redirected to the users management page. Once there, press the New User button on the top, a window will pop up. The first voice of the form is Account Type which is a select between User and Robot. In order to create a regular user account choose User. Fill the other fields as requested; the last field is Role and it is a select box of three values:

  • Admin
  • Instructor
  • Signer

An Admin account can create new users, can see all the DSTs in the domain, can create DSTs and Templates as well as sign DSTs.

An Instructor account can see the DSTs where he is involved only, can create DSTs and Templates and can sign DSTs.

A Signer account can see the DSTs where he is involved and can sign DSTs only.

Once completed all the mandatory fields you can press Create. A window will pop up containing a success message.

2.3. Create Service Account

In order to create a service account, the logged account needs to be an admin one. From the homepage press the menu icon in the left upper corner, a side menu will open. Press Users in order to be redirected to the users management page. Once there, press the New User button on the top, a window will pop up. The first voice of the form is Account Type which is a select between User and Robot. In order to create a service account choose Robot. Check the Automatic Signer check box in order to allow the robot to perform signatures. Once the Username and Application Name fields are completed click the Create button. A window will pop up containing a success message.

2.4. Generate Service Token

In order to generate a service token, from the homepage press the menu icon in the left upper corner, a side menu will open. Press Users in order to be redirected to the users management page. Click on the username of the service account from whom you want to generate a lifetime token. You will be redirected to the account page. Press the menu button on the top next to Contact Info and then press Manage Token from the menu that has opened.

The next menu will show an Authentication Token, that will be the lifetime token of the service user. A service user is to be intended as an external application which creates templates and/or DSTs.

In case there will be the need to change the token, press the Request a new token button. The old one will be destroyed and a new one will be provided.

From here it is also possible to set up the notification system for the DSTs created by the application. Fill the field Webhooks with the URL where the notifications should be sent. Fill the Headers Key-Value pair if some particular kind of headers are requested to Signing Today in order to send the notifications. It is possible to add one or more headers, as well. If authentication is needed, choose it from the Authentication select box, and compile the following fields as requested.

Note that the authentication methods specified will be also used from Signing Today to download the documents in the case of a DST's creation with document/documents uploaded from an URL.

2.5. Create Template from Web

In order to create a DST Template, the logged user must be an admin or instructor. From the homepage press the menu icon in the left upper corner, a side menu will open. Press Create New Template in order to be redirected to the page of the Template Creation. Once there, you have two options: you can drag and drop the file/files in the box Drag here the file or press!, either you can press on the button and choose the document/documents from your file system. The uploaded documents will appear on the page; you can rename them, as well. Once done, press the Next button on the top left. In this page you have to name the DST compiling the mandatory field Transaction title and, in order to allow the other accounts (e.g. service accounts) to instantiate DSTs from the current Template, you have also to check the box Public Template. Then press on the document for which you want to plan a signature flow, at the bottom of the page.

The signature flow is easy to understand. Basically the signature flow follows the order of the Signer Groups. It is possible to set one or more signers per group. This means that until each member of the first group has performed or explicitly refused the signature (if the signature is not mandatory) none of the second group can perform the signature, and so on. There is no order for the signers of the same group. Each document has its own signature flow, this means you have to set up the flow for each document of the DST.

If, for example, you just need one signature, press the button Add Role, and a window will pop up; set the name of that role, or choose it from the previously used ones, and press Add. You will see a Signer Group with the created role inside, under the document. Once done, press again the Next button on the top left.

On the left side of the page you will see the role you defined in the previous step; press on the plus icon and choose Add Signature from the menu. A signature box will appear on the document. Drag it and resize it as you prefer, or do it from the right side menu at the bottom, in the Field Properties section. You can modify the Field Details from the right side menu as well. Once this is completed, press the Create button on the top left in order to create the Template.

3. Quick Start - Back end

3.1. SDK Configuration

Once the service token has been generated, in order to use it into a SDK - e.g. a Python SDK- you need to configure the SDK. Signing Today SDKs are provided here.

Imagine the token you got is: b22a5ce4-ef7e-4281-a171-9dc36275f2ba.

In your python script you will need something like the following portion of snippet on the top of the module:

...

 import signing_today_client

 configuration = signing_today_client.Configuration()
 configuration.access_token = "b22a5ce4-ef7e-4281-a171-9dc36275f2ba"

 ...

3.2. Request Sample

Once the service token is available, the Python SDK has been downloaded, the setup procedure provided in the README has been completed and a test.py file sibling to the signing_today_client package has been created, put the following code in the python module just created:

from signing_today_client import ApiClient, Configuration, \
     DigitalSignatureTransactionsApi

 configuration = Configuration()
 configuration.access_token = "b22a5ce4-ef7e-4281-a171-9dc36275f2ba"

 dsts_instance = DigitalSignatureTransactionsApi(
     ApiClient(configuration)
 )

 if __name__ == "__main__":
     api_response = dsts_instance.d_s_ts_get()
     print(api_response)

The request retrieves all the DSTs:

{
     'count': None,
     'values': [{
     'cc_groups': [],
     'cc_users': [],
     'created_at': datetime.datetime(2020, 2, 12, 19, 3, 56, 570000, tzinfo=tzutc()),
     'created_by_user': '0a99b1c9-d9d3-4c5b-8322-3006cd4e99dc',
     'deleted_at': None,
     'documents': [{
         'filled_document_uuid': '5f9d51cd-893d-420b-92a1-90bb16018c7e',
         'forms': [{
             'document_id': 0,
             'extra_data': {'signatureRequestId': '0'},
             'filled': None,
             'height': 10.0,
             'id': 1,
             'instance_id': 7035,
             'invisible': None,
             'page': 1,
             'position_x': 1.786,
             'position_y': 20.217,
             'signer_id': 0,
             'to_fill': False,
             'type': 'SignatureForm',
             'width': 30.0
         }],
         'id': 0,
         'instance_id': 7034,
         'plain_document_uuid': '435ac12e-50ea-4b28-b8c2-4066f18f03f0',
         'signature_requests': [{
             'declinable': True,
             'description': '',
             'extra_data': {
             'st_signatureTicketUrl': 'https://web.sandbox.signingtoday.com/std/306e8b87-015b-4222-931e-2e6e2ab5fb17/signature',
             'st_uuid': '306e8b87-015b-4222-931e-2e6e2ab5fb17'
             },
         'id': 0,
         'instance_id': 7038,
         'reason': 'As buyer',
         'restrictions': None,
         'sign_profile': 'PAdES',
         'signer_id': 0,
         'with_timestamp': False
         }],
         'signed_document_uuid': None,
         'signer_groups': [{
             'instance_id': 7039,
             'label': 'Group 1',
             'signers': [{
                 'email': 'jdo@example.com',
                 'id': 0,
                 'instance_id': 7040,
                 'name': 'John',
                 'phone': '3334455667',
                 'role': 'signer',
                 'surname': 'Doe',
                 'template_label': 'Buyer',
                 'user_uuid': '0a99b1c9-d9d3-4c5b-8322-3006cd4e99dc'
             }]
         }],
         'status': 'filled'
     }],
     'domain': 'demo',
     'error_message': None,
     'expires_at': datetime.datetime(
         2020, 3, 13, 19, 3, 56, 570000, tzinfo=tzutc()),
     'extra_data': {
         'st_status': 'pending',
         'st_uuid': 'af0b91fc-f4b2-4dc4-8684-80b9138a0795',
         'user_action': 'NONE'
     },
     'id': 'f220030c-e8dd-4d77-9e70-ae3f5f67fda3',
     'public_template': False,
     'published_at': datetime.datetime(
         2020, 2, 12, 19, 4, 12, 41000, tzinfo=tzutc()),
     'replaced_by': None,
     'replaces': None,
     'resources': [{'created_at': datetime.datetime(2020, 2, 12, 19, 4, 32, 198000, tzinfo=tzutc()),
         'domain': 'demo',
         'dst_uuid': 'f220030c-e8dd-4d77-9e70-ae3f5f67fda3',
         'extra_data': None,
         'filename': 'sales-contract.pdf',
         'id': '5f9d51cd-893d-420b-92a1-90bb16018c7e',
         'mimetype': 'application/pdf',
         'pages': 2,
         'size': 3689,
         'title': 'Sales Contract',
         'type': 'PDF_Document',
         'url': None
     }],
     'signatures': [],
     'status': 'toSign',
     'tags': [],
     'template': False,
     'title': 'fill',
     'updated_at': datetime.datetime(
         2020, 2, 13, 10, 0, 40, 46000, tzinfo=tzutc()),
     'urgent': False,
     'visible_to': ['0a99b1c9-d9d3-4c5b-8322-3006cd4e99dc']
 }

Follows the same request executed with cURL:

curl -L -X GET \
   'https://web.sandbox.signingtoday.com/api/DSTs' \
   -H 'Authorization: Bearer b22a5ce4-ef7e-4281-a171-9dc36275f2ba'

3.3. Create DST by Service Token

In order the create a DST intended to be signed by a user account using the service token, you have to make a POST request on the following endpoint:

  • https://web.sandbox.signingtoday.com/api/robot/DSTs

including a body that represents the DST you are going to create.

Below the portion of code for a Python SDK:

from signing_today_client import ApiClient, Configuration, \
     DigitalSignatureTransactionsApi

 configuration = Configuration()
 configuration.access_token = "b22a5ce4-ef7e-4281-a171-9dc36275f2ba"

 service_instance = RobotApi(ApiClient(configuration))

 if __name__ == "__main__":
     dst = {
         "title": "Sample DST",
         "documents": [
             {
                 "resource": {
                     "filename": "sample.pdf",
                     "resourceType": "PDF_Document",
                     "title": "Test PDF",
                     "source": {
                         "type": "URL",
                         "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
                     }
                 },
                 "forms": [
                     {
                         "id": 1,
                         "documentId": 0,
                         "type": "SignatureForm",
                         "positionX": "10.00",
                         "positionY": "10.14",
                         "width": "10.1",
                         "height": "5.66",
                         "page": "1",
                         "signerId": 1,
                         "toFill": False,
                         "invisible": False,
                         "extraData": {
                             "signatureRequestId": 1
                         }
                     }
                 ],
                 "signatureRequests": [
                     {
                         "id": 1,
                         "reason": "For approvation",
                         "description": "As sample test",
                         "signerId": 1,
                         "signProfile": "PAdES",
                         "withTimestamp": True,
                         "declinable": False
                     }
                 ],
                 "signerGroups": [
                     {
                         "label": 'Group 1",
                         "signers": [
                             {
                                 "id": 1,
                                 "name": "John",
                                 "surname": "Doe",
                                 "email": "jdo@example.com",
                                 "role": "Approver"
                             }
                         ]
                     }
                 ]
             }
         ],
         "status": "published",
         "template": False,
         "publicTemplate": False,
         "urgent": False
     }

     api_response = service_instance.robot_ds_ts_post(
         create_digital_signature_transaction=dst
     )
     print(api_response)

If you check the homepage of the Signing Today Web Application you will see a new DST that matches your request. A notification has been already sent to the signer and everything is set up in order to perform the signature.

The signer has received a mail with an url that will redirect them to the Signature Tray.

It is important to focus on the signers key in the previous payload, in order to understand how it works.

For a user account, member of your domain, you can provide either their UUID or email. The other information will be provided by Signing Today. If you want to overwrite - only for the current DST scope- thir name, surname or phone, you can provide them.

This snippet:

"signers": [
     {
         "id": 1,
         "email": "jdo@example.com",
         "role": "Signer"
     }
 ]

is equivalent to the following:

"signers": [
     {
         "id": 1,
         "role": "Signer",
         "userUUID": "5938c7c8-4085-46eb-b824-7ef4f1e151af"
     }
 ]

where the provided userUUID corresponds to the one associated to the user account.

Also there is the chance to ask a signature for someone external to your domain, this could be the case of a one-shot signer. He will receive a mail with the url to the Signature Tray.

"signers": [
     {
         "id": 1,
         "name": "Adam",
         "surname": "Smith",
         "email": "adam.smith@email.com",
         "phone": "+013392213450",
         "role": "Buyer",
     }
 ]

3.4. Create DST from Template by Service Token

In order to instantiate a DST from a Template intended to be signed by a user account using the service token, you have to make a POST request on the following endpoint:

  • https://web.sandbox.signingtoday.com/api/robot/{TEMPLATE-ID}/instantiate

where TEMPLATE-ID represents the UUID of the DST Template you have previously created from the Web App. The body of the request integrates the information of the signer/signers according with the Template.

Let us assume the UUID of the Template is: ccceefa4-8371-47f8-9e82-fe07515c2b49, the portion of code for a Python SDK may be something like the following:

from signing_today_client import ApiClient, Configuration, \
     DigitalSignatureTransactionsApi

 configuration = Configuration()
 configuration.access_token = "b22a5ce4-ef7e-4281-a171-9dc36275f2ba"

 service_instance = RobotApi(ApiClient(configuration))

 if __name__ == "__main__":
     patched_dst = {
         "templatePatches": {
             "status": "published",
         },
         "rolesMapping": [
             {
                 "roleName": "Buyer",
                 "signer": {
                     "name": "John",
                     "surname": "Doe",
                     "email": "jdo@example.com",
                     "role": "Buyer"
                 }
             }
         ]
     }

     api_response = service_instance.robot_dst_id_instantiate_post(
         id="ccceefa4-8371-47f8-9e82-fe07515c2b49",
         instantiate_dst_template=patched_dst
     )
     print(api_response)

where roleName is the signer Role defined previously in the Template creation procedure, because there is a mapping between the roleName (of the body) and the Role (of the Template).

The signer of the roleMapping can be a user account or a one-shot signer, even in that case what said previously about the signer name, username, UUID and so on remains valid.

3.5. Get DSTs Info

In order to retrieve the DSTs information you can use the following Python SDK script:

from signing_today_client import ApiClient, Configuration, \
     DigitalSignatureTransactionsApi

 configuration = Configuration()
 configuration.access_token = "b22a5ce4-ef7e-4281-a171-9dc36275f2ba"

 dsts_instance = DigitalSignatureTransactionsApi(
     ApiClient(configuration)
 )

 if __name__ == "__main__":
     api_response = dsts_instance.d_s_ts_get(
         template=True,
         filter="title==Sample Template"
     )
     print(api_response)

The request retrieves all the DST Templates which title matches the filter Sample Template. You can omit the template keyword (or set it to False in order to avoid that DSTs Templates will be shown in the response) and the filter keyword in order to retrieve all the DSTs.

Below the same request executed with cURL:

curl -L -X GET \
   'https://web.sandbox.signingtoday.com/api/DSTs?template=true&%24filter=title%3D%3DSample%20Template' \
   -H 'Authorization: Bearer b22a5ce4-ef7e-4281-a171-9dc36275f2ba'

4. Integration Tips

4.1. Deactivate Emails for a DST

This is a common feature wanted from whom is integrating Signing Today in a CRM or proprietary system. In order to do so, you have to add the parameter email_disabled, set to true, in the extraData field of the DST you are going to create. The target extraData field is the sibling of the status parameter of the DST. Here is an example:

{
     "title": "Partnership Agreement",
     "documents": [...],
     "status": "published",
     "extraData": {
         "email_disabled": true
     }
 }

4.2. Redict the signer after the signature

This one is another helpful feature for who is integrating Signing Today in a CRM or proprietary system. There are two ways of implementing the redirect, either for the the single signature, or for the DST.

In the first scenario the parameter is documents[n].signatureRequests[n].extraData.sign_urlback, which can be a null value or a URL. Once performed the signature, if the value is null, the user will remain in the Signature Tray, where he can sign other documents, if there are any, where is requested the signature of the current user. The document will be swhitched automatically, hence no actions are requested from the user, if not to sign the next document. For the next signature the same logic as before is applied, about the signature_urlback parameter. In the second scenario, after the signature, the user will be redirected to the specified URL. If no sign_urlback are specified, the default behavior is the redirect to the Signing Today Web Application.

The urlback parameter of the DST is extraData.dst_urlback, where extraData is the sibling of the status of the DST. This urlback parameter is referenced to the behavior of the last signature, which means when the DST is completed. As before, the allows values are null and a URL. Moreover the default behavior is the same as before, which is the redirect to the Signing Today Web Application.

Signing Today Web v2.0.0

Signing Today is the perfect Digital Signature Gateway. Whenever in Your workflow You need to add one or more Digital Signatures to Your document, Signing Today is the right choice. You prepare Your documents, Signing Today takes care of all the rest: send invitations (signature tickets) to signers, collects their signatures, send You back the signed document. Integrating Signing Today in Your existing applications is very easy. Just follow these API specifications and get inspired by the many examples presented hereafter.

The DSTNote model

The DSTNote represents a text note that can be attached to a DST whenever an entitled user needs it (when requesting for clarifications, informing of the proceedings, adding context)

  • attributes
  • idintegerint64

    The id of the note

  • dstIdstringuuid

    The UUID code of the Digital Signature Transaction

  • userIdstringuuid

    The UUID code of the user which created the Note

  • createdAtstringdate-time

    The data-time of the note creation

  • textstringany

    Actual content of the DST Note

Retrieve the DSTNotes associated to the DST

This API allows to retrieve the DST Notes associated to the DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/DST/{id}/note

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

[
  {
    "id": 32,
    "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
    "userId": "123e4567-e89b-12d3-a456-426655440000",
    "createdAt": "2018-12-19 09:26:03.478039",
    "text": "This a DSTNote sample"
  }
]

Append a new DSTNote

This API allows to append a new DSTNote to the DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • textstring

    This is the actual content of the DSTNote

POST

/DST/{id}/note

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "text": "This is the new privacy policy."
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "text": "This is the new privacy policy."
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "text": "This is the new privacy policy."
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "text": "This is the new privacy policy."
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "id": 32,
  "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "userId": "123e4567-e89b-12d3-a456-426655440000",
  "createdAt": "2018-12-19 09:26:03.478039",
  "text": "This a DSTNote sample"
}

Edit a DSTNote

This API allows to edit a DSTNote.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • noteIdpath parameterinteger

    The reference of a DSTNote

  • idinteger

    The id of the note

  • dstIdstring

    The UUID code of the Digital Signature Transaction

  • userIdstring

    The UUID code of the user which created the Note

  • createdAtstring

    The data-time of the note creation

  • textstring

    Actual content of the DST Note

PUT

/DST/{id}/note/{noteId}

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "id": 32,
  "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "userId": "123e4567-e89b-12d3-a456-426655440000",
  "createdAt": "2018-12-19 09:26:03.478039",
  "text": "This a DSTNote sample"
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "id": 32,
  "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "userId": "123e4567-e89b-12d3-a456-426655440000",
  "createdAt": "2018-12-19 09:26:03.478039",
  "text": "This a DSTNote sample"
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "id": 32,
  "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "userId": "123e4567-e89b-12d3-a456-426655440000",
  "createdAt": "2018-12-19 09:26:03.478039",
  "text": "This a DSTNote sample"
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "id": 32,
    "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
    "userId": "123e4567-e89b-12d3-a456-426655440000",
    "createdAt": "2018-12-19 09:26:03.478039",
    "text": "This a DSTNote sample"
}
response = requests.put(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "id": 32,
  "dstId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "userId": "123e4567-e89b-12d3-a456-426655440000",
  "createdAt": "2018-12-19 09:26:03.478039",
  "text": "This a DSTNote sample"
}

Delete a DSTNote

This API allows to delete a DSTNote.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • noteIdpath parameterinteger

    The reference of a DSTNote

DELETE

/DST/{id}/note/{noteId}

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/note/14"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

The Devices APIs set

Devices are registered instances of mobile devices (e.g.: smartphones and tables) with SigningToday App installed and bound to a User. This set of APIs lets You manage them.

Get the list of trusted devices

The API allows to enumerate all the devices of a user.

  • parameters
  • userIdquery parameter

    Select the objects relative to the user specified by the parameter. If not specified will be used the id of the current authenticated user

  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

GET

/devices

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/devices' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/devices");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/devices")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/devices"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "count": 1,
  "values": [
    {
      "userId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "deviceId": "e6419924-fd1d-4c42-9fa2-88023461f5df",
      "name": "John Doe\"s Iphone",
      "registeredAt": "2021-10-17T07:26Z"
    }
  ]
}

Retrieve a challenge for authorizing a new trusted device

This API allows to retrieve a challenge in order to authorize a new trusted device.

  • If asked in image/png the challenge is given encoded as a QR-Code image.
  • An invocation of the endpoint invalidate any previous challenge.
  • The challenge lasts 10 minutes.
GET

/device/authorization

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/device/authorization' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/device/authorization");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/device/authorization")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/device/authorization"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "userId": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
  "baseURL": "https://web.sandbox.signingtoday.com/api/challenge",
  "challenge": "8df173c3bcd4274715491fc196705da8"
}

Register a new trusted device

This API allows to register a new trusted device. If the device is already present, it returns the current associated Token and updates the name.

  • parameters
  • challengestring

    The challenge to be used to register the device

  • deviceIdstring

    The id of the device

  • namestring

    An arbitrary name to be assigned to the device

POST

/device/authorization

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/device/authorization' \
  -H 'Content-Type: application/json' \
  -d '{
  "challenge": "2a12618a-4128-11ea-b77f-2e728ce88125",
  "deviceId": "123e4567-e89b-12d3-a456-556642440000",
  "name": "John Doe\"s iPhone"
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/device/authorization");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "challenge": "2a12618a-4128-11ea-b77f-2e728ce88125",
  "deviceId": "123e4567-e89b-12d3-a456-556642440000",
  "name": "John Doe\"s iPhone"
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "challenge": "2a12618a-4128-11ea-b77f-2e728ce88125",
  "deviceId": "123e4567-e89b-12d3-a456-556642440000",
  "name": "John Doe\"s iPhone"
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/device/authorization")
  .method("POST", body)
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/device/authorization"
headers = {
    "Content-Type": "application/json"
}
payload = {
    "challenge": "2a12618a-4128-11ea-b77f-2e728ce88125",
    "deviceId": "123e4567-e89b-12d3-a456-556642440000",
    "name": "John Doe\"s iPhone"
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

[
  "123e4567-e89b-12d3-a456-556642440000"
]

Clear a trusted device

This APIs allows to deregister a deviceId of a trusted device.

It also deletes any notification push-token associated to the trusted device.

  • parameters
  • deviceIdquery parameter

    The deviceId to deregister

  • userIdquery parameter

    Select the objects relative to the user specified by the parameter. If not specified will be used the id of the current authenticated user

DELETE

/device/authorization

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/device/authorization?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/device/authorization?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/device/authorization?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/device/authorization"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "deviceId": "05ea656f-df69-49b1-a12b-9bf640c427c2"
}
response = requests.delete(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

The Digital Signature Transaction model

The Digital Signature Transaction is the core object at the center of every digital signature workflow in Signing Today. It is a collection element and holds every document (to be signed or just attached to the transaction) as well as the signature plan required to fulfill the transaction; how many signatures are required, are there any forms to be filled, appearance, signature sequence, signers... everything starts here.

  • attributes
  • idstringuuid

    The uuid code that identifies the Digital Signature Transaction

  • domainstringany

    The domain is the Organization which a user or a DST belongs

  • titlestringany

    Title of the Digital Signature Transaction

  • replacesstringuuid

    The DST which this one replaces

  • replacedBystringuuid

    The DST which has replaces the current one

  • createdByUserstringuuid

    The user created the Digital Signature Transaction

  • createdAtstringdate-time

    Date of creation of the Digital Signature Transaction

  • documentsarray

    The documents field is an array containing document objects, where everyone of them is defined as follows

    • _instance_idint64

      It is a reference for internal use

    • idint32

      Unique Id of the document

    • plainDocumentUuiduuid

      Id of the associated Resource (plain PDF file e.g. the one uploaded by the user)

    • filledDocumentUuiduuid

      Id of the associated PDF file that contains all the forms filled (present only once the whole document has been filled)

    • signedDocumentUuiduuid

      Id of the associated PDF file that contains all the signatures (present only once the whole document has been signed)

    • statusany

      The status of the Document, which can be:

      • "plain": The document has been correctly updated by the user
      • "filled": The document has been filled
      • "signed": The document has been signed
    • formsarray

      The fillable elements of the document. Use the type field to identify textual fillable fields and signature fields

    • signatureRequestsarray

      The list of signature request of the document

    • signerGroupsarray

      The sign plan for the document

    • extraDataNone

      no description provided

  • publishedAtstringdate-time

    The date-time the DST has been published

  • expiresAtstringdate-time

    Indicates when the DST will expire

  • resourcesarray

    An array of resources attached to the DST, each one defined as follows

    • iduuid

      Unique id of the resource

    • domainany

      The domain is the Organization which a user or a DST belongs

    • typeany

      Type of the resource, for example a PDFResource

    • dstUuiduuid

      Unique id of the DST which the resource is correlated

    • titleany

      Title of the resource

    • filenameany

      Name of the file uploaded, with its extension as well

    • urlurl

      Url of the resource

    • sizeint64

      Size of the resource

    • createdAtdate-time

      Indicates when the resource has been uploaded

    • mimetypeany

      MIME type of the resource

    • pagesint32

      Indicates how many pages the resource is

    • extraDataany

      Extra data of the resource

  • signaturesarray

    An array of signatures, each one defined as follows

    • _instance_idint64

      It is a reference for internal use

    • documentIdint32

      Id of the document

    • signatureRequestIdint32

      Id of the requested signature

    • signedAtdate-time

      Indicates when the DST has been signed

    • declinedReasonany

      no description provided

    • statusany

      Status of the signature, which can be signed or declined

    • extraDataany

      Extra data of the signature

  • statusstring

    Status of the Digital Signature Transaction

    • draft
    • downloadingInDraft
    • downloadingInPublished
    • published
    • toFill
    • toSign
    • expired
    • signed
    • rejected
    • error
  • errorMessagestringall

    The explication of the occurred error

  • deletedAtstringdate-time

    Indicates when the DST has been deleted

  • tagsarray

    An array of tags for the DST. In such way is possible to tag in the same way some DSTs in order to keep them organized and been easy to find them through the custom search

  • templateboolean

    Indicates if a template has been used to create the DST or not

  • publicTemplateboolean

    Indicates if a public template has been used to create the DST or not

  • extraDataobject

    Extra information about the DST

  • visibleToarray

    UUIDs of the users to which the DST is visible

  • ccGroupsarray

    Name of groups that are informed about the DST

  • ccUsersarray

    UUIDs of the users that are informed about the DST

  • urgentboolean

    True if the DST is flagged as urgent

  • updatedAtstringdate-time

    Indicates the last update of the DST, such as the performing of a signature

Retrieve DSTs

This API allows to list the DSTs of an organization.

  • parameters
  • templatequery parameter

    Select templates or instances

  • userIdquery parameter

    Select the objects relative to the user specified by the parameter. If not specified will be used the id of the current authenticated user

  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

  • $orderByquery parameter

    An ordering definition (eg. $orderBy=updatedAt,desc)

  • $filterquery parameter

    A filter definition (eg. $filter=name == "Milk" or surname == "Bread")

GET

/DSTs

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DSTs' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DSTs");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DSTs")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DSTs"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "count": 1,
  "values": [
    {
      "domain": "bit4id",
      "title": "Real estate sales contract transaction",
      "documents": [
        {
          "id": 1,
          "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
          "forms": [
            {
              "id": 0,
              "documentId": 0,
              "type": "SignatureForm",
              "positionX": "100.00",
              "positionY": "58.14",
              "width": "10.1",
              "height": "5.66",
              "page": 1,
              "signerId": 0,
              "toFill": true,
              "filled": false,
              "invisible": true,
              "extraData": {
                "signatureRequestId": 0
              }
            }
          ],
          "signatureRequests": [
            {
              "id": 0,
              "reason": "As the Buyer",
              "description": "The proponent",
              "signerId": 0,
              "signProfile": "PAdES",
              "withTimestamp": true,
              "declinable": false,
              "restrictions": [
                {
                  "rule": "",
                  "operator": "",
                  "value": ""
                }
              ],
              "extraData": {
                "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
              }
            }
          ],
          "signerGroups": [
            {
              "label": "Group 1",
              "signers": [
                {
                  "id": 0,
                  "name": "Adam",
                  "surname": "Smith",
                  "email": "adam.smith@email.com"
                }
              ]
            }
          ],
          "extraData": {
            "additionalProperty": {}
          }
        }
      ],
      "resources": [
        {
          "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
          "domain": "bit4id",
          "title": "Sales Contract",
          "filename": "contract.pdf",
          "pages": 3,
          "extraData": {
            "toSign": true
          }
        }
      ],
      "signatures": [
        {
          "documentId": 3,
          "signatureRequestId": 0,
          "signedAt": "2021-10-17T07:26Z",
          "declinedReason": "Reason of declination",
          "extraData": {
            "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
          }
        }
      ],
      "errorMessage": null,
      "tags": null,
      "template": false,
      "publicTemplate": false,
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      },
      "visibleTo": null,
      "ccGroups": null,
      "ccUsers": null,
      "urgent": false
    }
  ]
}

Create a new DST

This API allows to creates a new DST. A DST is created in the Draft state and then updated using PUT. Example of creation request:

{
  status: "draft",
  publishedAt: null,
  tags: [],
  urgent: false,
  template: false
}

To add documents use the Resources Patch endpoint /DST/{id}/resources.

If the template flag is set true the DST is a Template. If the publicTemplate flag is set true the Template is visible to all users with rights to create a DST.

A DST is made made available to users using publish end point. A template generates a DST with the instantiate endpoint.

  • parameters
  • idstring

    The uuid code that identifies the Digital Signature Transaction

  • domainstring

    The domain is the Organization which a user or a DST belongs

  • titlestring

    Title of the Digital Signature Transaction

  • replacesstring

    The DST which this one replaces

  • replacedBystring

    The DST which has replaces the current one

  • createdByUserstring

    The user created the Digital Signature Transaction

  • createdAtstring

    Date of creation of the Digital Signature Transaction

  • documentsarray

    The documents field is an array containing document objects, where everyone of them is defined as follows

    • _instance_idint64

      It is a reference for internal use

    • idint32

      Unique Id of the document

    • plainDocumentUuiduuid

      Id of the associated Resource (plain PDF file e.g. the one uploaded by the user)

    • filledDocumentUuiduuid

      Id of the associated PDF file that contains all the forms filled (present only once the whole document has been filled)

    • signedDocumentUuiduuid

      Id of the associated PDF file that contains all the signatures (present only once the whole document has been signed)

    • statusany

      The status of the _Document_, which can be:
      - "plain": The document has been correctly updated by the user
      - "filled": The document has been filled
      - "signed": The document has been signed

    • formsarray

      The fillable elements of the document. Use the type field to identify textual fillable fields and signature fields

    • signatureRequestsarray

      The list of signature request of the document

    • signerGroupsarray

      The sign plan for the document

    • extraDataNone

      None

  • publishedAtstring

    The date-time the DST has been published

  • expiresAtstring

    Indicates when the DST will expire

  • resourcesarray

    An array of resources attached to the DST, each one defined as follows

    • iduuid

      Unique id of the resource

    • domainany

      The _domain_ is the Organization which a user or a DST belongs

    • typeany

      Type of the resource, for example a _PDFResource_

    • dstUuiduuid

      Unique id of the _DST_ which the resource is correlated

    • titleany

      Title of the resource

    • filenameany

      Name of the file uploaded, with its extension as well

    • urlurl

      Url of the resource

    • sizeint64

      Size of the resource

    • createdAtdate-time

      Indicates when the resource has been uploaded

    • mimetypeany

      _MIME_ type of the resource

    • pagesint32

      Indicates how many pages the resource is

    • extraDataany

      Extra data of the resource

  • signaturesarray

    An array of signatures, each one defined as follows

    • _instance_idint64

      It is a reference for internal use

    • documentIdint32

      Id of the document

    • signatureRequestIdint32

      Id of the requested signature

    • signedAtdate-time

      Indicates when the DST has been signed

    • declinedReasonany

      None

    • statusany

      Status of the signature, which can be _signed_ or _declined_

    • extraDataany

      Extra data of the signature

  • statusstring

    Status of the Digital Signature Transaction

    • draft
    • downloadingInDraft
    • downloadingInPublished
    • published
    • toFill
    • toSign
    • expired
    • signed
    • rejected
    • error
  • errorMessagestring

    The explication of the occurred error

  • deletedAtstring

    Indicates when the DST has been deleted

  • tagsarray

    An array of tags for the DST. In such way is possible to tag in the same way some DSTs in order to keep them organized and been easy to find them through the custom search

  • templateboolean

    Indicates if a template has been used to create the DST or not

  • publicTemplateboolean

    Indicates if a public template has been used to create the DST or not

  • extraDataobject

    Extra information about the DST

  • visibleToarray

    UUIDs of the users to which the DST is visible

  • ccGroupsarray

    Name of groups that are informed about the DST

  • ccUsersarray

    UUIDs of the users that are informed about the DST

  • urgentboolean

    True if the DST is flagged as urgent

  • updatedAtstring

    Indicates the last update of the DST, such as the performing of a signature

POST

/DSTs

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DSTs' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DSTs");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DSTs")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DSTs"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "domain": "bit4id",
    "title": "Real estate sales contract transaction",
    "documents": [
        {
            "id": 1,
            "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
            "forms": [
                {
                    "id": 0,
                    "documentId": 0,
                    "type": "SignatureForm",
                    "positionX": "100.00",
                    "positionY": "58.14",
                    "width": "10.1",
                    "height": "5.66",
                    "page": 1,
                    "signerId": 0,
                    "toFill": True,
                    "filled": False,
                    "invisible": True,
                    "extraData": {
                        "signatureRequestId": 0
                    }
                }
            ],
            "signatureRequests": [
                {
                    "id": 0,
                    "reason": "As the Buyer",
                    "description": "The proponent",
                    "signerId": 0,
                    "signProfile": "PAdES",
                    "withTimestamp": True,
                    "declinable": False,
                    "restrictions": [
                        {
                            "rule": "",
                            "operator": "",
                            "value": ""
                        }
                    ],
                    "extraData": {
                        "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
                    }
                }
            ],
            "signerGroups": [
                {
                    "label": "Group 1",
                    "signers": [
                        {
                            "id": 0,
                            "name": "Adam",
                            "surname": "Smith",
                            "email": "adam.smith@email.com"
                        }
                    ]
                }
            ],
            "extraData": {
                "additionalProperty": {}
            }
        }
    ],
    "resources": [
        {
            "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
            "domain": "bit4id",
            "title": "Sales Contract",
            "filename": "contract.pdf",
            "pages": 3,
            "extraData": {
                "toSign": True
            }
        }
    ],
    "signatures": [
        {
            "documentId": 3,
            "signatureRequestId": 0,
            "signedAt": "2021-10-17T07:26Z",
            "declinedReason": "Reason of declination",
            "extraData": {
                "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
            }
        }
    ],
    "errorMessage": None,
    "tags": None,
    "template": False,
    "publicTemplate": False,
    "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    },
    "visibleTo": None,
    "ccGroups": None,
    "ccUsers": None,
    "urgent": False
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
201

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Instantiate a DST from a template

This API allows to instantiate a DST from a template by specifying the template Id.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/instantiate

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Instantiate a DST from a template from file

This API allows to instantiate a DST from a template by the Id and using a Template Spec file.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • publishquery parameter

    True if should be the template published

  • filestring

    The file to upload in csv or xlsx format

  • titlestring

    The title of the file

  • tagsarray

    Tags to override

POST

/DST/{id}/instantiate/byFile

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate/byFile' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: multipart/form-data' \
  -f 'file=/Users/user/Desktop/template.csv' \
  -f 'title=Test File' \
  -f 'tags=[]'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate/byFile");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("file", "/Users/user/Desktop/template.csv");
request.AddParameter("title", "Test File");
request.AddParameter("tags", "[]");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("file", "/Users/user/Desktop/template.csv")
  .addFormDataPart("title", "Test File")
  .addFormDataPart("tags", "[]")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate/byFile")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate/byFile"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
payload = MultipartEncoder(
    fields = {
        "file": "/Users/user/Desktop/template.csv",
        "title": "Test File",
        "tags": []
})
headers["Content-Type"] = payload.content_type
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "instantiationGroup": null,
  "title": "Test DSTs",
  "dstIDs": [
    "cfb5d919-5c40-40fd-b7cf-6ca5d51a4ff6",
    "e6661cbd-52e8-4b39-86e7-0c5600c18eef"
  ]
}

Modify a published DST template

This API allows to move a published DST to DRAFT, allowing the modification. This way is possible to modify a DST Template.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/modify

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/modify' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/modify");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/modify")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/modify"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Create a template from a DST

This API allows to creates a new template starting from a DST. Currently implemented only for published DST templates.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/templatize

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/templatize' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/templatize");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/templatize")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/templatize"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Retrieve the audit records associated to the DST

This API allows to retrieves the audit records associated to the DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/DST/{id}/audit

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/audit' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/audit");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/audit")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/audit"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

[
  {
    "at": "2020-01-17T07:26Z",
    "event": "stage_signed",
    "signer": {
      "name": "Adam",
      "surname": "Smith",
      "email": "adam.smith@email.com",
      "role": "buyer",
      "userUUID": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
    },
    "value": "utente registrato John Doe (jdo@bit4id.com) ha pubblicato la DST \"Contratto\" (aeaa6c62-8b59-4fac-9419-8e9a95aea410)\nLa DST contiene i documenti:\n- \"Contratto Preliminare\" con compilatori [John Doe (jdo@bit4id.com)] e firmatari [Adam Smith (adam.smith@email.com)]",
    "dstId": "00f462e8-333c-45d6-bdef-95797cc1a2a9",
    "documentId": 2,
    "fillableFormId": 3,
    "signatureRequestId": 0,
    "noteId": 2
  }
]

Replace a rejected DST

This API allows to replace a rejected DST instantiating a new one. The replacing DST is created in DRAFT state.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/replace

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/replace' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/replace");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/replace")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/replace"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Clone a DST

This API allows to clone a DST in any state.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/clone

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/clone' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/clone");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/clone")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/clone"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Return the address for signing

This API returns the address to perform the signature.

  • parameters
  • idpath parameter

    The value of the unique id

  • docIdpath parameter

    Reference to docId has to be signed

  • signIdpath parameter

    Reference to the signature request id

GET

/DST/{id}/sign/{docId}/{signId}

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DST/{id}/sign/{docId}/{signId}' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/{id}/sign/{docId}/{signId}");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/{id}/sign/{docId}/{signId}")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/{id}/sign/{docId}/{signId}"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "url": "https://web.sandbox.signingtoday.com/dst/da789cfe-4a8f-42d1-a34e-adc6908d6956"
}

Retrieve a DST

This API allows to retrieve a DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/DST/{id}

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Update a DST

This API allows to update a DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • idstring

    The uuid code that identifies the Digital Signature Transaction

  • domainstring

    The domain is the Organization which a user or a DST belongs

  • titlestring

    Title of the Digital Signature Transaction

  • replacesstring

    The DST which this one replaces

  • replacedBystring

    The DST which has replaces the current one

  • createdByUserstring

    The user created the Digital Signature Transaction

  • createdAtstring

    Date of creation of the Digital Signature Transaction

  • documentsarray

    The documents field is an array containing document objects, where everyone of them is defined as follows

    • _instance_idint64

      It is a reference for internal use

    • idint32

      Unique Id of the document

    • plainDocumentUuiduuid

      Id of the associated Resource (plain PDF file e.g. the one uploaded by the user)

    • filledDocumentUuiduuid

      Id of the associated PDF file that contains all the forms filled (present only once the whole document has been filled)

    • signedDocumentUuiduuid

      Id of the associated PDF file that contains all the signatures (present only once the whole document has been signed)

    • statusany

      The status of the _Document_, which can be:
      - "plain": The document has been correctly updated by the user
      - "filled": The document has been filled
      - "signed": The document has been signed

    • formsarray

      The fillable elements of the document. Use the type field to identify textual fillable fields and signature fields

    • signatureRequestsarray

      The list of signature request of the document

    • signerGroupsarray

      The sign plan for the document

    • extraDataNone

      None

  • publishedAtstring

    The date-time the DST has been published

  • expiresAtstring

    Indicates when the DST will expire

  • resourcesarray

    An array of resources attached to the DST, each one defined as follows

    • iduuid

      Unique id of the resource

    • domainany

      The _domain_ is the Organization which a user or a DST belongs

    • typeany

      Type of the resource, for example a _PDFResource_

    • dstUuiduuid

      Unique id of the _DST_ which the resource is correlated

    • titleany

      Title of the resource

    • filenameany

      Name of the file uploaded, with its extension as well

    • urlurl

      Url of the resource

    • sizeint64

      Size of the resource

    • createdAtdate-time

      Indicates when the resource has been uploaded

    • mimetypeany

      _MIME_ type of the resource

    • pagesint32

      Indicates how many pages the resource is

    • extraDataany

      Extra data of the resource

  • signaturesarray

    An array of signatures, each one defined as follows

    • _instance_idint64

      It is a reference for internal use

    • documentIdint32

      Id of the document

    • signatureRequestIdint32

      Id of the requested signature

    • signedAtdate-time

      Indicates when the DST has been signed

    • declinedReasonany

      None

    • statusany

      Status of the signature, which can be _signed_ or _declined_

    • extraDataany

      Extra data of the signature

  • statusstring

    Status of the Digital Signature Transaction

    • draft
    • downloadingInDraft
    • downloadingInPublished
    • published
    • toFill
    • toSign
    • expired
    • signed
    • rejected
    • error
  • errorMessagestring

    The explication of the occurred error

  • deletedAtstring

    Indicates when the DST has been deleted

  • tagsarray

    An array of tags for the DST. In such way is possible to tag in the same way some DSTs in order to keep them organized and been easy to find them through the custom search

  • templateboolean

    Indicates if a template has been used to create the DST or not

  • publicTemplateboolean

    Indicates if a public template has been used to create the DST or not

  • extraDataobject

    Extra information about the DST

  • visibleToarray

    UUIDs of the users to which the DST is visible

  • ccGroupsarray

    Name of groups that are informed about the DST

  • ccUsersarray

    UUIDs of the users that are informed about the DST

  • urgentboolean

    True if the DST is flagged as urgent

  • updatedAtstring

    Indicates the last update of the DST, such as the performing of a signature

PUT

/DST/{id}

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "domain": "bit4id",
    "title": "Real estate sales contract transaction",
    "documents": [
        {
            "id": 1,
            "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
            "forms": [
                {
                    "id": 0,
                    "documentId": 0,
                    "type": "SignatureForm",
                    "positionX": "100.00",
                    "positionY": "58.14",
                    "width": "10.1",
                    "height": "5.66",
                    "page": 1,
                    "signerId": 0,
                    "toFill": True,
                    "filled": False,
                    "invisible": True,
                    "extraData": {
                        "signatureRequestId": 0
                    }
                }
            ],
            "signatureRequests": [
                {
                    "id": 0,
                    "reason": "As the Buyer",
                    "description": "The proponent",
                    "signerId": 0,
                    "signProfile": "PAdES",
                    "withTimestamp": True,
                    "declinable": False,
                    "restrictions": [
                        {
                            "rule": "",
                            "operator": "",
                            "value": ""
                        }
                    ],
                    "extraData": {
                        "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
                    }
                }
            ],
            "signerGroups": [
                {
                    "label": "Group 1",
                    "signers": [
                        {
                            "id": 0,
                            "name": "Adam",
                            "surname": "Smith",
                            "email": "adam.smith@email.com"
                        }
                    ]
                }
            ],
            "extraData": {
                "additionalProperty": {}
            }
        }
    ],
    "resources": [
        {
            "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
            "domain": "bit4id",
            "title": "Sales Contract",
            "filename": "contract.pdf",
            "pages": 3,
            "extraData": {
                "toSign": True
            }
        }
    ],
    "signatures": [
        {
            "documentId": 3,
            "signatureRequestId": 0,
            "signedAt": "2021-10-17T07:26Z",
            "declinedReason": "Reason of declination",
            "extraData": {
                "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
            }
        }
    ],
    "errorMessage": None,
    "tags": None,
    "template": False,
    "publicTemplate": False,
    "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    },
    "visibleTo": None,
    "ccGroups": None,
    "ccUsers": None,
    "urgent": False
}
response = requests.put(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Delete a DST

This API allows to delete a DST. Actually the DST is marked as deleted thus not displayed anymore into the organization, but it will still be present in the database.

  • parameters
  • idpath parameterstring

    The value of the unique id

DELETE

/DST/{id}

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Fill a form of a DST

This API allows to fill a form of a DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • _instance_idinteger

    It is a reference for internal use

  • idinteger

    Id of the form

  • documentIdinteger

    Id of the document

  • typestring

    Type of the fill form

  • positionXnumber

    Position onto the X axis of the form, expressed in percentage

  • positionYnumber

    Position onto the Y axis of the form, expressed in percentage

  • widthnumber

    Width of the form expressed in percentage

  • heightnumber

    Height of the form expressed in percentage

  • pageinteger

    Page of the document where the form is

  • signerIdinteger

    Id of the signer in the sign plan

  • toFillboolean

    True if the field need to be filled by the user. In case of a Signature it is false

  • filledboolean

    True ones the form has been filled

  • invisibleboolean

    True if the appearance has to be hidden

  • extraDataobject

    Extra information about the form

PATCH

/DST/{id}/fill

Click to copy
curl -L -X PATCH \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/fill' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "id": 0,
  "documentId": 0,
  "type": "SignatureForm",
  "positionX": "100.00",
  "positionY": "58.14",
  "width": "10.1",
  "height": "5.66",
  "page": 1,
  "signerId": 0,
  "toFill": true,
  "filled": false,
  "invisible": true,
  "extraData": {
    "signatureRequestId": 0
  }
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/fill");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "id": 0,
  "documentId": 0,
  "type": "SignatureForm",
  "positionX": "100.00",
  "positionY": "58.14",
  "width": "10.1",
  "height": "5.66",
  "page": 1,
  "signerId": 0,
  "toFill": true,
  "filled": false,
  "invisible": true,
  "extraData": {
    "signatureRequestId": 0
  }
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "id": 0,
  "documentId": 0,
  "type": "SignatureForm",
  "positionX": "100.00",
  "positionY": "58.14",
  "width": "10.1",
  "height": "5.66",
  "page": 1,
  "signerId": 0,
  "toFill": true,
  "filled": false,
  "invisible": true,
  "extraData": {
    "signatureRequestId": 0
  }
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/fill")
  .method("PATCH", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/fill"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "id": 0,
    "documentId": 0,
    "type": "SignatureForm",
    "positionX": "100.00",
    "positionY": "58.14",
    "width": "10.1",
    "height": "5.66",
    "page": 1,
    "signerId": 0,
    "toFill": True,
    "filled": False,
    "invisible": True,
    "extraData": {
        "signatureRequestId": 0
    }
}
response = requests.patch(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Publish a DST

This API allows to publish a DST, the new state becomes published. It will automatically evolve to a new state where it will be filled or signed.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/publish

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/publish' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/publish");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/publish")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/publish"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Send notifications for a DST

This API allows to send notifications to pending users for an active DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

POST

/DST/{id}/notify

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/notify' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/notify");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/notify")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/notify"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.post(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Retrieve DSTs instantiated by file

This API allows to enumerate the DSTs instantiated by file.

  • parameters
  • userIdquery parameter

    Select the objects relative to the user specified by the parameter. If not specified will be used the id of the current authenticated user

  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

  • $orderByquery parameter

    An ordering definition (eg. $orderBy=updatedAt,desc)

GET

/DSTs/byFile

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DSTs/byFile' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DSTs/byFile");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DSTs/byFile")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DSTs/byFile"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "values": [
    {
      "instantiationGroupId": "Partners",
      "templateId": "bcbde8fe-8739-4f27-9215-bf6aaae8172c",
      "title": "Partnership Agreement",
      "generatedAt": "2021-01-17T07:26Z",
      "groupSize": 2,
      "inStateSigned": 1,
      "inStateError": 0,
      "inStateRejected": 0,
      "inStateExpired": 0
    }
  ],
  "count": 1
}

Create a DST Template by File

This API allows to create a new DST Template by File.

  • parameters
  • filestring

    The file to upload

POST

/DSTs/byFile

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DSTs/byFile' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: multipart/form-data' \
  -f 'file=/Users/user/Desktop/template.csv'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DSTs/byFile");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("file", "/Users/user/Desktop/template.csv");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("file", "/Users/user/Desktop/template.csv")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DSTs/byFile")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/DSTs/byFile"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
payload = MultipartEncoder(
    fields = {
        "file": "/Users/user/Desktop/template.csv"
})
headers["Content-Type"] = payload.content_type
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

The Notifications APIs set

The Notifications APIs set describes all about the notifications, used to send updates about the DSTs to everyone involved.

Get latest DST Notifications

This APIs allows to get latest user Notifications for DSTs sorted desc by time.

  • parameters
  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

GET

/notifications/dsts

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/notifications/dsts' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/notifications/dsts");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/notifications/dsts")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/notifications/dsts"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "count": 1,
  "values": [
    {
      "dstTitle": "Contract",
      "username": "johndoe",
      "email": "jdo@bit4id.com"
    }
  ]
}

Clear Notifications for a DST

This API notifies that a user consumed all active notifications for a DST.

  • parameters
  • idpath parameter

    The value of the unique id

DELETE

/notifications/dst/{id}

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/notifications/dst/{id}' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/notifications/dst/{id}");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/notifications/dst/{id}")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/notifications/dst/{id}"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Register a token for push notifications

This API allows to register a token for push notifications. Only trusted deviceId can be registered.

  • parameters
  • deviceIdstring

    Unique reference to the device

  • tokenstring

    The token to register

POST

/notifications/push-token

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/notifications/push-token' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "deviceId": "1ca229c8-2a99-4f3e-9421-36377fd8d9e5",
  "token": "c84c1180-3bdf-44e0-afee-1e255c7ab88f"
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/notifications/push-token");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "deviceId": "1ca229c8-2a99-4f3e-9421-36377fd8d9e5",
  "token": "c84c1180-3bdf-44e0-afee-1e255c7ab88f"
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "deviceId": "1ca229c8-2a99-4f3e-9421-36377fd8d9e5",
  "token": "c84c1180-3bdf-44e0-afee-1e255c7ab88f"
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/notifications/push-token")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/notifications/push-token"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "deviceId": "1ca229c8-2a99-4f3e-9421-36377fd8d9e5",
    "token": "c84c1180-3bdf-44e0-afee-1e255c7ab88f"
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Clear a registered push notification token

This API deregister a deviceId from the push notifications.

  • parameters
  • deviceIdquery parameter

    The deviceId to deregister

DELETE

/notifications/push-token

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/notifications/push-token?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/notifications/push-token?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/notifications/push-token?deviceId=05ea656f-df69-49b1-a12b-9bf640c427c2")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/notifications/push-token"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "deviceId": "05ea656f-df69-49b1-a12b-9bf640c427c2"
}
response = requests.delete(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

The Resources APIs set

The Resources APIs set is all about the Resources/Files associated to Users or DSTs. This set of APIs contains what You need to add, delete or just retrieve resources of a DST, such as the documents to be signed. In the same way there are APIs to upload or delete the signature appearance of the users' identities.

Download an identity appearance resource

This API allows to get the identity appearance resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • identity-idpath parameterstring

    The unique id of the Identity

GET

/user/{id}/identity/{identity-id}/appearance

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

The response is the binary resource file content.

Add a graphical appearance to a user's identity

This API allows to add a graphical appearance to the identity of a user.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • identity-idpath parameterstring

    The unique id of the Identity

  • filestring

    The path of the file to upload

  • filenamestring

    The name of the file

  • resourceTypestring

    The type of the resource

    • PDF_Document
    • Image
  • titlestring

    User-defined title of the resource

POST

/user/{id}/identity/{identity-id}/appearance

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: multipart/form-data' \
  -f 'file=C:\Users\jdo\contracts\contract.pdf' \
  -f 'filename=contract.pdf' \
  -f 'resourceType=PDF_Document' \
  -f 'title=Sales Contract'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("file", "C:\Users\jdo\contracts\contract.pdf");
request.AddParameter("filename", "contract.pdf");
request.AddParameter("resourceType", "PDF_Document");
request.AddParameter("title", "Sales Contract");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("file", "C:\Users\jdo\contracts\contract.pdf")
  .addFormDataPart("filename", "contract.pdf")
  .addFormDataPart("resourceType", "PDF_Document")
  .addFormDataPart("title", "Sales Contract")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
payload = MultipartEncoder(
    fields = {
        "file": "C:\\Users\\jdo\\contracts\\contract.pdf",
        "filename": "contract.pdf",
        "resourceType": "PDF_Document",
        "title": "Sales Contract"
})
headers["Content-Type"] = payload.content_type
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
  "domain": "bit4id",
  "title": "Sales Contract",
  "filename": "contract.pdf",
  "pages": 3,
  "extraData": {
    "toSign": true
  }
}

Delete a user appearance resource.

This API allows to delete an identity appearance resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • identity-idpath parameterstring

    The unique id of the Identity

DELETE

/user/{id}/identity/{identity-id}/appearance

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identity/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/appearance"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Retrieve a Resource

This API allows to retrieve a Resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/resource/{id}

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

The response is the binary resource file content.

Update a Resource

This API allows to update a Resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • idstring

    Unique id of the resource

  • domainstring

    The domain is the Organization which a user or a DST belongs

  • typestring

    Type of the resource, for example a PDFResource

  • dstUuidstring

    Unique id of the DST which the resource is correlated

  • titlestring

    Title of the resource

  • filenamestring

    Name of the file uploaded, with its extension as well

  • urlstring

    Url of the resource

  • sizeinteger

    Size of the resource

  • createdAtstring

    Indicates when the resource has been uploaded

  • mimetypestring

    MIME type of the resource

  • pagesinteger

    Indicates how many pages the resource is

  • extraDataobject

    Extra data of the resource

PUT

/resource/{id}

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
  "domain": "bit4id",
  "title": "Sales Contract",
  "filename": "contract.pdf",
  "pages": 3,
  "extraData": {
    "toSign": true
  }
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
  "domain": "bit4id",
  "title": "Sales Contract",
  "filename": "contract.pdf",
  "pages": 3,
  "extraData": {
    "toSign": true
  }
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
  "domain": "bit4id",
  "title": "Sales Contract",
  "filename": "contract.pdf",
  "pages": 3,
  "extraData": {
    "toSign": true
  }
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
    "domain": "bit4id",
    "title": "Sales Contract",
    "filename": "contract.pdf",
    "pages": 3,
    "extraData": {
        "toSign": True
    }
}
response = requests.put(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Delete a Resource

This API allows to delete a Resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

DELETE

/DST/resource/{id}

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/DST/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/resource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Swap the order of a document with another

This API allows to swap the order of a document with another.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • docIdpath parameterinteger

    The id of the document to swap

  • targetDocIdquery parameterinteger

    The id of the target document

POST

/DST/{id}/doc/{docId}/swap

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/swap?targetDocId=1' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/swap?targetDocId=1");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/swap?targetDocId=1")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/swap"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "targetDocId": 1
}
response = requests.post(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Perform an action on a document resource

This API allows to perform an action on a document resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • docIdpath parameterinteger

    The id of the document to swap

  • filestring

    The file to upload

  • filenamestring

    The name of the file

  • resourceTypestring

    The type of the resource. Only available is PDF_Document

    • PDF_Document
  • titlestring

    User-defined title of the resource

  • actionTypestring

    None

    • replace
    • clone_and_replace
POST

/DST/{id}/doc/{docId}/resource

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/resource' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: multipart/form-data' \
  -f 'file=/Users/user/Desktop/doc.pdf' \
  -f 'filename=doc.pdf' \
  -f 'resourceType=PDF_Document' \
  -f 'title=Partnership Agreement' \
  -f 'actionType=replace'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/resource");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("file", "/Users/user/Desktop/doc.pdf");
request.AddParameter("filename", "doc.pdf");
request.AddParameter("resourceType", "PDF_Document");
request.AddParameter("title", "Partnership Agreement");
request.AddParameter("actionType", "replace");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("file", "/Users/user/Desktop/doc.pdf")
  .addFormDataPart("filename", "doc.pdf")
  .addFormDataPart("resourceType", "PDF_Document")
  .addFormDataPart("title", "Partnership Agreement")
  .addFormDataPart("actionType", "replace")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/resource")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/doc/0/resource"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
payload = MultipartEncoder(
    fields = {
        "file": "/Users/user/Desktop/doc.pdf",
        "filename": "doc.pdf",
        "resourceType": "PDF_Document",
        "title": "Partnership Agreement",
        "actionType": "replace"
})
headers["Content-Type"] = payload.content_type
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Retrieve all resources associated to a DST

This API allows to retrieve all resources associated to a DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/DST/{id}/resources

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

The response body contains all resources associated to a DST into a zip file.

Append a new resource to a DST

This API allows to append a new Resource to a DST.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • filestring

    The file to upload

  • filenamestring

    The name of the file

  • resourceTypestring

    The type of resource

    • PDF_Document
  • titlestring

    User-defined title of the resource.

  • extraDataobjcet

    JSON-serialized extra-data

PATCH

/DST/{id}/resources

Click to copy
curl -L -X PATCH \
  'https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: multipart/form-data' \
  -f 'file=C:\Users\jdo\contracts\contract.pdf' \
  -f 'filename=contract.pdf' \
  -f 'resourceType=PDF_Document' \
  -f 'title=Sales Contract' \
  -f 'extraData={}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("file", "C:\Users\jdo\contracts\contract.pdf");
request.AddParameter("filename", "contract.pdf");
request.AddParameter("resourceType", "PDF_Document");
request.AddParameter("title", "Sales Contract");
request.AddParameter("extraData", "{}");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("file", "C:\Users\jdo\contracts\contract.pdf")
  .addFormDataPart("filename", "contract.pdf")
  .addFormDataPart("resourceType", "PDF_Document")
  .addFormDataPart("title", "Sales Contract")
  .addFormDataPart("extraData", "{}")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources")
  .method("PATCH", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/resources"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
payload = MultipartEncoder(
    fields = {
        "file": "C:\\Users\\jdo\\contracts\\contract.pdf",
        "filename": "contract.pdf",
        "resourceType": "PDF_Document",
        "title": "Sales Contract",
        "extraData": {}
})
headers["Content-Type"] = payload.content_type
response = requests.patch(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Retrieve all the resources associated to a DST's group instantiation

This API allowd to retrieve all the resources associated to a DST's group instantiation.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/DSTs/instantiationGroup/{id}/resources

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/DSTs/instantiationGroup/test_id/resources' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/DSTs/instantiationGroup/test_id/resources");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/DSTs/instantiationGroup/test_id/resources")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/DSTs/instantiationGroup/test_id/resources"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

All resources associated to a DST's group instantiation in a zip file.

The Robots APIs set

Whenever You are integrating Signing Today into Your existing Applications (CRM, HR, etc.) and You need to add signature services to them, a couple of simple APIs are all that separates You from Your goal. Here they are. If You're in a hurry go straight to Create a new DST and to Instantiate a DST from a template

Retrieve the Robot authentication lifetime token

This API allows to generate or retrieves the Robot authentication lifetime token for the specified robot account, or the current logged in account.

  • parameters
  • usernamequery parameter

    The username associated to the account

  • domainquery parameter

    The domain associated to the account

GET

/robot/authentication

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/robot/authentication' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/authentication");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/authentication")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/authentication"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "accessToken": "19a6f7b6-e558-46c7-ac1c-ed4fea78e644"
}

Clear a Robot authentication lifetime token

This API allows to clear the Robot authentication lifetime token.

  • parameters
  • usernamequery parameter

    The username associated to the account

  • domainquery parameter

    The domain associated to the account

DELETE

/robot/authentication

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/robot/authentication' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/authentication");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/authentication")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/authentication"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Retrieve the Robot configuration

This API allows to retrieve the Robot configuration.

  • parameters
  • usernamequery parameter

    The username associated to the account

  • domainquery parameter

    The domain associated to the account

GET

/robot/configuration

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/robot/configuration' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/configuration");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/configuration")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/configuration"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "requestHeaders": {
    "Authorization": [
      "Token eed3fc66-cfc8-4b11-9bf9-33493d95411b"
    ]
  },
  "authentication": {
    "username": "jdo",
    "password": "A12345678z",
    "authMode": "basic",
    "clientKey": "clientKey",
    "clientCert": ""
  },
  "webhooks": {
    "dst": "https://web.sandbox.signingtoday.com"
  }
}

Edit the Robot configuration

This API allows to edit the Robot configuration.

  • parameters
  • usernamequery parameter

    The username associated to the account

  • domainquery parameter

    The domain associated to the account

  • requestHeadersobject

    Eventually the headers the application have to use during requests

  • authenticationobject

    The data the application will use to authenticate itself wherever there will be the need, for example in order to access to a resource

    • usernamestring

      The username for the authentication

    • passwordstring

      The password for the authentication

    • authModestring

      The type of authentication

    • clientKeystring

      Client key

    • clientCertstring

      Client certificate

  • webhooksobject

    The webhook where the notifications have to be send

    • dsturl

      Actual URL

PUT

/robot/configuration

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/robot/configuration' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "requestHeaders": {
    "Authorization": [
      "Token eed3fc66-cfc8-4b11-9bf9-33493d95411b"
    ]
  },
  "authentication": {
    "username": "jdo",
    "password": "A12345678z",
    "authMode": "basic",
    "clientKey": "clientKey",
    "clientCert": ""
  },
  "webhooks": {
    "dst": "https://web.sandbox.signingtoday.com"
  }
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/configuration");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "requestHeaders": {
    "Authorization": [
      "Token eed3fc66-cfc8-4b11-9bf9-33493d95411b"
    ]
  },
  "authentication": {
    "username": "jdo",
    "password": "A12345678z",
    "authMode": "basic",
    "clientKey": "clientKey",
    "clientCert": ""
  },
  "webhooks": {
    "dst": "https://web.sandbox.signingtoday.com"
  }
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "requestHeaders": {
    "Authorization": [
      "Token eed3fc66-cfc8-4b11-9bf9-33493d95411b"
    ]
  },
  "authentication": {
    "username": "jdo",
    "password": "A12345678z",
    "authMode": "basic",
    "clientKey": "clientKey",
    "clientCert": ""
  },
  "webhooks": {
    "dst": "https://web.sandbox.signingtoday.com"
  }
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/configuration")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/configuration"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "requestHeaders": {
        "Authorization": [
            "Token eed3fc66-cfc8-4b11-9bf9-33493d95411b"
        ]
    },
    "authentication": {
        "username": "jdo",
        "password": "A12345678z",
        "authMode": "basic",
        "clientKey": "clientKey",
        "clientCert": ""
    },
    "webhooks": {
        "dst": "https://web.sandbox.signingtoday.com"
    }
}
response = requests.put(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Create a new DST in one call

This API allows to create a new DST with a more convenient interface for client applications. The purpose is to provide a method for the creation of a DST in order to semplify the integration into third part applications.

  • parameters
  • titlestring

    Title of the Digital Signature Transaction

  • documentsarray

    The document or documents of the DST

    • resourceobject

      The actual resource (e.g. a pdf file). It has the following fields: "filename" which wilò be the name of the document including its extension once downloaded. "resourceType" which is PDF_Document for pdf documents. "title" which will be the title of the document in the Signature Tray. "source" which is an object and it is different if the document is uploaded from the computer or from the internet. In the first case it will be {"type": Embedded, "embeddedData": -base64 of the file-}. In the second case it will be {"type": "URL" "sourceURL": -the url of the document-}.

    • formsarray

      The fillable elements of the document. Use the type field to identify textual fillable field and signature fields.

    • signatureRequestsarray

      The list of signature request of the document.

    • signerGroupsarray

      The sign plan for the document.

    • extraDataNone

      Json serialized extra data of the document

  • statusstring

    Status of the DST. Set to published in order to publish the DST and start the notification of the signer and the signature flow. Set to draft in order to save the transaction and edid/publish it later

    • draft
    • published
  • expiresAtstring

    Date of expiration of the DST

  • tagsarray

    An array of tags for the DST. In such way is possible to tag in the same way some DSTs in order to keep them organized and been easy to find them through the custom search

  • templateboolean

    True if the DST has been created from a template

  • publicTemplateboolean

    Indicates if a public template has been used to create the DST or not

  • ccGroupsarray

    Name of groups that are informed about the DST.

  • ccUsersarray

    UUIDs of the users that are informed about the DST.

  • urgentboolean

    True if the DST is flagged as urgent

  • extraDataobject

    Json serialized DSTs extra data

POST

/robot/DSTs

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/robot/DSTs' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "resource": {
        "filename": "contract.pdf",
        "resourceType": "PDF_Document",
        "title": "Sales Contract",
        "source": {
          "type": "URL",
          "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
        }
      },
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {}
    }
  ],
  "status": "published",
  "expiresAt": "2030-04-25T12:00:00Z",
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  }
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/DSTs");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "resource": {
        "filename": "contract.pdf",
        "resourceType": "PDF_Document",
        "title": "Sales Contract",
        "source": {
          "type": "URL",
          "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
        }
      },
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {}
    }
  ],
  "status": "published",
  "expiresAt": "2030-04-25T12:00:00Z",
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  }
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "resource": {
        "filename": "contract.pdf",
        "resourceType": "PDF_Document",
        "title": "Sales Contract",
        "source": {
          "type": "URL",
          "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
        }
      },
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {}
    }
  ],
  "status": "published",
  "expiresAt": "2030-04-25T12:00:00Z",
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  }
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/DSTs")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/DSTs"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "title": "Real estate sales contract transaction",
    "documents": [
        {
            "resource": {
                "filename": "contract.pdf",
                "resourceType": "PDF_Document",
                "title": "Sales Contract",
                "source": {
                    "type": "URL",
                    "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
                }
            },
            "forms": [
                {
                    "id": 0,
                    "documentId": 0,
                    "type": "SignatureForm",
                    "positionX": "100.00",
                    "positionY": "58.14",
                    "width": "10.1",
                    "height": "5.66",
                    "page": 1,
                    "signerId": 0,
                    "toFill": True,
                    "filled": False,
                    "invisible": True,
                    "extraData": {
                        "signatureRequestId": 0
                    }
                }
            ],
            "signatureRequests": [
                {
                    "id": 0,
                    "reason": "As the Buyer",
                    "description": "The proponent",
                    "signerId": 0,
                    "signProfile": "PAdES",
                    "withTimestamp": True,
                    "declinable": False,
                    "restrictions": [
                        {
                            "rule": "",
                            "operator": "",
                            "value": ""
                        }
                    ],
                    "extraData": {
                        "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
                    }
                }
            ],
            "signerGroups": [
                {
                    "label": "Group 1",
                    "signers": [
                        {
                            "id": 0,
                            "name": "Adam",
                            "surname": "Smith",
                            "email": "adam.smith@email.com"
                        }
                    ]
                }
            ],
            "extraData": {}
        }
    ],
    "status": "published",
    "expiresAt": "2030-04-25T12:00:00Z",
    "tags": None,
    "template": False,
    "publicTemplate": False,
    "ccGroups": None,
    "ccUsers": None,
    "urgent": False,
    "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    }
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

Instantiate a DST from a template by robot

This API allows to instantiate a DST from a template patching parts of its data structure.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • templatePatchesobject

    The DST Template from which will be created the DST

    • titlestring

      Title of the Digital Signature Transaction

    • documentsarray

      The document or documents of the DST

    • statusstring

      Status of the DST. Set to published in order to publish the DST and start the notification of the signer and the signature flow. Set to draft in order to save the transaction and edid/publish it later

    • expiresAtdate-time

      Date of expiration of the DST

    • tagsstring

      An array of tags for the DST. In such way is possible to tag in the same way some DSTs in order to keep them organized and been easy to find them through the custom search

    • templateboolean

      True if the DST has been created from a template

    • publicTemplateboolean

      Indicates if a public template has been used to create the DST or not

    • ccGroupsarray

      Name of groups that are informed about the DST.

    • ccUsersarray

      UUIDs of the users that are informed about the DST.

    • urgentboolean

      True if the DST is flagged as urgent

    • extraDataNone

      Json serialized DSTs extra data

  • rolesMappingarray

    Indicates the mapping between the role specified into the template and the actual signer have to sign the Digital Signature Transaction

    • roleNamestring

      The role indicated into the template

    • signerobject

      The Mapping of the Roles will be used in the new DST

POST

/robot/DST/{id}/instantiate

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/robot/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "templatePatches": {
    "title": "Real estate sales contract transaction",
    "documents": [
      {
        "resource": {
          "filename": "contract.pdf",
          "resourceType": "PDF_Document",
          "title": "Sales Contract",
          "source": {
            "type": "URL",
            "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
          }
        },
        "forms": [
          {
            "id": 0,
            "documentId": 0,
            "type": "SignatureForm",
            "positionX": "100.00",
            "positionY": "58.14",
            "width": "10.1",
            "height": "5.66",
            "page": 1,
            "signerId": 0,
            "toFill": true,
            "filled": false,
            "invisible": true,
            "extraData": {
              "signatureRequestId": 0
            }
          }
        ],
        "signatureRequests": [
          {
            "id": 0,
            "reason": "As the Buyer",
            "description": "The proponent",
            "signerId": 0,
            "signProfile": "PAdES",
            "withTimestamp": true,
            "declinable": false,
            "restrictions": [
              {
                "rule": "",
                "operator": "",
                "value": ""
              }
            ],
            "extraData": {
              "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
            }
          }
        ],
        "signerGroups": [
          {
            "label": "Group 1",
            "signers": [
              {
                "id": 0,
                "name": "Adam",
                "surname": "Smith",
                "email": "adam.smith@email.com"
              }
            ]
          }
        ],
        "extraData": {}
      }
    ],
    "status": "published",
    "expiresAt": "2030-04-25T12:00:00Z",
    "tags": null,
    "template": false,
    "publicTemplate": false,
    "ccGroups": null,
    "ccUsers": null,
    "urgent": false,
    "extraData": {
      "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    }
  },
  "rolesMapping": [
    {
      "roleName": "Buyer",
      "signer": {
        "name": "Adam",
        "surname": "Smith",
        "email": "adam.smith@email.com",
        "phone": "+013392213450",
        "userUUID": "a845e772-cb45-466f-9c02-d9dd06afa36e"
      }
    }
  ]
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/robot/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "templatePatches": {
    "title": "Real estate sales contract transaction",
    "documents": [
      {
        "resource": {
          "filename": "contract.pdf",
          "resourceType": "PDF_Document",
          "title": "Sales Contract",
          "source": {
            "type": "URL",
            "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
          }
        },
        "forms": [
          {
            "id": 0,
            "documentId": 0,
            "type": "SignatureForm",
            "positionX": "100.00",
            "positionY": "58.14",
            "width": "10.1",
            "height": "5.66",
            "page": 1,
            "signerId": 0,
            "toFill": true,
            "filled": false,
            "invisible": true,
            "extraData": {
              "signatureRequestId": 0
            }
          }
        ],
        "signatureRequests": [
          {
            "id": 0,
            "reason": "As the Buyer",
            "description": "The proponent",
            "signerId": 0,
            "signProfile": "PAdES",
            "withTimestamp": true,
            "declinable": false,
            "restrictions": [
              {
                "rule": "",
                "operator": "",
                "value": ""
              }
            ],
            "extraData": {
              "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
            }
          }
        ],
        "signerGroups": [
          {
            "label": "Group 1",
            "signers": [
              {
                "id": 0,
                "name": "Adam",
                "surname": "Smith",
                "email": "adam.smith@email.com"
              }
            ]
          }
        ],
        "extraData": {}
      }
    ],
    "status": "published",
    "expiresAt": "2030-04-25T12:00:00Z",
    "tags": null,
    "template": false,
    "publicTemplate": false,
    "ccGroups": null,
    "ccUsers": null,
    "urgent": false,
    "extraData": {
      "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    }
  },
  "rolesMapping": [
    {
      "roleName": "Buyer",
      "signer": {
        "name": "Adam",
        "surname": "Smith",
        "email": "adam.smith@email.com",
        "phone": "+013392213450",
        "userUUID": "a845e772-cb45-466f-9c02-d9dd06afa36e"
      }
    }
  ]
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "templatePatches": {
    "title": "Real estate sales contract transaction",
    "documents": [
      {
        "resource": {
          "filename": "contract.pdf",
          "resourceType": "PDF_Document",
          "title": "Sales Contract",
          "source": {
            "type": "URL",
            "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
          }
        },
        "forms": [
          {
            "id": 0,
            "documentId": 0,
            "type": "SignatureForm",
            "positionX": "100.00",
            "positionY": "58.14",
            "width": "10.1",
            "height": "5.66",
            "page": 1,
            "signerId": 0,
            "toFill": true,
            "filled": false,
            "invisible": true,
            "extraData": {
              "signatureRequestId": 0
            }
          }
        ],
        "signatureRequests": [
          {
            "id": 0,
            "reason": "As the Buyer",
            "description": "The proponent",
            "signerId": 0,
            "signProfile": "PAdES",
            "withTimestamp": true,
            "declinable": false,
            "restrictions": [
              {
                "rule": "",
                "operator": "",
                "value": ""
              }
            ],
            "extraData": {
              "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
            }
          }
        ],
        "signerGroups": [
          {
            "label": "Group 1",
            "signers": [
              {
                "id": 0,
                "name": "Adam",
                "surname": "Smith",
                "email": "adam.smith@email.com"
              }
            ]
          }
        ],
        "extraData": {}
      }
    ],
    "status": "published",
    "expiresAt": "2030-04-25T12:00:00Z",
    "tags": null,
    "template": false,
    "publicTemplate": false,
    "ccGroups": null,
    "ccUsers": null,
    "urgent": false,
    "extraData": {
      "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
    }
  },
  "rolesMapping": [
    {
      "roleName": "Buyer",
      "signer": {
        "name": "Adam",
        "surname": "Smith",
        "email": "adam.smith@email.com",
        "phone": "+013392213450",
        "userUUID": "a845e772-cb45-466f-9c02-d9dd06afa36e"
      }
    }
  ]
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/robot/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/robot/DST/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/instantiate"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "templatePatches": {
        "title": "Real estate sales contract transaction",
        "documents": [
            {
                "resource": {
                    "filename": "contract.pdf",
                    "resourceType": "PDF_Document",
                    "title": "Sales Contract",
                    "source": {
                        "type": "URL",
                        "sourceURL": "http://www.africau.edu/images/default/sample.pdf"
                    }
                },
                "forms": [
                    {
                        "id": 0,
                        "documentId": 0,
                        "type": "SignatureForm",
                        "positionX": "100.00",
                        "positionY": "58.14",
                        "width": "10.1",
                        "height": "5.66",
                        "page": 1,
                        "signerId": 0,
                        "toFill": True,
                        "filled": False,
                        "invisible": True,
                        "extraData": {
                            "signatureRequestId": 0
                        }
                    }
                ],
                "signatureRequests": [
                    {
                        "id": 0,
                        "reason": "As the Buyer",
                        "description": "The proponent",
                        "signerId": 0,
                        "signProfile": "PAdES",
                        "withTimestamp": True,
                        "declinable": False,
                        "restrictions": [
                            {
                                "rule": "",
                                "operator": "",
                                "value": ""
                            }
                        ],
                        "extraData": {
                            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
                        }
                    }
                ],
                "signerGroups": [
                    {
                        "label": "Group 1",
                        "signers": [
                            {
                                "id": 0,
                                "name": "Adam",
                                "surname": "Smith",
                                "email": "adam.smith@email.com"
                            }
                        ]
                    }
                ],
                "extraData": {}
            }
        ],
        "status": "published",
        "expiresAt": "2030-04-25T12:00:00Z",
        "tags": None,
        "template": False,
        "publicTemplate": False,
        "ccGroups": None,
        "ccUsers": None,
        "urgent": False,
        "extraData": {
            "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
        }
    },
    "rolesMapping": [
        {
            "roleName": "Buyer",
            "signer": {
                "name": "Adam",
                "surname": "Smith",
                "email": "adam.smith@email.com",
                "phone": "+013392213450",
                "userUUID": "a845e772-cb45-466f-9c02-d9dd06afa36e"
            }
        }
    ]
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "domain": "bit4id",
  "title": "Real estate sales contract transaction",
  "documents": [
    {
      "id": 1,
      "plainDocumentUuid": "737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4",
      "forms": [
        {
          "id": 0,
          "documentId": 0,
          "type": "SignatureForm",
          "positionX": "100.00",
          "positionY": "58.14",
          "width": "10.1",
          "height": "5.66",
          "page": 1,
          "signerId": 0,
          "toFill": true,
          "filled": false,
          "invisible": true,
          "extraData": {
            "signatureRequestId": 0
          }
        }
      ],
      "signatureRequests": [
        {
          "id": 0,
          "reason": "As the Buyer",
          "description": "The proponent",
          "signerId": 0,
          "signProfile": "PAdES",
          "withTimestamp": true,
          "declinable": false,
          "restrictions": [
            {
              "rule": "",
              "operator": "",
              "value": ""
            }
          ],
          "extraData": {
            "st_ticketUrl": "http://signing.today/ticket/8bd4aead-ad37-42bc-b3b0-22ce3d1c9e79"
          }
        }
      ],
      "signerGroups": [
        {
          "label": "Group 1",
          "signers": [
            {
              "id": 0,
              "name": "Adam",
              "surname": "Smith",
              "email": "adam.smith@email.com"
            }
          ]
        }
      ],
      "extraData": {
        "additionalProperty": {}
      }
    }
  ],
  "resources": [
    {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    }
  ],
  "signatures": [
    {
      "documentId": 3,
      "signatureRequestId": 0,
      "signedAt": "2021-10-17T07:26Z",
      "declinedReason": "Reason of declination",
      "extraData": {
        "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
      }
    }
  ],
  "errorMessage": null,
  "tags": null,
  "template": false,
  "publicTemplate": false,
  "extraData": {
    "st_uuid": "d6ebb1ed-73a4-45ba-b33a-7db8a6cdd882"
  },
  "visibleTo": null,
  "ccGroups": null,
  "ccUsers": null,
  "urgent": false
}

The Services APIs set

The Services APIs set includes all the endpoints used as support for the other APIs. For example the APIs referring the authentication are into this set, as well as service resources or login/logout endpoints.

Get the bearer token

This API allows to get the token needed to access other APIs through the OAuth2 authentication.

  • parameters
  • usernamestring

    The username in the form username@domain where domain is the organization the user belongs to

  • passwordstring

    This is the actual password of the user

  • grant_typestring

    A parameter that indicates the type of the grant in order to perform the basic authentication

    • password
POST

/oauth/token

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/oauth/token' \
  -H 'Authorization: Basic Y2xpZW50OnNlY3JldA==' \
  -H 'Content-Type: multipart/form-data' \
  -f 'username=username@bit4id' \
  -f 'password=a12345678z' \
  -f 'grant_type=password'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/oauth/token");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Basic Y2xpZW50OnNlY3JldA==");
request.AddHeader("Content-Type", "multipart/form-data");
request.AlwaysMultipartFormData = true;
request.AddParameter("username", "username@bit4id");
request.AddParameter("password", "a12345678z");
request.AddParameter("grant_type", "password");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("multipart/form-data");
RequestBody body = new MultipartBody.Builder().setType(MultipartBody.FORM)
  .addFormDataPart("username", "username@bit4id")
  .addFormDataPart("password", "a12345678z")
  .addFormDataPart("grant_type", "password")
  .build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/oauth/token")
  .method("POST", body)
  .addHeader("Authorization", "Basic Y2xpZW50OnNlY3JldA==")
  .addHeader("Content-Type", "multipart/form-data")
  .build();
Response response = client.newCall(request).execute();
import requests
from requests_toolbelt.multipart.encoder import MultipartEncoder
url = "https://web.sandbox.signingtoday.com/api/oauth/token"
headers = {
    "Authorization": "Basic Y2xpZW50OnNlY3JldA=="
}
payload = MultipartEncoder(
    fields = {
        "username": "username@bit4id",
        "password": "a12345678z",
        "grant_type": "password"
})
headers["Content-Type"] = payload.content_type
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "access_token": "5c7fe85e-5ccd-4ae7-9629-ed49f969eee9",
  "token_type": "bearer",
  "refresh_token": "ef1185f4-2af7-4bf2-acd5-3c4b2e7dad72",
  "expires_in": 30623,
  "scope": "all"
}

Log out current user terminating the session

This API allows to Log out current user.

GET

/auth/logout

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/auth/logout' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/logout");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/logout")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/logout"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Return the current logged in user

This API allows to retrieve the current logged in user.

GET

/auth/user

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/auth/user' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/user");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/user")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/user"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "username": "jdo",
  "domain": "bit4id",
  "language": "en",
  "name": "John",
  "surname": "Doe",
  "email": "john.doe@email.com",
  "phone": "+013392213450",
  "role": "signer",
  "groups": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ],
  "capabilities": null,
  "extraData": {
    "additionalProperty": {}
  },
  "templateData": {
    "taxNumber": "RSSMRA30A01H501I"
  }
}

Request to recover own password

This API requests to recover the own password.

  • parameters
  • usernamequery parameter

    Username associated to the account

  • domainquery parameter

    Domain associated to the account

GET

/auth/passwordLost

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/auth/passwordLost?username=jdo&domain=demo' \
  
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/passwordLost?username=jdo&domain=demo");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/passwordLost?username=jdo&domain=demo")
  .method("GET", null)
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/passwordLost"
params = {
    "username": "jdo",
    "domain": "demo"
}
response = requests.get(
    url,
    params=params,
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Reset a user password with superuser

This API allows to reset the password of a user. This is possible when the request is performed with a superuser.

  • parameters
  • usernamequery parameter

    Username associated to the account

  • domainquery parameter

    Domain associated to the account

GET

/auth/passwordReset

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/auth/passwordReset?username=jdo&domain=demo' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/passwordReset?username=jdo&domain=demo");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/passwordReset?username=jdo&domain=demo")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/passwordReset"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "username": "jdo",
    "domain": "demo"
}
response = requests.get(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Reset your own password

This API allows to reset your own password knowing the previous one with a logged user.

  • parameters
  • currentPasswordstring

    The current password of the user

  • newPasswordstring

    The new password choosen

POST

/auth/passwordReset

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/auth/passwordReset' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "currentPassword": "a12345678Z",
  "newPassword": "0abcdefgH9"
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/passwordReset");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "currentPassword": "a12345678Z",
  "newPassword": "0abcdefgH9"
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "currentPassword": "a12345678Z",
  "newPassword": "0abcdefgH9"
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/passwordReset")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/passwordReset"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "currentPassword": "a12345678Z",
    "newPassword": "0abcdefgH9"
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Consume a token to change the password

This API allows to change the password by consuming a token.

  • parameters
  • passwordTokenquery parameter

    The password token issued to change password

  • Newpasswordstring

    New password associated to the account (BCrypt)

POST

/auth/changePassword

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/auth/changePassword?passwordToken=05ea656f-df69-49b1-a12b-9bf640c427c2' \
  -H 'Content-Type: text/plain' \
  -d '"A12345678z"'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/changePassword?passwordToken=05ea656f-df69-49b1-a12b-9bf640c427c2");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "text/plain");
request.AddParameter("text/plain", "\"A12345678z\"");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "\"A12345678z\"");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/changePassword?passwordToken=05ea656f-df69-49b1-a12b-9bf640c427c2")
  .method("POST", body)
  .addHeader("Content-Type", "text/plain")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/changePassword"
headers = {
    "Content-Type": "text/plain"
}
params = {
    "passwordToken": "05ea656f-df69-49b1-a12b-9bf640c427c2"
}
payload = "A12345678z"
response = requests.post(
    url,
    params=params,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Change the password of a service user

This API allows to change the password of a service user.

  • parameters
  • usernamequery parameter

    Username associated to the account

  • domainquery parameter

    Domain associated to the account

  • Newpasswordstring

    New password associated to the account (BCrypt)

POST

/service/changePassword

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/service/changePassword?username=jdo&domain=demo' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: text/plain' \
  -d '"A12345678z"'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/service/changePassword?username=jdo&domain=demo");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "text/plain");
request.AddParameter("text/plain", "\"A12345678z\"");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "\"A12345678z\"");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/service/changePassword?username=jdo&domain=demo")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "text/plain")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/service/changePassword"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "text/plain"
}
params = {
    "username": "jdo",
    "domain": "demo"
}
payload = "A12345678z"
response = requests.post(
    url,
    params=params,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Register or Update a SAML user

This API allows to register or update a SAML user.

  • parameters
  • domainstring

    SAML domain

  • IDToken1string

    The BASE64-encoded SAML Reply in JSON

  • IDToken2string

    The Hex-encoded HMAC-SHA256 of the decoded IDToken1

POST

/auth/saml

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/auth/saml' \
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -d 'domain=bit4id' \
  -d 'IDToken1=PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIElEPSJSZDkwYTY5NDg1YTdiMmMxYjM0NWFjOGQ1Y2UyZmExMzFkZmRkMzRlOSIgVmVyc2lvbj0iMi4wIiBJc3N1ZUluc3RhbnQ9IjIwMTYtMDMtMTdUMjI6NTA6MzBaIiBEZXN0aW5hdGlvbj0iaHR0cHM6Ly97c3ViZG9tYWlufS5mYWNlYm9vay5jb20vd29yay9zYW1sLnBocCI+P...' \
  -d 'IDToken2=f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/saml");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/x-www-form-urlencoded");
request.AddParameter("domain", "bit4id");
request.AddParameter("IDToken1", "PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIElEPSJSZDkwYTY5NDg1YTdiMmMxYjM0NWFjOGQ1Y2UyZmExMzFkZmRkMzRlOSIgVmVyc2lvbj0iMi4wIiBJc3N1ZUluc3RhbnQ9IjIwMTYtMDMtMTdUMjI6NTA6MzBaIiBEZXN0aW5hdGlvbj0iaHR0cHM6Ly97c3ViZG9tYWlufS5mYWNlYm9vay5jb20vd29yay9zYW1sLnBocCI+P...");
request.AddParameter("IDToken2", "f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/x-www-form-urlencoded");
RequestBody body = RequestBody.create(mediaType, "domain=bit4id&IDToken1=PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIElEPSJSZDkwYTY5NDg1YTdiMmMxYjM0NWFjOGQ1Y2UyZmExMzFkZmRkMzRlOSIgVmVyc2lvbj0iMi4wIiBJc3N1ZUluc3RhbnQ9IjIwMTYtMDMtMTdUMjI6NTA6MzBaIiBEZXN0aW5hdGlvbj0iaHR0cHM6Ly97c3ViZG9tYWlufS5mYWNlYm9vay5jb20vd29yay9zYW1sLnBocCI+P...&IDToken2=f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/saml")
  .method("POST", body)
  .addHeader("Content-Type", "application/x-www-form-urlencoded")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/saml"
headers = {
    "Content-Type": "application/x-www-form-urlencoded"
}
payload = {
    "domain": "bit4id",
    "IDToken1": "PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIElEPSJSZDkwYTY5NDg1YTdiMmMxYjM0NWFjOGQ1Y2UyZmExMzFkZmRkMzRlOSIgVmVyc2lvbj0iMi4wIiBJc3N1ZUluc3RhbnQ9IjIwMTYtMDMtMTdUMjI6NTA6MzBaIiBEZXN0aW5hdGlvbj0iaHR0cHM6Ly97c3ViZG9tYWlufS5mYWNlYm9vay5jb20vd29yay9zYW1sLnBocCI+P...",
    "IDToken2": "f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8"
}
response = requests.post(
    url,
    data=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
303

Response

Redirect to frontend page with new auth token (Post/Redirect/Get design pattern).

Get token to change password

This API allows to get a password token to use in order to change a password.

GET

/auth/passwordToken

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/auth/passwordToken' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/auth/passwordToken");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/auth/passwordToken")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/auth/passwordToken"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

[
  "a9851478-7fe3-4d67-bcbc-1ba30581fab3"
]

Retrieve a Resource (of service)

This API allows to extract thumbnails from a PDF Resource.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • pagequery parameter

    The page to retrieve

  • widthquery parameter

    The output image width

GET

/pdfResource/{id}/thumbs

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/pdfResource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/thumbs?page=1' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/pdfResource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/thumbs?page=1");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/pdfResource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/thumbs?page=1")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/pdfResource/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/thumbs"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "page": 1
}
response = requests.get(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

The output is a raw string. The thumbnails of the page requested for the PDF resource.

Retrieve the App configuration

This API allows to get the public configuration associated to the application.

GET

/service/configuration

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/service/configuration' \
  
var client = new RestClient("https://web.sandbox.signingtoday.com/api/service/configuration");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/service/configuration")
  .method("GET", null)
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/service/configuration"
response = requests.get(
    url,
)
print(response.text.encode("utf-8"))
200

Response

{}

The User model

The User object is the one that serializes the users of the Organizations. The User has field that identifies the generality of the person who has been registered and uses the platform, as well as the digital identities through which he can sign documents.

  • attributes
  • idstringuuid

    The unique id of the User

  • usernamestringany

    The username of the User. The username is used to login

  • domainstringany

    The domain is the Organization which a user or a DST belongs

  • languagestring

    The default language of the User

    • it
    • en
    • es
    • fr
  • namestringany

    The name of the User

  • surnamestringany

    The name of the User

  • emailstringemail

    The email address of the User

  • phonestringnumber

    The phone number of the User

  • rolestring

    The role of the User. The admin can create users, as well as DSTs and can sign. The instructor can create DSTs and sign. The signer can only sign documents.

    • admin
    • instructor
    • signer
  • groupsarray

    A group of users. This is useful during DSTs creation, it is possible to select a group as signers. This way all the components of that group have to sign the document

    • idint64

      Unique id of the Group

    • nameany

      Name of the Group

    • domainany

      Organization which the Group belongs

  • capabilitiesarray

    The capabilities represents the action a user is able to do

    • user.pwd.clear
    • user.create.all
    • user.access.all
    • user.delete.all
    • dst.list.all
    • dst.delete.all
    • dst.create.modify_all
    • devices.list.all
    • devices.delete.all
    • organizations.access.write.user
  • createdBystringuuid

    The one which created the User

  • createdAtstringdate-time

    The date of the creation of the User

  • deletedAtstringdate-time

    The date of deletion of the User

  • automaticboolean

    If true the user is automatic

  • extraDataobject

    Extra data associated to the User

  • templateDataobject

    Additional user data in json serialized format

Retrieve Users

This allows to get the list of the Users of an Organization.

  • parameters
  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

  • $orderByquery parameter

    An ordering definition (eg. $orderBy=updatedAt,desc)

  • $filterquery parameter

    A filter definition (eg. $filter=name == "Milk" or surname == "Bread")

GET

/users

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/users' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/users");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/users")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/users"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "count": 1,
  "values": [
    {
      "username": "jdo",
      "domain": "bit4id",
      "language": "en",
      "name": "John",
      "surname": "Doe",
      "email": "john.doe@email.com",
      "phone": "+013392213450",
      "role": "signer",
      "groups": [
        {
          "name": "Marketing BU",
          "domain": "bit4id"
        }
      ],
      "capabilities": null,
      "extraData": {
        "additionalProperty": {}
      },
      "templateData": {
        "taxNumber": "RSSMRA30A01H501I"
      }
    }
  ]
}

Create a new User

This API allows to create a new User.

  • parameters
  • userobject

    The User object is the one that serializes the users of the Organizations. The User has field that identifies the generality of the person who has been registered and uses the platform, as well as the digital identities through which he can sign documents.

    • iduuid

      The unique id of the User

    • usernameany

      The username of the User. The username is used to login

    • domainany

      The domain is the Organization which a user or a DST belongs

    • languagestring

      The default language of the User

    • nameany

      The name of the User

    • surnameany

      The name of the User

    • emailemail

      The email address of the User

    • phonenumber

      The phone number of the User

    • roleany

      The role of the User. The admin can create users, as well as DSTs and can sign. The instructor can create DSTs and sign. The signer can only sign documents.<br>

    • groupsarray

      A group of users. This is useful during DSTs creation, it is possible to select a group as signers. This way all the components of that group have to sign the document

    • capabilitiesarray

      The capabilities represents the action a user is able to do

    • createdByuuid

      The one which created the User

    • createdAtdate-time

      The date of the creation of the User

    • deletedAtdate-time

      The date of deletion of the User

    • automaticNone

      If true the user is automatic

    • extraDataobject

      Extra data associated to the User

    • templateDataNone

      Additional user data in json serialized format

  • passwordstring

    This represents the password the user will use to login from the web interface. If the field is omitted the email address provided during the creation of the user will receive an email with a link from where will be possible to set a password

POST

/users

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/users' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "user": {
    "username": "jdo",
    "domain": "bit4id",
    "language": "en",
    "name": "John",
    "surname": "Doe",
    "email": "john.doe@email.com",
    "phone": "+013392213450",
    "role": "signer",
    "groups": [
      {
        "name": "Marketing BU",
        "domain": "bit4id"
      }
    ],
    "capabilities": null,
    "extraData": {
      "additionalProperty": {}
    },
    "templateData": {
      "taxNumber": "RSSMRA30A01H501I"
    }
  },
  "password": "A12345678z"
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/users");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "user": {
    "username": "jdo",
    "domain": "bit4id",
    "language": "en",
    "name": "John",
    "surname": "Doe",
    "email": "john.doe@email.com",
    "phone": "+013392213450",
    "role": "signer",
    "groups": [
      {
        "name": "Marketing BU",
        "domain": "bit4id"
      }
    ],
    "capabilities": null,
    "extraData": {
      "additionalProperty": {}
    },
    "templateData": {
      "taxNumber": "RSSMRA30A01H501I"
    }
  },
  "password": "A12345678z"
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "user": {
    "username": "jdo",
    "domain": "bit4id",
    "language": "en",
    "name": "John",
    "surname": "Doe",
    "email": "john.doe@email.com",
    "phone": "+013392213450",
    "role": "signer",
    "groups": [
      {
        "name": "Marketing BU",
        "domain": "bit4id"
      }
    ],
    "capabilities": null,
    "extraData": {
      "additionalProperty": {}
    },
    "templateData": {
      "taxNumber": "RSSMRA30A01H501I"
    }
  },
  "password": "A12345678z"
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/users")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/users"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "user": {
        "username": "jdo",
        "domain": "bit4id",
        "language": "en",
        "name": "John",
        "surname": "Doe",
        "email": "john.doe@email.com",
        "phone": "+013392213450",
        "role": "signer",
        "groups": [
            {
                "name": "Marketing BU",
                "domain": "bit4id"
            }
        ],
        "capabilities": None,
        "extraData": {
            "additionalProperty": {}
        },
        "templateData": {
            "taxNumber": "RSSMRA30A01H501I"
        }
    },
    "password": "A12345678z"
}
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
201

Response

[
  "7e49d963-544e-407e-ba57-049785ef3760"
]

Retrieve UserGroups

This API allows to get the list of the UserGroups.

  • parameters
  • $topquery parameter

    A number of results to return. Applied after $skip

  • $skipquery parameter

    An offset into the collection of results

  • $countquery parameter

    If true, the server includes the count of all the items in the response

  • $orderByquery parameter

    An ordering definition (eg. $orderBy=updatedAt,desc)

  • $filterquery parameter

    A filter definition (eg. $filter=name == "Milk" or surname == "Bread")

GET

/users/groups

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/users/groups' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/users/groups");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/users/groups")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/users/groups"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "count": 1,
  "values": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ]
}

Create a new UserGroups

This API allows to create a new UserGroups.

  • parameters
  • idinteger

    Unique id of the Group

  • namestring

    Name of the Group

  • domainstring

    Organization which the Group belongs

POST

/users/groups

Click to copy
curl -L -X POST \
  'https://web.sandbox.signingtoday.com/api/users/groups' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '[
  {
    "name": "Marketing BU",
    "domain": "bit4id"
  }
]'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/users/groups");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "[
  {
    "name": "Marketing BU",
    "domain": "bit4id"
  }
]", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "[
  {
    "name": "Marketing BU",
    "domain": "bit4id"
  }
]");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/users/groups")
  .method("POST", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/users/groups"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = [
    {
        "name": "Marketing BU",
        "domain": "bit4id"
    }
]
response = requests.post(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Retrieve a User

This API allows to retrieve a User.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/user/{id}

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

{
  "username": "jdo",
  "domain": "bit4id",
  "language": "en",
  "name": "John",
  "surname": "Doe",
  "email": "john.doe@email.com",
  "phone": "+013392213450",
  "role": "signer",
  "groups": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ],
  "capabilities": null,
  "extraData": {
    "additionalProperty": {}
  },
  "templateData": {
    "taxNumber": "RSSMRA30A01H501I"
  }
}

Update a User

This API allows to update a User.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • idstring

    The unique id of the User

  • usernamestring

    The username of the User. The username is used to login

  • domainstring

    The domain is the Organization which a user or a DST belongs

  • languagestring

    The default language of the User

    • it
    • en
    • es
    • fr
  • namestring

    The name of the User

  • surnamestring

    The name of the User

  • emailstring

    The email address of the User

  • phonestring

    The phone number of the User

  • rolestring

    The role of the User. The admin can create users, as well as DSTs and can sign. The instructor can create DSTs and sign. The signer can only sign documents.

    • admin
    • instructor
    • signer
  • groupsarray

    A group of users. This is useful during DSTs creation, it is possible to select a group as signers. This way all the components of that group have to sign the document

    • idint64

      Unique id of the Group

    • nameany

      Name of the Group

    • domainany

      Organization which the Group belongs

  • capabilitiesarray

    The capabilities represents the action a user is able to do

    • user.pwd.clear
    • user.create.all
    • user.access.all
    • user.delete.all
    • dst.list.all
    • dst.delete.all
    • dst.create.modify_all
    • devices.list.all
    • devices.delete.all
    • organizations.access.write.user
  • createdBystring

    The one which created the User

  • createdAtstring

    The date of the creation of the User

  • deletedAtstring

    The date of deletion of the User

  • automaticboolean

    If true the user is automatic

  • extraDataobject

    Extra data associated to the User

  • templateDataobject

    Additional user data in json serialized format

PUT

/user/{id}

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' \
  -H 'Content-Type: application/json' \
  -d '{
  "username": "jdo",
  "domain": "bit4id",
  "language": "en",
  "name": "John",
  "surname": "Doe",
  "email": "john.doe@email.com",
  "phone": "+013392213450",
  "role": "signer",
  "groups": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ],
  "capabilities": null,
  "extraData": {
    "additionalProperty": {}
  },
  "templateData": {
    "taxNumber": "RSSMRA30A01H501I"
  }
}'
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{
  "username": "jdo",
  "domain": "bit4id",
  "language": "en",
  "name": "John",
  "surname": "Doe",
  "email": "john.doe@email.com",
  "phone": "+013392213450",
  "role": "signer",
  "groups": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ],
  "capabilities": null,
  "extraData": {
    "additionalProperty": {}
  },
  "templateData": {
    "taxNumber": "RSSMRA30A01H501I"
  }
}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{
  "username": "jdo",
  "domain": "bit4id",
  "language": "en",
  "name": "John",
  "surname": "Doe",
  "email": "john.doe@email.com",
  "phone": "+013392213450",
  "role": "signer",
  "groups": [
    {
      "name": "Marketing BU",
      "domain": "bit4id"
    }
  ],
  "capabilities": null,
  "extraData": {
    "additionalProperty": {}
  },
  "templateData": {
    "taxNumber": "RSSMRA30A01H501I"
  }
}");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e",
    "Content-Type": "application/json"
}
payload = {
    "username": "jdo",
    "domain": "bit4id",
    "language": "en",
    "name": "John",
    "surname": "Doe",
    "email": "john.doe@email.com",
    "phone": "+013392213450",
    "role": "signer",
    "groups": [
        {
            "name": "Marketing BU",
            "domain": "bit4id"
        }
    ],
    "capabilities": None,
    "extraData": {
        "additionalProperty": {}
    },
    "templateData": {
        "taxNumber": "RSSMRA30A01H501I"
    }
}
response = requests.put(
    url,
    json=payload,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Enable or disable a User

This API allows to enable or disable a User account.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • enabledquery parameter

    This is a boolean parameter. If true the User is enabled

DELETE

/user/{id}

Click to copy
curl -L -X DELETE \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4")
  .method("DELETE", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.delete(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Change the User role

This API allows to change the permissions associated to the users, (capabilities) according to predefined user roles.

  • parameters
  • idpath parameterstring

    The value of the unique id

  • newRolequery parameter

    The new role of the User. Allowed values are admin, instructor, signer

PUT

/user/{id}/role

Click to copy
curl -L -X PUT \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/role?newRole=instructor' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/role?newRole=instructor");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/role?newRole=instructor")
  .method("PUT", body)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/role"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
params = {
    "newRole": "instructor"
}
response = requests.put(
    url,
    params=params,
    headers=headers
)
print(response.text.encode("utf-8"))
204

Response

The request has been satisfyied. No output.

Retrieve User identities

This API allows to retrieve user identities.

  • parameters
  • idpath parameterstring

    The value of the unique id

GET

/user/{id}/identities

Click to copy
curl -L -X GET \
  'https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identities' \
  -H 'Authorization: Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e' 
var client = new RestClient("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identities");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
OkHttpClient client = new OkHttpClient.newBuilder().build();
Request request = new Request.Builder()
  .url("https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identities")
  .method("GET", null)
  .addHeader("Authorization", "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e")
  .build();
Response response = client.newCall(request).execute();
import requests
url = "https://web.sandbox.signingtoday.com/api/user/737dc132-a3f0-11e9-a2a3-2a2ae2dbcce4/identities"
headers = {
    "Authorization": "Bearer 607a3bbc-b5e5-42c4-9b3c-533372ac1d3e"
}
response = requests.get(
    url,
    headers=headers
)
print(response.text.encode("utf-8"))
200

Response

[
  {
    "id": "abd562ae-e8ab-4cfd-a688-395e06eea9ff",
    "provider": "Approval Signing Today",
    "label": "Token John Doe",
    "providerType": "token",
    "subjectCommonName": "John Doe",
    "issuerCommonName": "Emicert",
    "expireDate": "2022-12-13T23:59:59Z",
    "rawCertificate": null,
    "appearance": {
      "id": "05a80817-a3a5-48fe-83c0-0df0f48a2a26",
      "domain": "bit4id",
      "title": "Sales Contract",
      "filename": "contract.pdf",
      "pages": 3,
      "extraData": {
        "toSign": true
      }
    },
    "providerData": {
      "smartcardID": -1121978858,
      "middlewareID": "bit4xpki",
      "ATR": "3bff1800008131fe55006b02090403010101434e5310318065",
      "tokenInfo": {
        "ulMinPinLen": 4,
        "manufacturerID": "Bit4id",
        "ulFreePublicMemory": 41168,
        "serialNumber": "7430010005961358",
        "ulTotalPublicMemory": 80000,
        "label": "CNS",
        "flags": 1037,
        "ulTotalPrivateMemory": 80000,
        "model": "JS2048 (LB)",
        "ulFreePrivateMemory": 41168,
        "ulMaxPinLen": 8
      },
      "reader": "Generic Smart Card Reader Interface 0"
    },
    "valid": true,
    "tags": null
  }
]