Getting started


Introduction

Dokobit WS API is RESTful, which means:

  • Uses resource-oriented URLs
  • Uses GET and POST methods to perform actions on resources
  • Responds with standard HTTP response codes
  • Returns JSON

Access Token is required to test the methods in our sandbox. Request access token. Once you have the Token please enter it at the top right corner of the page.

Terms of service

By using the Dokobit test environment, you confirm that you agree to the Dokobit Terms of Service and ensure that only test data will be used in the test environment.


Key Terms

Term Description
API access token Unique secret string issued by Dokobit, so you can access our API.
Mobile ID Electronic qualified signature stored on the SIM card
Smart Card Electronic qualified signature stored on the SmartCard (USB token, Identity card). Also known as stationary e-signature.
Session token Unique string issued during signing or login process, used to check whether the process succeeded.
Verification code The code displayed on screen of the device when signing / identification process is initiated.

API Endpoints

Endpoint URL
Sandbox https://developers.dokobit.com
Live https://ws.dokobit.com

Code Examples

Dokobit team has prepared basic API usage examples in .NET C#, Java, PHP languages and even more could be found at our GitHub.


Limits

Service allows to sign documents up to 300MB. Please contact us if you have a need to sign larger files.


Status codes

Dokobit API returns standard HTTP response codes:

Status Code Description
200 Success! Everything worked as expected.
400 Bad Request - often indicates missing required parameter or invalid data in the request.
403 Forbidden - invalid access token provided.
404 Not Found - requested resource could not be found.
500 Server Error - something went wrong on our side.
504 Timeout - service went into timeout while processing request.

If there was an error in the API call, response body is accompanied by the message explaining the error.

Testing data

You can find Mobile ID and Smart-ID test data here.

Example Data

If you want to test sandbox right away, here is demo data, which is available for autocompleting also.

Demo file
Demo file digest (SHA256) 6256a099cd2a3d3606acc86e7eacbdcf4cd067db3a1d46930d77886d96fd226e
E-signature login certificate (PEM) dokobit_dev_login.pem
E-signature login private key dokobit_dev_login_key.pem
E-signature login certificate (base64)
LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVCakNDQXU2Z0F3SUJBZ0lCQVRBTkJna3Foa2lHOXcwQkFRVUZBRENCbHpFTE1Ba0dBMVVFQmhNQ1RGUXgKRURBT0JnTlZCQWdNQjFacGJHNXBkWE14RURBT0JnTlZCQWNNQjFacGJHNX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0RUZnUVVETTVUUWMvdApRL0RhSU9rZ2xHNzZCR052OU8wd0h3WURWUjBqQkJnd0ZvQVVGKzFkQkkrbkQwRncyUHowSTkycjNwa0VHV013CkVBWUlLd1lCQlFVSEFRTUVCQUVDQXdRd0V3WURWUjBsQkF3d0NnWUlLd1lCQlFVSEF3SXdEUVlKS29aSWh2Y04KQVFFRkJRQURnZ0VCQUlodG1uU0lOcG5za2g4MGFJN0Q5ZzBRblhCdmU3NWxPdTNIUW9mMW13TGJHMC9YcisyVwoxUnEwVS9USWFFUDR5WU1MOVNpQ1hkMVdhaDBIK3NzRy9DUnBkQ29qdVFhVkN0Q2c1dGNKdVBmdVNId1FtelNDCitkbW5BKzB0VE8rUXFhR1lwbU5JWWI1cnl1RVIrQ2ZCejNWQWVJVEZEVTIycEZBVVdOWVdsK29oWmdBNGlLb2IKakJtblVNbExTUnFIcnhGcTRYVElOb0t1WlpWLytBU3VrM3ROSEpmckkyRm50cm1GdWk1U2VmSlNNZ2VCMUJmYwpnWldPL2VhSFgyRFVMNHByWHQ0bWNRUHh1bmtOcjZCRGJEOEE4NENoazV6WHVrdTgxYVdXNjMzaTV4QU42R3NFCjhuVUtrZitjUnNxc2pBWkd2QXRaMC9GWC93WEpBU0tnVEtvPQotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0t
E-signature signing certificate (PEM) dokobit_dev_sign.pem
E-signature signing private key dokobit_dev_sign_key.pem
E-signature signing certificate (base64)
LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVDekNDQXZPZ0F3SUJBZ0lCQWpBTkJna3Foa2lHOXcwQkFRVUZBRENCbHpFTE1Ba0dBMVVFQmhNQ1RGUXgKRURBT0JnTlZCQWdNQjFacGJHNXBkWE14RURBT0JnTlZCQWNNQjFacGJHNXBkWE14RGpBTUJnTlZCQW9NQldsVAphV2R1TVJZd0ZBWURWUVFMREExcFUybG5iaUJUWVc1a1ltOTRNUjR3SEFZRFZRUUREQlZwVTJsbmJpQ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kdXTXdFQVlJS3dZQkJRVUhBUU1FQkFFQ0F3UXdGUVlEVlIwbEJBNHdEQVlLS3dZQkJBR0NOd29ERERBTkJna3EKaGtpRzl3MEJBUVVGQUFPQ0FRRUFRYVRyV0dDU0xZUzlrcHRnSXByQkpwMldEMG9pZGk0UGVacnJyaDQzazhCcQpXNmNxQzdJRmtuWmgxejRvQ3VNbXFwemhQVWVjRVRHSzVHNVZBTDU1MjVrdDd4R0FKVjNONmwvTm5OWFVJNFpCCjdjQ052MzB1ZDA2a3A0Rkg4UVZVaENvc0lORTloVHVaNTdFRmtZZ25sRDdDYlZWU2pLNVZXRDVSdTVSdENmdlEKQXFMQk5UbTVISmIrcnJzWDRXZXR2SFVlYkdyMVl4LzlKS0VXaU1SUndnUGN2YkYzcFpYbVVPV3k3VVhrYmdHdApOTUNvM0lBWUt1NkpiRWNhZ0xxbjFneHp5bjVvMU45SGNlU0kzUW8wVzNmS244ZWlZWFBOVWJPbE1yR3ZzZVEvCklKVkRCbVg3SmJNRmx1OVdnZDBlQ2dMWTdhWnU1TnVqVnJ4MEUwTXF5dz09Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0=

1. Identification with Mobile ID

Set of API methods used to perform user authentication with Mobile ID.

Login

POST /v2/mobile/login.json

This API method initializes and performs the identification process with Mobile ID, returns a session token for status checking and control code which has to be displayed to the user.

When a login.json request is received, instructions are sent to the user’s phone, triggering the authentication process. If the user enters the PIN correctly, authentication succeeds, and the API server receives a response from the user’s device. The process may take a while, so you’ll need to call the Mobile ID Login Status API method every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
phone string +37200000766 Phone number.
code string 60001019906 Personal code (not required for Icelandic users).

Optional params

Name Type Required Description
language string false Language for messages displayed on the phone screen. Possible values: LT, ET, IS, EN, RU.
message string false Message displayed on the phone screen.

Requirements

Parameters

Content
Replaces header if set

{
   "status": "ok",
   "token": "b9485f4b-18a7-44b1-bf0b-236325542975",
   "control_code": "3729"
}

Login Status

GET /v2/mobile/login/status/{token}.json

Checks the status of login session. Status field has value of “ok” - on success, “waiting” - when process is pending or “error” when process has timed out or has been canceled.

Required params

Name Type Example Description
token string b9485f4b-18a7-44b1-bf0b-236325542975 Token received from /v2/mobile/login call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
   "status": "ok",
   "name": "MARY ÄNN",
   "surname": "O’CONNEŽ-ŠUSLIK TESTNUMBER",
   "code": "60001019906",
   "country": "EE",
   "certificate": {
     "name": "/C=EE/O=ESTEID (MOBIIL-ID)/OU=authentication/CN=O\\xE2\\x80\\x99CONNE\\xC5\\xBD-\\xC5\\xA0USLIK TESTNUMBER,MARY \\xC3\\x84NN,60001019906/SN=O\\xE2\\x80\\x99CONNE\\xC5\\xBD-\\xC5\\xA0USLIK TESTNUMBER/GN=MARY \\xC3\\x84NN/serialNumber=60001019906",
     "subject": {
       "country": "EE",
       "organisation": "ESTEID (MOBIIL-ID)",
       "organisation_unit": "authentication",
       "common_name": "O’CONNEŽ-ŠUSLIK TESTNUMBER,MARY ÄNN,60001019906",
       "surname": "O’CONNEŽ-ŠUSLIK TESTNUMBER",
       "name": "MARY ÄNN",
       "serial_number": "60001019906"
     },
     "issuer": {
       "country": "EE",
       "organisation": "AS Sertifitseerimiskeskus",
       "common_name": "TEST of ESTEID-SK 2015"
     },
     "valid_from": "2018-08-09T14:20:27+00:00",
     "valid_to": "2022-12-11T21:59:59+00:00",
     "value": "Base64 encoded PEM certificate"
   }
}

2. Identification with Smart-ID

Login

POST /smartid/login.json

This API method initializes and performs the identification process with Smart-ID, returns a session token for status checking and control code which has to be displayed to the user.

When a login.json request is received, instructions are sent to the user’s phone, triggering the authentication process. If the user enters the PIN correctly, authentication succeeds, and the API server receives a response from the user’s device. The process may take a while, so you’ll need to call the Smart-ID Login Status API method every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
code string 30303039914 Personal code.
country string LT Country related to personal code. Possible values: LT, LV, EE.

Optional params

Name Type Required Description
message string false Message displayed in Smart-ID application.
confirmationMessage string false Message displayed in Smart-ID application and shown in confirmation modal.

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "token": "7823efe6-7ca5-413e-bbde-286654768150",
    "control_code": "4001",
}

Login Status

GET /smartid/login/status/{token}.json

Checks the status of login session. Status field has possible values: “ok” - when login is successful, “waiting” - when login process is in progress or “canceled” - when process was canceled by user. If session timesout, you will receive status with value “error” and error_code “6005”.

Required params

Name Type Example Description
token string 7823efe6-7ca5-413e-bbde-286654768150 Token received from /smartid/login call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "canceled"
}

or

{
  "status": "ok",
  "name": "DEMO",
  "surname": "SMART-ID",
  "code": "30303039914",
  "country": "LT",
  "certificate": {
    "name": "/OU=AUTHENTICATION/CN=SMART-ID,DEMO,PNOLT-30303039914/serialNumber=PNOLT-30303039914/GN=DEMO/SN=SMART-ID/C=LT",
    "subject": {
      "organisation_unit": "AUTHENTICATION",
      "common_name": "SMART-ID,DEMO,PNOLT-30303039914",
      "serial_number": "PNOLT-30303039914",
      "name": "DEMO",
      "surname": "SMART-ID",
      "country": "LT"
    },
    "issuer": {
      "country": "EE",
      "organisation": "AS Sertifitseerimiskeskus",
      "common_name": "TEST of EID-SK 2016"
    },
    "valid_from": "2019-03-12T17:55:18+02:00",
    "valid_to": "2030-12-18T01:59:59+02:00",
    "value": "Base64 encoded PEM certificate"
  }
}

3. Identification with Audkenni App

Login

POST /audkenniapp/login.json

This API method initializes and performs the identification process with Audkenni App, returns a session token for status checking and control code which has to be displayed to the user.

When a login.json request is received, instructions are sent to the user’s phone, triggering the authentication process. If the user enters the PIN correctly, authentication succeeds, and the API server receives a response from the user’s device. The process may take a while, so you’ll need to call the Audkenni App Login Status API method every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
code string 30303039914 Personal code.

Optional params

Name Type Required Description
message string false Message displayed in Audkenni App application.

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "token": "jMSmSNzBEEdyL5BjIy8PRYNs10g",
    "control_code": "4255"
}

Login Status

GET /audkenniapp/login/status/{token}.json

Checks the status of login session. Status field has possible values: “ok” - when login is successful, “waiting” - when login process is in progress or “canceled” - when process was canceled by user. If session timesout, you will receive status with value “error” and error_code “6005”.

Required params

Name Type Example Description
token string 4gkpy8gCJbQemIQs9_nEE9-A4CY Token received from /audkenniapp/login call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}
or

{
    "status": "canceled"
}
or

{
  "status": "ok",
  "name": "Gervimaður",
  "surname": "Eyjaálfa",
  "code": "0101304339",
  "country": "IS",
  "certificate": {
    "name": "/C=IS/CN=Gervima\\xC3\\xB0ur Eyja\\xC3\\xA1lfa/SN=Eyja\\xC3\\xA1lfa/GN=Gervima\\xC3\\xB0ur/serialNumber=0101304339",
    "subject": {
      "country": "IS",
      "common_name": "Gervimaður Eyjaálfa",
      "surname": "Eyjaálfa",
      "name": "Gervimaður",
      "serial_number": "0101304339"
    },
    "issuer": {
      "country": "IS",
      "organisation": "Auðkenni test ehf",
      "common_name": "Fullgilt audkenni Test",
      "serial_number": "5210002790"
    },
    "valid_from": "2021-07-01T11:59:02+03:00",
    "valid_to": "2026-07-01T11:59:02+03:00",
    "value": "LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUlZVENDQmttZ0F3SUJBZ0lRU1lTNFY4RWZRYVA0UlZJSy9kQ0QvVEFOQmdrcWhraUc5dzBCQVFzRkFEQjcKTVFzd0NRWURWUVFHRXdKSlV6RWJNQmtHQTFVRUNnd1NRWFhEc0d0bGJtNXBJSFJsYzNRZ1pXaG1NUmt3RndZRApWUVJoRXhCT1ZGSkpVejAxTWpFd01EQXlOemt3TVI4d0hRWURWUVFERXhaR2RXeHNaMmxzZENCaG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p3dHpDOUttWUx0alpKeVh6dGdpblp1VXpudGNVTkpTd1FjSktkRHZoYmFYaVFHVXVoejZ3SEU4SnQKQ3lIbUFZVFFINjVmbVZDb1pxQUdWU1NMclZjQWdWaFEwYjcvcXBpU0Vud285NmptL0ExZktWZGVZQkl2MHc1MApHditvcWpiVFdWTDEzY0J2VXVjUEV1UTBnazhubUcrQ3R0T1BVQ0xveVo4anE2QXFJMklHZlVkQkVtQTJGMXRlCklNNWJrVXRaVlZIazVDUWVyM1UvYlpicW9pMjcyU3VZeDR3TE5DSmlGY2hhUGNQemdrTkJobDByYkcyZ2h6VjcKQk5rcHg1Q3lCbUdCeUd2TjhFVUZTUVh4YzhLR3hTSCt3M2xOcXY0WjU2L2ltcURIdEw1S1MwRTNlT1FwSW41YwpGeXV5R1NPMnVwSUV3NjB3b01vZzM2eTU5M0p1U3pHMUpnNk83Wk9hcWFOMDBPSFJ2UT09Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0="
  }
}

4. Document Signing with Mobile ID

Methods for signing documents with qualified electronic signature stored on SIM card (Mobile ID).

Sign

POST /mobile/sign.json

This API method initiates the document signing process with Mobile ID. Returns session token and verification code to be displayed to the user. The list of required parameters varies by document format. You will find both common parameters (parameters that you need to send regardless of the document format) and format-specific parameters in the tables below.

To determine the result of the initiated signing process, you need to call the Mobile ID Signing Status API method periodically every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
type string pdf Document format. Possible values: pdf, pdflt, adoc, adoc.cedoc, adoc.bedoc, adoc.gedoc, adoc.ggedoc, mdoc, mdoc.cedoc, mdoc.bedoc, mdoc.gedoc, mdoc.ggedoc, bdoc, edoc, asice.
phone string +37200000766 Phone number.
message string Signing of Agreement No. 123456. Message displayed on screen. Attention: UTF-8 symbols are not allowed.
timestamp boolean true Timestamp.
language string EN Language for messages displayed on the phone screen. Possible values: LT, ET, IS, EN, RU.
code string 60001019906 Personal code (required for Estonian and Lithuanian Mobile-ID users).

Optional params

Name Type Required Description
return_document_structure boolean false Set if status method should return document structure (default: false)
pdf[files][0][name] string true File name (required for PDF signing)
pdf[files][0][content] string true Base64 encoded file content (required for PDF signing)
pdf[files][0][digest] string true SHA256 checksum of file content (required for PDF signing)
pdf[contact] string true Full name (required for PDF signing)
pdf[signing_purpose] string false Possible values: signature, registration. Default: signature.
pdf[reason] string false Text that will be displayed in visible signature. (Additional parameters: %personal_code%)
pdf[location] string true Signing location (required for PDF signing). Example: Vilnius
pdf[annotation][page] string false Page index for visible signature. Default: 1
pdf[annotation][top] string false Visible signature position from top. Default: 1
pdf[annotation][left] string false Visible signature position from left. Default: 1
pdf[annotation][width] string false Visible signature width. Default: 100
pdf[annotation][height] string false Visible signature height. Default: 40
pdf[annotation][text] string false Custom text for visible signature. Example: Signature: Jonas Jonaitis
pdf[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdf[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
pdf[attachments][0][name] string true File name
pdf[attachments][0][content] string true Base64 encoded file content
pdf[attachments][0][digest] string true SHA256 checksum of file content
pdf[attachments][0][description] string false Description of attachment file
pdflt[files][0][name] string true File name (required for PDF-LT signing)
pdflt[files][0][content] string true Base64 encoded file content (required for PDF-LT signing)
pdflt[files][0][digest] string true SHA256 checksum of file content (required for PDF-LT signing)
pdflt[compliance_level] string false A|B (Required if not already set in document)
pdflt[titles][0][name] string false Document title (Required if not already set in document)
pdflt[titles][0][language] string false Title language (ex. lt-LT, required if not already set in document)
pdflt[authors][0][name] string false Author's full name or company name (Required if not already set in document)
pdflt[authors][0][code] string false Personal code or company code
pdflt[authors][0][address] string false 1428 Elm Street
pdflt[authors][0][email] string false E-mail of person or company
pdflt[authors][0][individual] boolean false true or false (Required if not already set in document)
pdflt[contact] string true Signer's full name (required for PDF-LT signing)
pdflt[reason] string false Text that will be displayed in visible signature
pdflt[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, resolution, end-of-execution, notarisation, copy-certification, authenticity
pdflt[location] string false Signing location. Example: Vilnius
pdflt[role] string false Signer role. Example: Manager
pdflt[note] string false Additional note about signing. Example. visa note
pdflt[signer_registration][date] string false Signer registration date. Example: 2012-01-01T12:12:12Z
pdflt[signer_registration][number] string false Signer registration number
pdflt[signer_registration][code] string false Signer registration code
pdflt[signer_reception][date] string false Signer reception date. Example: 2012-01-01T12:12:12Z
pdflt[signer_reception][number] string false Signer reception number
pdflt[signer_reception][code] string false Signer reception code
pdflt[signer_reception][receiver][name] string false Receiver's full name or company name (must be specified for reception)
pdflt[signer_reception][receiver][code] string false Personal code or company code
pdflt[signer_reception][receiver][address] string false 1428 Elm Street
pdflt[signer_reception][receiver][email] string false E-mail of person or company
pdflt[signer_reception][receiver][individual] boolean false true or false
pdflt[recipients][0][name] string false Recipient's full name or company name
pdflt[recipients][0][code] string false Personal code or company code
pdflt[recipients][0][address] string false 1428 Elm Street
pdflt[recipients][0][email] string false E-mail of person or company
pdflt[recipients][0][individual] boolean false true or false
pdflt[original_registrations][0][date] string false Original registration date. Example: 2012-01-01T12:12:12Z
pdflt[original_registrations][0][number] string false Original registration number
pdflt[original_registrations][0][code] string false Original registration code
pdflt[original_receptions][0][date] string false Original reception date. Example: 2012-01-01T12:12:12Z
pdflt[original_receptions][0][number] string false Original reception number
pdflt[original_receptions][0][code] string false Original reception code
pdflt[original_receivers][0][name] string false Receiver's full name or company name
pdflt[original_receivers][0][code] string false Personal code or company code
pdflt[original_receivers][0][address] string false 1428 Elm Street
pdflt[original_receivers][0][email] string false E-mail of person or company
pdflt[original_receivers][0][individual] boolean false true or false
pdflt[instance_identifier] string false Document instance identifier
pdflt[annotation][page] string false Page index for visible signature. Default: 1
pdflt[annotation][top] string false Visible signature position from top. Default: 1
pdflt[annotation][left] string false Visible signature position from left. Default: 1
pdflt[annotation][width] string false Visible signature width. Default: 100
pdflt[annotation][height] string false Visible signature height. Default: 40
pdflt[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdflt[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdflt[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
adoc[files][0][name] string true File name (required for ADoc signing)
adoc[files][0][content] string true Base64 encoded file content (required for ADoc signing)
adoc[files][0][digest] string true SHA256 checksum of file content (required for ADoc signing)
adoc[files][0][type] string true Possible values: main, appendix, attachment
adoc[title] string false Document title. Required for BeDOC, GeDOC, GGeDOC when creating new ADOC document.
adoc[sort] string false Document sort.
adoc[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, notarisation, copy-certification
adoc[signer_individual_name] string false Full name (required for ADoc signing)
adoc[signer_position_name] string false Position, example: Director (required for ADoc signing)
adoc[signer_structural_subdivision] string false Department or division. Example: Accounting
adoc[signing_structure][content][] array false Define file element ID to sign it
adoc[signing_structure][signatures][] array false Define Signature elements ID`s to sign
adoc[signing_structure][metadata][signable][document][] array false Define document metadata element ID`s to sign
adoc[signing_structure][metadata][signable][authors][] array false Define author element ID`s to sign
adoc[signing_structure][metadata][signable][recipients][] array false Define recipient element ID`s to sign
adoc[signing_structure][metadata][signable][restrictions][] array false Define restriction element ID`s to sign
adoc[signing_structure][metadata][signable][registrations][] array false Define registration element ID`s to sign
adoc[signing_structure][metadata][signable][receptions][] array false Define reception element ID`s to sign
adoc[authors][0][name] string false Full name or company name
adoc[authors][0][code] string false Personal code or company code
adoc[authors][0][address] string false 1428 Elm Street
adoc[authors][0][individual] boolean false true or false
adoc[case_id][0] string false Index of the case (volume) the document is assigned to
adoc[storage] string false Storage location
adoc[recipients][0][name] string false Full name or company name
adoc[recipients][0][code] string false Personal code or company code
adoc[recipients][0][address] string false 1428 Elm Street
adoc[recipients][0][individual] boolean false true or false
adoc[restrictions][0][content_restriction] boolean false true or false
adoc[restrictions][0][metadata_restriction] boolean false true or false
adoc[restrictions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[restrictions][0][reason] string false Restricted use
adoc[registrations][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[registrations][0][number] string false Document registration number
adoc[registrations][0][registrar][individual_name] string false Full name
adoc[registrations][0][registrar][position_name] string false Position, example: Director
adoc[registrations][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[registrations][0][code] string false Code of the company or institution which registered the document
adoc[receptions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[receptions][0][number] string false Document’s registration number assigned upon reception
adoc[receptions][0][registrar][individual_name] string false Full name
adoc[receptions][0][registrar][position_name] string false Position, example: Director
adoc[receptions][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[receptions][0][receiver][name] string false Receiver’s full name or company name
adoc[receptions][0][receiver][code] string false Receivers personal or company code
adoc[receptions][0][receiver][address] string false Receiver’s address
adoc[receptions][0][receiver][individual] boolean false true or false
adoc[agent][responsibilities][0][area] string false Possible values: creation, management, relocation, storage, deletion
adoc[agent][responsibilities][0][responsible][individual_name] string false Full name
adoc[agent][responsibilities][0][responsible][position_name] string false Position, example: Director
adoc[agent][responsibilities][0][responsible][structural_subdivision] string false Department or division. Example: Accounting
bdoc[files][0][name] string true File name (required for BDoc signing)
bdoc[files][0][content] string true Base64 encoded file content (required for BDoc signing)
bdoc[files][0][digest] string true SHA256 checksum of file content (required for BDoc signing)
bdoc[country] string false Estonia
bdoc[city] string false Tallinn
bdoc[postal_code] string false 01234
bdoc[position] string false Manager
edoc[files][0][name] string true File name (required for EDoc signing)
edoc[files][0][content] string true Base64 encoded file content (required for EDoc signing)
edoc[files][0][digest] string true SHA256 checksum of file content (required for EDoc signing)
edoc[country] string false Latvia
edoc[city] string false Riga
edoc[postal_code] string false 01234
edoc[position] string false Manager
asice[files][0][name] string true File name (required for ASiCe signing)
asice[files][0][content] string true Base64 encoded file content (required for ASiCe signing)
asice[files][0][digest] string true SHA256 checksum of file content (required for ASiCe signing)
asice[country] string false Estonia
asice[city] string false Tallinn
asice[postal_code] string false 01234
asice[position] string false Manager

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "token": "cb4e6efec94d0c7cf3542f591c803b05a17c78f4",
    "control_code": "1337"
}

Signing Status

GET /mobile/sign/status/{token}.json

This API method checks the status of the document signing process. Success response returns a signed document. Status field has value of "ok" - on success, "waiting" - when the process is pending, or "error" when the process has timed out, has been canceled or an error occurred.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /mobile/sign call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "ok",
    "signature_id": "Signature1",
    "file": {
        "name": "d251f53441f61822a7884454e89d0c5baf246ab2_signed.pdf",
        "content": "Base64 encoded signed file content",
        "digest": "SHA1 checksum of signed file content"
    },
}

5. Document Signing with Smart-ID

Sign

POST /smartid/sign.json

This API method initiates the document signing process with Smart-ID. Returns session token and verification code to be displayed to the user. The list of required parameters varies by document format. You will find both common parameters (parameters that you need to send regardless of the document format) and format-specific parameters in the tables below.

To determine the result of the initiated signing process you need to call the Smart-ID Signing Status API method periodically every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
type string pdf Document format. Possible values: pdf, pdflt, adoc, adoc.cedoc, adoc.bedoc, adoc.gedoc, adoc.ggedoc, mdoc, mdoc.cedoc, mdoc.bedoc, mdoc.gedoc, mdoc.ggedoc, bdoc, edoc, asice.
code string 30303039914 Personal code.
country string LT Signer's country code. Possible values: LT, LV, EE.
timestamp boolean true Timestamp.
language string LT Language for messages. Possible values: LT, LV, ET, EN, RU.

Optional params

Name Type Required Description
message string false Message displayed in Smart-ID application.
confirmationMessage string false Message displayed in Smart-ID application and shown in confirmation modal.
pdf[files][0][name] string true File name (required for PDF signing)
pdf[files][0][content] string true Base64 encoded file content (required for PDF signing)
pdf[files][0][digest] string true SHA256 checksum of file content (required for PDF signing)
pdf[contact] string true Full name (required for PDF signing)
pdf[signing_purpose] string false Possible values: signature, registration. Default: signature.
pdf[reason] string false Text that will be displayed in visible signature
pdf[location] string true Signing location (required for PDF signing). Example: Vilnius
pdf[annotation][page] string false Page index for visible signature. Default: 1
pdf[annotation][top] string false Visible signature position from top. Default: 1
pdf[annotation][left] string false Visible signature position from left. Default: 1
pdf[annotation][width] string false Visible signature width. Default: 100
pdf[annotation][height] string false Visible signature height. Default: 40
pdf[annotation][text] string false Custom text for visible signature. Example: Signature: Jonas Jonaitis
pdf[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdf[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
pdflt[files][0][name] string true File name (required for PDF-LT signing)
pdflt[files][0][content] string true Base64 encoded file content (required for PDF-LT signing)
pdflt[files][0][digest] string true SHA256 checksum of file content (required for PDF-LT signing)
pdflt[compliance_level] string false A|B (Required if not already set in document)
pdflt[titles][0][name] string false Document title (Required if not already set in document)
pdflt[titles][0][language] string false Title language (ex. lt-LT, required if not already set in document)
pdflt[authors][0][name] string false Author's full name or company name (Required if not already set in document)
pdflt[authors][0][code] string false Personal code or company code
pdflt[authors][0][address] string false 1428 Elm Street
pdflt[authors][0][email] string false E-mail of person or company
pdflt[authors][0][individual] boolean false true or false (Required if not already set in document)
pdflt[contact] string true Signer's full name (required for PDF-LT signing)
pdflt[reason] string false Text that will be displayed in visible signature
pdflt[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, resolution, end-of-execution, notarisation, copy-certification, authenticity
pdflt[location] string false Signing location. Example: Vilnius
pdflt[role] string false Signer role. Example: Manager
pdflt[note] string false Additional note about signing. Example. visa note
pdflt[signer_registration][date] string false Signer registration date. Example: 2012-01-01T12:12:12Z
pdflt[signer_registration][number] string false Signer registration number
pdflt[signer_registration][code] string false Signer registration code
pdflt[signer_reception][date] string false Signer reception date. Example: 2012-01-01T12:12:12Z
pdflt[signer_reception][number] string false Signer reception number
pdflt[signer_reception][code] string false Signer reception code
pdflt[signer_reception][receiver][name] string false Receiver's full name or company name (must be specified for reception)
pdflt[signer_reception][receiver][code] string false Personal code or company code
pdflt[signer_reception][receiver][address] string false 1428 Elm Street
pdflt[signer_reception][receiver][email] string false E-mail of person or company
pdflt[signer_reception][receiver][individual] boolean false true or false
pdflt[recipients][0][name] string false Recipient's full name or company name
pdflt[recipients][0][code] string false Personal code or company code
pdflt[recipients][0][address] string false 1428 Elm Street
pdflt[recipients][0][email] string false E-mail of person or company
pdflt[recipients][0][individual] boolean false true or false
pdflt[original_registrations][0][date] string false Original registration date. Example: 2012-01-01T12:12:12Z
pdflt[original_registrations][0][number] string false Original registration number
pdflt[original_registrations][0][code] string false Original registration code
pdflt[original_receptions][0][date] string false Original reception date. Example: 2012-01-01T12:12:12Z
pdflt[original_receptions][0][number] string false Original reception number
pdflt[original_receptions][0][code] string false Original reception code
pdflt[original_receivers][0][name] string false Receiver's full name or company name
pdflt[original_receivers][0][code] string false Personal code or company code
pdflt[original_receivers][0][address] string false 1428 Elm Street
pdflt[original_receivers][0][email] string false E-mail of person or company
pdflt[original_receivers][0][individual] boolean false true or false
pdflt[instance_identifier] string false Document instance identifier
pdflt[annotation][page] string false Page index for visible signature. Default: 1
pdflt[annotation][top] string false Visible signature position from top. Default: 1
pdflt[annotation][left] string false Visible signature position from left. Default: 1
pdflt[annotation][width] string false Visible signature width. Default: 100
pdflt[annotation][height] string false Visible signature height. Default: 40
pdflt[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdflt[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdflt[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
adoc[files][0][name] string true File name (required for ADoc signing)
adoc[files][0][content] string true Base64 encoded file content (required for ADoc signing)
adoc[files][0][digest] string true SHA256 checksum of file content (required for ADoc signing)
adoc[files][0][type] string true Possible values: main, appendix, attachment
adoc[title] string false Document title. Required for BeDOC, GeDOC, GGeDOC when creating new ADOC document.
adoc[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, notarisation, copy-certification
adoc[signer_individual_name] string false Full name (required for ADoc signing)
adoc[signer_position_name] string false Position, example: Director (required for ADoc signing)
adoc[signer_structural_subdivision] string false Department or division. Example: Accounting
adoc[signing_structure][content][] array false Define file element ID to sign it
adoc[signing_structure][signatures][] array false Define Signature elements ID`s to sign
adoc[signing_structure][metadata][signable][document][] array false Define document metadata element ID`s to sign
adoc[signing_structure][metadata][signable][authors][] array false Define author element ID`s to sign
adoc[signing_structure][metadata][signable][recipients][] array false Define recipient element ID`s to sign
adoc[signing_structure][metadata][signable][restrictions][] array false Define restriction element ID`s to sign
adoc[signing_structure][metadata][signable][registrations][] array false Define registration element ID`s to sign
adoc[signing_structure][metadata][signable][receptions][] array false Define reception element ID`s to sign
adoc[authors][0][name] string false Full name or company name
adoc[authors][0][code] string false Personal code or company code
adoc[authors][0][address] string false 1428 Elm Street
adoc[authors][0][individual] boolean false true or false
adoc[case_id][0] string false Index of the case (volume) the document is assigned to
adoc[storage] string false Storage location
adoc[recipients][0][name] string false Full name or company name
adoc[recipients][0][code] string false Personal code or company code
adoc[recipients][0][address] string false 1428 Elm Street
adoc[recipients][0][individual] boolean false true or false
adoc[restrictions][0][content_restriction] boolean false true or false
adoc[restrictions][0][metadata_restriction] boolean false true or false
adoc[restrictions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[restrictions][0][reason] string false Restricted use
adoc[registrations][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[registrations][0][number] string false Document registration number
adoc[registrations][0][registrar][individual_name] string false Full name
adoc[registrations][0][registrar][position_name] string false Position, example: Director
adoc[registrations][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[registrations][0][code] string false Code of the company or institution which registered the document
adoc[receptions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[receptions][0][number] string false Document’s registration number assigned upon reception
adoc[receptions][0][registrar][individual_name] string false Full name
adoc[receptions][0][registrar][position_name] string false Position, example: Director
adoc[receptions][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[receptions][0][receiver][name] string false Receiver’s full name or company name
adoc[receptions][0][receiver][code] string false Receivers personal or company code
adoc[receptions][0][receiver][address] string false Receiver’s address
adoc[receptions][0][receiver][individual] boolean false true or false
adoc[agent][responsibilities][0][area] string false Possible values: creation, management, relocation, storage, deletion
adoc[agent][responsibilities][0][responsible][individual_name] string false Full name
adoc[agent][responsibilities][0][responsible][position_name] string false Position, example: Director
adoc[agent][responsibilities][0][responsible][structural_subdivision] string false Department or division. Example: Accounting
bdoc[files][0][name] string true File name (required for BDoc signing)
bdoc[files][0][content] string true Base64 encoded file content (required for BDoc signing)
bdoc[files][0][digest] string true SHA256 checksum of file content (required for BDoc signing)
bdoc[country] string false Estonia
bdoc[city] string false Tallinn
bdoc[postal_code] string false 01234
bdoc[position] string false Manager
edoc[files][0][name] string true File name (required for EDoc signing)
edoc[files][0][content] string true Base64 encoded file content (required for EDoc signing)
edoc[files][0][digest] string true SHA256 checksum of file content (required for EDoc signing)
edoc[country] string false Latvia
edoc[city] string false Riga
edoc[postal_code] string false 01234
edoc[position] string false Manager
asice[files][0][name] string true File name (required for ASiCe signing)
asice[files][0][content] string true Base64 encoded file content (required for ASiCe signing)
asice[files][0][digest] string true SHA256 checksum of file content (required for ASiCe signing)
asice[country] string false Estonia
asice[city] string false Tallinn
asice[postal_code] string false 01234
asice[position] string false Manager

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "token": "cb4e6efec94d0c7cf3542f591c803b05a17c78f4",
    "control_code": "1337"
}

Signing Status

GET /smartid/sign/status/{token}.json

This API method checks the status of the document signing process. Success response returns a signed document. Status field has value of "ok" - on success, "waiting" - when the process is pending, "canceled" - when the users canceled the request. When the process has timed out or an error occurs, the status "error" is returned.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /smartid/sign call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "ok",
    "signature_id": "Signature1",
    "file": {
        "name": "d251f53441f61822a7884454e89d0c5baf246ab2_signed.pdf",
        "content": "Base64 encoded signed file content",
        "digest": "SHA1 checksum of signed file content"
    },
}

6. Document Signing with Audkenni App

Sign

POST /audkenniapp/sign.json

This API method initiates the document signing process with Audkenni App. Returns session token and verification code to be displayed to the user. The list of required parameters varies by document format. You will find both common parameters (parameters that you need to send regardless of the document format) and format-specific parameters in the tables below.

To determine the result of the initiated signing process you need to call the Audkenni App Signing Status API method periodically every 2 seconds to determine the result. Do not repeat the request until a response from the previous request is received. Also, make sure to stop requesting the login status after 120 seconds in any case.

Required params

Name Type Example Description
type string pdf Document format. Possible values: pdf, pdflt, adoc, adoc.cedoc, adoc.bedoc, adoc.gedoc, adoc.ggedoc, mdoc, mdoc.cedoc, mdoc.bedoc, mdoc.gedoc, mdoc.ggedoc, bdoc, edoc, asice.
code string 0101304339 Personal code.
timestamp boolean true Timestamp.

Optional params

Name Type Required Description
message string false Message displayed in Audkenni App application.
pdf[files][0][name] string true File name (required for PDF signing)
pdf[files][0][content] string true Base64 encoded file content (required for PDF signing)
pdf[files][0][digest] string true SHA256 checksum of file content (required for PDF signing)
pdf[contact] string true Full name (required for PDF signing)
pdf[signing_purpose] string false Possible values: signature, registration. Default: signature.
pdf[reason] string false Text that will be displayed in visible signature
pdf[location] string true Signing location (required for PDF signing). Example: Vilnius
pdf[annotation][page] string false Page index for visible signature. Default: 1
pdf[annotation][top] string false Visible signature position from top. Default: 1
pdf[annotation][left] string false Visible signature position from left. Default: 1
pdf[annotation][width] string false Visible signature width. Default: 100
pdf[annotation][height] string false Visible signature height. Default: 40
pdf[annotation][text] string false Custom text for visible signature. Example: Signature: Jonas Jonaitis
pdf[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdf[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
pdflt[files][0][name] string true File name (required for PDF-LT signing)
pdflt[files][0][content] string true Base64 encoded file content (required for PDF-LT signing)
pdflt[files][0][digest] string true SHA256 checksum of file content (required for PDF-LT signing)
pdflt[compliance_level] string false A|B (Required if not already set in document)
pdflt[titles][0][name] string false Document title (Required if not already set in document)
pdflt[titles][0][language] string false Title language (ex. lt-LT, required if not already set in document)
pdflt[authors][0][name] string false Author's full name or company name (Required if not already set in document)
pdflt[authors][0][code] string false Personal code or company code
pdflt[authors][0][address] string false 1428 Elm Street
pdflt[authors][0][email] string false E-mail of person or company
pdflt[authors][0][individual] boolean false true or false (Required if not already set in document)
pdflt[contact] string true Signer's full name (required for PDF-LT signing)
pdflt[reason] string false Text that will be displayed in visible signature
pdflt[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, resolution, end-of-execution, notarisation, copy-certification, authenticity
pdflt[location] string false Signing location. Example: Vilnius
pdflt[role] string false Signer role. Example: Manager
pdflt[note] string false Additional note about signing. Example. visa note
pdflt[signer_registration][date] string false Signer registration date. Example: 2012-01-01T12:12:12Z
pdflt[signer_registration][number] string false Signer registration number
pdflt[signer_registration][code] string false Signer registration code
pdflt[signer_reception][date] string false Signer reception date. Example: 2012-01-01T12:12:12Z
pdflt[signer_reception][number] string false Signer reception number
pdflt[signer_reception][code] string false Signer reception code
pdflt[signer_reception][receiver][name] string false Receiver's full name or company name (must be specified for reception)
pdflt[signer_reception][receiver][code] string false Personal code or company code
pdflt[signer_reception][receiver][address] string false 1428 Elm Street
pdflt[signer_reception][receiver][email] string false E-mail of person or company
pdflt[signer_reception][receiver][individual] boolean false true or false
pdflt[recipients][0][name] string false Recipient's full name or company name
pdflt[recipients][0][code] string false Personal code or company code
pdflt[recipients][0][address] string false 1428 Elm Street
pdflt[recipients][0][email] string false E-mail of person or company
pdflt[recipients][0][individual] boolean false true or false
pdflt[original_registrations][0][date] string false Original registration date. Example: 2012-01-01T12:12:12Z
pdflt[original_registrations][0][number] string false Original registration number
pdflt[original_registrations][0][code] string false Original registration code
pdflt[original_receptions][0][date] string false Original reception date. Example: 2012-01-01T12:12:12Z
pdflt[original_receptions][0][number] string false Original reception number
pdflt[original_receptions][0][code] string false Original reception code
pdflt[original_receivers][0][name] string false Receiver's full name or company name
pdflt[original_receivers][0][code] string false Personal code or company code
pdflt[original_receivers][0][address] string false 1428 Elm Street
pdflt[original_receivers][0][email] string false E-mail of person or company
pdflt[original_receivers][0][individual] boolean false true or false
pdflt[instance_identifier] string false Document instance identifier
pdflt[annotation][page] string false Page index for visible signature. Default: 1
pdflt[annotation][top] string false Visible signature position from top. Default: 1
pdflt[annotation][left] string false Visible signature position from left. Default: 1
pdflt[annotation][width] string false Visible signature width. Default: 100
pdflt[annotation][height] string false Visible signature height. Default: 40
pdflt[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdflt[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdflt[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
adoc[files][0][name] string true File name (required for ADoc signing)
adoc[files][0][content] string true Base64 encoded file content (required for ADoc signing)
adoc[files][0][digest] string true SHA256 checksum of file content (required for ADoc signing)
adoc[files][0][type] string true Possible values: main, appendix, attachment
adoc[title] string false Document title. Required for BeDOC, GeDOC, GGeDOC when creating new ADOC document.
adoc[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, notarisation, copy-certification
adoc[signer_individual_name] string false Full name (required for ADoc signing)
adoc[signer_position_name] string false Position, example: Director (required for ADoc signing)
adoc[signer_structural_subdivision] string false Department or division. Example: Accounting
adoc[signing_structure][content][] array false Define file element ID to sign it
adoc[signing_structure][signatures][] array false Define Signature elements ID`s to sign
adoc[signing_structure][metadata][signable][document][] array false Define document metadata element ID`s to sign
adoc[signing_structure][metadata][signable][authors][] array false Define author element ID`s to sign
adoc[signing_structure][metadata][signable][recipients][] array false Define recipient element ID`s to sign
adoc[signing_structure][metadata][signable][restrictions][] array false Define restriction element ID`s to sign
adoc[signing_structure][metadata][signable][registrations][] array false Define registration element ID`s to sign
adoc[signing_structure][metadata][signable][receptions][] array false Define reception element ID`s to sign
adoc[authors][0][name] string false Full name or company name
adoc[authors][0][code] string false Personal code or company code
adoc[authors][0][address] string false 1428 Elm Street
adoc[authors][0][individual] boolean false true or false
adoc[case_id][0] string false Index of the case (volume) the document is assigned to
adoc[storage] string false Storage location
adoc[recipients][0][name] string false Full name or company name
adoc[recipients][0][code] string false Personal code or company code
adoc[recipients][0][address] string false 1428 Elm Street
adoc[recipients][0][individual] boolean false true or false
adoc[restrictions][0][content_restriction] boolean false true or false
adoc[restrictions][0][metadata_restriction] boolean false true or false
adoc[restrictions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[restrictions][0][reason] string false Restricted use
adoc[registrations][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[registrations][0][number] string false Document registration number
adoc[registrations][0][registrar][individual_name] string false Full name
adoc[registrations][0][registrar][position_name] string false Position, example: Director
adoc[registrations][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[registrations][0][code] string false Code of the company or institution which registered the document
adoc[receptions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[receptions][0][number] string false Document’s registration number assigned upon reception
adoc[receptions][0][registrar][individual_name] string false Full name
adoc[receptions][0][registrar][position_name] string false Position, example: Director
adoc[receptions][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[receptions][0][receiver][name] string false Receiver’s full name or company name
adoc[receptions][0][receiver][code] string false Receivers personal or company code
adoc[receptions][0][receiver][address] string false Receiver’s address
adoc[receptions][0][receiver][individual] boolean false true or false
adoc[agent][responsibilities][0][area] string false Possible values: creation, management, relocation, storage, deletion
adoc[agent][responsibilities][0][responsible][individual_name] string false Full name
adoc[agent][responsibilities][0][responsible][position_name] string false Position, example: Director
adoc[agent][responsibilities][0][responsible][structural_subdivision] string false Department or division. Example: Accounting
bdoc[files][0][name] string true File name (required for BDoc signing)
bdoc[files][0][content] string true Base64 encoded file content (required for BDoc signing)
bdoc[files][0][digest] string true SHA256 checksum of file content (required for BDoc signing)
bdoc[country] string false Estonia
bdoc[city] string false Tallinn
bdoc[postal_code] string false 01234
bdoc[position] string false Manager
edoc[files][0][name] string true File name (required for EDoc signing)
edoc[files][0][content] string true Base64 encoded file content (required for EDoc signing)
edoc[files][0][digest] string true SHA256 checksum of file content (required for EDoc signing)
edoc[country] string false Latvia
edoc[city] string false Riga
edoc[postal_code] string false 01234
edoc[position] string false Manager
asice[files][0][name] string true File name (required for ASiCe signing)
asice[files][0][content] string true Base64 encoded file content (required for ASiCe signing)
asice[files][0][digest] string true SHA256 checksum of file content (required for ASiCe signing)
asice[country] string false Estonia
asice[city] string false Tallinn
asice[postal_code] string false 01234
asice[position] string false Manager

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "control_code": "8539",
    "token": "505187957d8ea493852afb1aba06c069bafb1c92"
}

Signing Status

GET /audkenniapp/sign/status/{token}.json

This API method checks the status of the document signing process. Success response returns a signed document. Status field has value of "ok" - on success, "waiting" - when the process is pending, "canceled" - when the users canceled the request. When the process has timed out or an error occurs, the status "error" is returned.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /audkenniapp/sign call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "ok",
    "signature_id": "Signature1",
    "file": {
        "name": "d251f53441f61822a7884454e89d0c5baf246ab2_signed.pdf",
        "content": "Base64 encoded signed file content",
        "digest": "SHA1 checksum of signed file content"
    },
}

7. Hash Signing with Mobile ID

Sign hash

POST /mobile/sign/hash.json

Method for signing custom hash with Mobile ID.

Required params

Name Type Example Description
phone string +37200000766 Phone number.
code string 60001019906 Personal code.
hash string d04b98f48e8f8bcc15c6ae5ac050801cd6dcfd42 8fb5f9e65c4e16e7807340fa Hash to sign.
hash_algorithm string SHA256 Hash algorithm. Possible values: SHA256, SHA512.
message string Signing of Agreement No. 123456. Message displayed on the phone screen. Attention: UTF-8 symbols are not allowed.
language string EN Language for messages displayed on the phone screen. Possible values: LT, ET, IS, EN, RU.

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "token": "cb4e6efec94d0c7cf3542f591c803b05a17c78f4",
    "control_code": "1337"
}

Hash Signing Status

GET /mobile/sign/hash/status/{token}.json

This API method checks the status of the hash signing process. Success response returns signature value. Status field has value of "ok" - on success, "waiting" - when the process is pending, or "error" when the process has timed out, has been canceled or an error occured.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /mobile/sign/hash call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "ok",
    "signature_value": "OCggf2lbKrMrMW9Jpw7d5t3fF/haeA0lwgcFx0ngCsaAShJa+pD2PN0fhjBVtwbT/lzP/8UkmnI2lmkOZLgum5V9PFgqduulQvbuNoietco7IPW4dYbHIcBXF+LG1tT87qWeJjHTXxEY52dMubC5KrrP84OMHsufxvX2RggeP7o="
}

Get user signing certificate

POST /v2/mobile/certificate.json

Returns desired user Mobile ID signing certificate on success.

Required params

Name Type Example Description
phone string +37200000766 Phone number.
code string 60001019906 Personal code.

Requirements

Content
Replaces header if set

{
   "status": "ok",
   "name": "MARY ÄNN",
   "surname": "O’CONNEŽ-ŠUSLIK TESTNUMBER",
   "code": "60001019906",
   "country": "EE",
   "certificate": {
     "name": "/C=EE/O=ESTEID (MOBIIL-ID)/OU=digital signature/CN=O\\xE2\\x80\\x99CONNE\\xC5\\xBD-\\xC5\\xA0USLIK TESTNUMBER,MARY \\xC3\\x84NN,60001019906/SN=O\\xE2\\x80\\x99CONNE\\xC5\\xBD-\\xC5\\xA0USLIK TESTNUMBER/GN=MARY \\xC3\\x84NN/serialNumber=60001019906",
     "subject": {
       "country": "EE",
       "organisation": "ESTEID (MOBIIL-ID)",
       "organisation_unit": "digital signature",
       "common_name": "O’CONNEŽ-ŠUSLIK TESTNUMBER,MARY ÄNN,60001019906",
       "surname": "O’CONNEŽ-ŠUSLIK TESTNUMBER",
       "name": "MARY ÄNN",
       "serial_number": "60001019906"
     },
     "issuer": {
       "country": "EE",
       "organisation": "AS Sertifitseerimiskeskus",
       "common_name": "TEST of ESTEID-SK 2015"
     },
     "valid_from": "2018-08-09T14:22:54+00:00",
     "valid_to": "2022-12-11T21:59:59+00:00",
     "value": "Base64 encoded PEM certificate"
    }
}

8. Hash Signing with Smart-ID

Get user certificate

POST /smartid/certificate.json

Returns desired user Smart-ID certificate. This request must be followed by /smartid/sign/hash.json request.

Required params

Name Type Example Description
code string 30303039914 Personal code.
country string LT Country related to personal code. Possible values: LT, LV, EE.

Requirements

Content
Replaces header if set

{
  "status": "ok",
  "account_identificator": "PNOEE-30303039914-Z1B2-Q",
  "name": "DEMO",
  "surname": "SMART-ID",
  "code": "30303039914",
  "country": "EE",
  "certificate": {
    "name": "/OU=SIGNATURE/CN=SMART-ID,DEMO,PNOEE-30303039914/serialNumber=PNOEE-30303039914/GN=DEMO/SN=SMART-ID/C=EE",
    "subject": {
      "organisation_unit": "SIGNATURE",
      "common_name": "SMART-ID,DEMO,PNOEE-30303039914",
      "serial_number": "PNOEE-30303039914",
      "name": "DEMO",
      "surname": "SMART-ID",
      "country": "EE"
    },
    "issuer": {
      "country": "EE",
      "organisation": "AS Sertifitseerimiskeskus",
      "common_name": "TEST of EID-SK 2016"
    },
    "valid_from": "2019-03-12T17:46:41+02:00",
    "valid_to": "2030-12-18T01:59:59+02:00",
    "value": "Base64 encoded PEM certificate"
  }
}

Sign hash

POST /smartid/sign/hash.json

Method for signing custom hash with Smart-ID.

/smartid/certificate.json must be called before using this method.

Required params

Name Type Example Description
account_identificator string PNOEE-30303039914-Z1B2-Q Account identificator which has to be received from /smartid/certificate.json method.
hash string d04b98f48e8f8bcc15c6ae5ac050801cd6dcfd42 8fb5f9e65c4e16e7807340fa Hash to sign.
hash_algorithm string SHA256 Hash algorithm. Possible values: SHA256, SHA512.
message string Signing of Agreement No. 123456. Message displayed in the Smart-ID app.

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "control_code": "0033",
    "token": "3f961393f06b90c1d8cf8a159459900770e326bf"
}

Hash Signing Status

GET /smartid/sign/hash/status/{token}.json

This API method checks the status of the hash signing process. Success response returns signature value. Status field has value of "ok" - on success, "waiting" - when the process is pending, "canceled" - when the users canceled the request. When the process has timed out or an error occurs, the status "error" is returned.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /smartid/sign/hash call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "canceled"
}

or

{
    "status": "ok",
    "signature_value": "Base64 encoded signature value"
}

9. Hash Signing with Audkenni App

Get user certificate

POST /audkenniapp/certificate.json

Returns desired user Audkenni App certificate. This request must be followed by /audkenniapp/sign/hash.json request.

Required params

Name Type Example Description
code string 0101304339 Personal code.

Requirements

Content
Replaces header if set

{
  "status": "ok",
  "account_identificator": "PNOIS-0101304339-4L6G-Q",
  "name": "Gervimaður",
  "surname": "Eyjaálfa",
  "code": "0101304339",
  "country": "IS",
  "certificate": {
    "name": "/C=IS/CN=Gervima\\xC3\\xB0ur Eyja\\xC3\\xA1lfa/SN=Eyja\\xC3\\xA1lfa/GN=Gervima\\xC3\\xB0ur/serialNumber=0101304339",
    "subject": {
      "country": "IS",
      "common_name": "Gervimaður Eyjaálfa",
      "surname": "Eyjaálfa",
      "name": "Gervimaður",
      "serial_number": "0101304339"
    },
    "issuer": {
      "country": "IS",
      "organisation": "Auðkenni test ehf",
      "common_name": "Fullgilt audkenni Test",
      "serial_number": "5210002790"
    },
    "valid_from": "2021-07-01T11:59:02+03:00",
    "valid_to": "2026-07-01T11:59:02+03:00",
    "value": "LS0tLS1CRUdJTiBDRVJUSU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ZVVycHVhcFVJMVZOc2ZNR2hiMU1ML1JhcnYydWVYTHBPV1EyMzZCYzUzZzExZm9xd2xaaEh3UmMKV1hlSVBPcE0ydkxxV2hsRXVPak5VMWE3N1pKYTArTCtHQlZRdlRrVEhOanVydmtiNCtwSi93d1J1OUpyNTh3Nwpha3p1U04vSlRUU3YxZElkY20yWGc5b3JMd2FpcHU5MGtXOWFmaXV0Rm9id3dOeDhBd3VYMG1CRE5tc0xvUEJPCk0rMlM2ZnlISEQyY0l0bkEzTk1iSGJiVVVJWS8rTDVVWElHeUxQWkJ3NFBibGxvZm9iZ2tya0FOcjhvRjRBa2cKbWNibWxRc2krV3lMRldEYXBlci82QjR6S0hOWFMydGVxN1ZSbWtSMEttZjc1aWQ1YU5FTTNpRlNhcURDTktJVwoySmptbnExb01zVThCTkRLMll2YUFPT0RhSHJDWWxTV3RIRXFvcXlZSmIzM1F3WEpjaUxUQ3pQMXluYnRlQzB3Cmh6QXo3RjdqTEtpKzg0ZnhNZ0EyTnNuMnlGV3lqQWU1QTc4NUwzOGh0OUxoZWJ2Wit0UDR1QmY0dkc3SjV1VTEKMVhzTXl0dk43VDBad3Q5RGFkT29WN3NJRFZUNmJydnVVdThFdnZlRkVMUlFLWWl5RHBVck01cmlCWjhFT0ZSMwpnTGFNOWp2bVhwalA1SUZIU09Gd1NWR3V5U250VkFlbWVGRERYZmxWWXRocmsxczFwUEtLNXdvWEU5S0p1TG1OCk9nekNYNU5tb0preUIvNEQ4SDhUSnZ2VjlzMU5vRjl4YXp4bWhSaG5vdzAyd2pkOTJUSVBMRmFDQWIyNzFKcDYKMGNCN29TTEpkR0xkVUc2ZEhxdFhRT3hUd3dacmtPdlNjaFU9Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0="
  }
}

Sign hash

POST /audkenniapp/sign/hash.json

Method for signing custom hash with Audkenni App.

/audkenniapp/certificate.json must be called before using this method.

Required params

Name Type Example Description
account_identificator string PNOIS-0101304339-4L6G-Q Account identificator which has to be received from /audkenniapp/certificate.json method.
hash string PxSWkv6QDZrw/HC4QTHjQW1cwMlz+Qow+fWnrNOG j9g= Base64 encoded SHA256 hash to sign.
message string Signing of Agreement No. 123456. Message displayed in the Audkenni App.

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "control_code": "0033",
    "token": "3f961393f06b90c1d8cf8a159459900770e326bf"
}

Hash Signing Status

GET /audkenniapp/sign/hash/status/{token}.json

This API method checks the status of the hash signing process. Success response returns signature value. Status field has value of "ok" - on success, "waiting" - when the process is pending, "canceled" - when the users canceled the request. When the process has timed out or an error occurs, the status "error" is returned.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Uses token received from /audkenniapp/sign/hash call.

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "canceled"
}

or

{
    "status": "ok",
    "signature_value": "Base64 encoded signature value"
}

10. Document Management API Methods

Set of methods for advanced manipulation of electronically signed documents.

Archiving

POST /archive.json

Prepares the document’s signatures for long-term document storage. If document’s signatures are not prepared for long term storage and certificate is revoked or expired, signed document is immediately rendered invalid. Thus, archiving function is very important for all real-life scenarios where signature’s meaning must be persisted through longer periods.

Required params

Name Type Example Description
type string pdf Possible values: pdf, pdflt, adoc, mdoc, bdoc, edoc, asice
file[name] string test.pdf File name
file[content] string base64_encode(file) Base64 encoded file content
file[digest] string 6256a099cd2a3d3606acc86e7eacbdcf4cd067db 3a1d46930d77886d96fd226e SHA256 checksum of file content

Optional params

Name Type Required Description
signatures[][id] string false Signature ID (only for ADoc documents)

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "file": {
        "name": "archived_document.pdf",
        "content": "Base64 encoded archived file content",
        "digest": "SHA1 checksum of archived file content"
    }
}

Check

POST /check.json

This method returns PDF, ADoc or MDoc file with meta data. Can be used to fetch information about document’s signatures.

Required params

Name Type Example Description
type string pdf Possible values: pdf, pdflt, adoc, mdoc, bdoc, edoc, ddoc, asice
file[name] string test.pdf File name
file[content] string base64_encode(file) Base64 encoded file content
file[digest] string 6256a099cd2a3d3606acc86e7eacbdcf4cd067db 3a1d46930d77886d96fd226e SHA256 checksum of file content

Optional params

Name Type Required Description
validation_policy string false Validation policy to be used for validation (qes, aes). Default: qes

Requirements

Parameters

Content
Replaces header if set

{
  "status": "ok",
  "structure": {
    "content": [
      {
        "id": "test.pdf",
        "name": "test.pdf",
        "size": 100208,
        "mimetype": "application/pdf",
        "type": "main"
      }
    ],
    "signatures": [
      {
        "id": "Signature1",
        "signing_time": "2016-01-08 10:53:41",
        "signature_timestamp_time": "2016-01-08 10:53:41",
        "grace_period_end_time": "2016-01-09 10:53:41",
        "signing_purpose": "signature",
        "certificate": {
          "name": "2.5.4.5=#130b3531303031303931303732,2.5.4.42=#0c0853454954534d4553,2.5.4.4=#0c0a544553544e554d424552,CN=TESTNUMBER\\,SEITSMES\\,60001019906,OU=digital signature,O=ESTEID (MOBIIL-ID),C=EE",
          "subject": {
            "organisation": "ESTEID (MOBIIL-ID)",
            "organisation_unit": "digital signature",
            "name": "SEITSMES",
            "country": "EE",
            "serial_number": "60001019906",
            "surname": "TESTNUMBER",
            "common_name": "TESTNUMBER,SEITSMES,60001019906"
          },
          "issuer": {
            "organisation": "AS Sertifitseerimiskeskus",
            "country": "EE",
            "common_name": "TEST of ESTEID-SK 2011",
            "email": "[email protected]"
          },
          "valid_from": "2013-09-19 11:45:34",
          "valid_to": "2016-09-18 23:59:59",
          "value": "LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVpVENDQTNHZ0F3SUJBZ0lRY29UcXNORGhMS3hTT3JtdVQwV3g4ekFOQmdrcWhraUc5dzBCQVFVRkFEQnNNUXN3Q1FZRFZRUUcKRXdKRlJURWlNQ0FHQTFVRUNnd1pRVk1nVTJWeWRHbG1hWFJ6WldWeWFXMXBjMnRsYzJ0MWN6RWZNQjBHQTFVRUF3d1dWRVZUVkNCdgpaaUJGVTFSRlNVUXRVMHNnTWpBeE1URVlNQllHQ1NxR1NJY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RmdRVWdZbEZKNG13d0QweHdMb1UKUU1FcjFzejM2Qkl3SWdZSUt3WUJCUVVIQVFNRUZqQVVNQWdHQmdRQWprWUJBVEFJQmdZRUFJNUdBUVF3SHdZRFZSMGpCQmd3Rm9BVQpRYmIreGJHeHRGTVRqUHI2WXRBMGJXMGlOQW93UlFZRFZSMGZCRDR3UERBNm9EaWdOb1kwYUhSMGNEb3ZMM2QzZHk1emF5NWxaUzl5ClpYQnZjMmwwYjNKNUwyTnliSE12ZEdWemRGOWxjM1JsYVdReU1ERXhMbU55YkRBTkJna3Foa2lHOXcwQkFRVUZBQU9DQVFFQUZKaXAKL0xGVE9JaXlPUEdSaGE1T0NuZFhOdGRacnFLa2ZtSTk4OUhEbmVYU2dlSGJpZGthb0lDRk1mc2F6SHBVLzBROGtyb3Z3Vzk4WUhqRgo3d25hdlhZems0eDhkSjBlSjVabzJQdDY2SVRTaGNDVWVQQ2pzYkt0ZFFuamF2T1U5UHh0Rk1YMnRmSllVTlYwV3dVVyswQTlUWnIzCnpvVmJiZDJLTS81QW9LOUpveHJZSWkyRjhmN1Y1Rmowcmh6djVYM29HbTFTaEdtUmhPWG40ODFzSnNBUVIweGs2Y1BpWitoZldoWWoKUURKaXN3KzBaWTMxbURyYVhTckFFU3ltRzR0azB1Y0RtWmpVb21aakxsT3BQRUU2OG9wNm0zeG9DczMyN285RUx4bFFObTlnbVhtUApoa1B1V0RSR2R5RFBCeTJtck1EL2xROEU2UzlkVUZOVVBnPT0KLS0tLS1FTkQgQ0VSVElGSUNBVEUtLS0tLQ=="
        },
        "metadata": {
          "reception": {
            "date": "2015-07-01 00:00:00",
            "number": "1234567",
            "code": "12345672",
            "receiver": {
              "individual": false,
              "name": "ReceiversName",
              "code": "12345673",
              "address": "Elm Street",
              "email": "[email protected]"
            }
          },
          "contact": "Petras Petraitis",
          "reason": "signature",
          "location": "nenurodyta",
          "name": "Petras Petraitis",
          "role": "Direktoriaus pavaduotojas",
          "note": "pastaba"
        },
        "type": "qes|aes|es (qualified electronic signature, advanced electronic signature, electronic signature)",
        "is_seal": "false",
        "algorithm": "sha256",
        "is_ltv_timestamp": false,
        "is_archived": false,
        "is_valid": true,
        "valid_to": "2016-09-18 23:59:59",
        "signature_value": "H5sIylithaAviVbZy6jY9JSDuJ7+7+hXkaMef8DbyOjnv7cJv+oA3uZwED9TAhAZQZX9kNsgEN5mvoj0opyGdTVBjK1UBnukabXrF63V8nsx/v9t7wkJt45r3gxhvmw87xh5mcGFsb6xQa/7L1cea1inSShjnjgyQ22uD1K22aI="
      }
    ],
    "metadata": {
      "title": "testas",
      "standard": {
        "part": "2",
        "conformance": "B"
      },
      "identifiers": [
        {
          "value": "A",
          "scheme": "http://archyvai.lt/pdf-ltud/2013/level/"
        }
      ],
      "creation_metadata": {
        "standard_version": "PDF-LT-V1.0",
        "authors": [
          {
            "individual": false,
            "name": "Testas Testauskas",
            "code": "60001019906",
            "address": "Testo g. 1"
          },
          {
            "individual": false,
            "name": "Testas2 Testauskas2",
            "code": "51001091073",
            "address": "Testo g. 1"
          }
        ],
        "recipients": [
          {
            "individual": false,
            "name": "RecipientName1",
            "code": "12345673",
            "address": "Elm Street",
            "email": "[email protected]"
          },
          {
            "individual": false,
            "name": "RecipientName2",
            "code": "12345672",
            "address": "Elm Street",
            "email": "[email protected]"
          }
        ]
      },
      "languages": [
        {
          "locale": "LT"
        },
        {
          "locale": "EN"
        }
      ],
      "alternative_titles": [
        {
          "locale": "LT",
          "name": "testas"
        },
        {
          "locale": "EN",
          "name": "Test"
        }
      ],
      "creator_tool": "Dokobit"
    },
    "standard": "PDF-LT-V1.0",
    "category": "PDF/A-2B",
    "is_valid": true,
    "valid_to": "2016-09-18 23:59:59"
  }
}

ADoc unsignable metadata modification

POST /edit/unsignable_metadata.json

Required params

Name Type Example Description
type string adoc Possible values: adoc, mdoc
file[name] string agreement.adoc File name
file[content] string base64_encode(file) Base64 encoded file content
file[digest] string 6256a099cd2a3d3606acc86e7eacbdcf4cd067db 3a1d46930d77886d96fd226e SHA256 checksum of file content
unsignable_metadata[case_id][0] string Index of the case (volume) the document is assigned to
unsignable_metadata[append_case_id] boolean false Defines if case id should be appended or replaced (appends by default)
unsignable_metadata[storage] string Storage location
unsignable_metadata[event_history][sent][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][sent][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][sent][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][sent][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][sent][0][reason] string Reason for sending
unsignable_metadata[event_history][sent][0][sender][name] string Sender’s full name or company name
unsignable_metadata[event_history][sent][0][sender][code] string Sender’s personal or company code
unsignable_metadata[event_history][sent][0][sender][address] string Sender’s address
unsignable_metadata[event_history][sent][0][sender][individual] boolean true or false
unsignable_metadata[event_history][reclassified][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][reclassified][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][reclassified][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][reclassified][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][reclassified][0][reason] string Reason for re-classification
unsignable_metadata[event_history][reclassified][0][case_id][0] string Index of the newly assigned case (volume)
unsignable_metadata[event_history][moved_from_location][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][moved_from_location][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][moved_from_location][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][moved_from_location][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][moved_from_location][0][reason] string Reason for relocation
unsignable_metadata[event_history][moved_from_location][0][storage] string New storage location
unsignable_metadata[event_history][changed][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][changed][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][changed][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][changed][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][changed][0][reason] string Reason for the change
unsignable_metadata[event_history][changed][0][abstract] string Change contents
unsignable_metadata[event_history][changed][0][reference] string Reference of the changed metadata element(#ID or file#ID)
unsignable_metadata[event_history][changed][0][new_value] string New metadata value
unsignable_metadata[event_history][transformed][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][transformed][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][transformed][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][transformed][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][transformed][0][format] string New format
unsignable_metadata[event_history][disposed][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][disposed][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][disposed][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][disposed][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][disposed][0][reason] string Reason for deletion
unsignable_metadata[event_history][restored][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][restored][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][restored][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][restored][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][restored][0][reason] string Reason for reastoration
unsignable_metadata[event_history][resolution][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][resolution][0][author][individual_name] string Full name
unsignable_metadata[event_history][resolution][0][author][position_name] string Position, example: Director
unsignable_metadata[event_history][resolution][0][author][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][resolution][0][text] string Text of resolution
unsignable_metadata[event_history][resolution][0][executors][0][individual_name] string Full name
unsignable_metadata[event_history][resolution][0][executors][0][position_name] string Position, example: Director
unsignable_metadata[event_history][resolution][0][executors][0][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][resolution][0][due_by] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][executed][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][executed][0][responsible][individual_name] string Full name
unsignable_metadata[event_history][executed][0][responsible][position_name] string Position, example: Director
unsignable_metadata[event_history][executed][0][responsible][structural_subdivision] string Department or division. Example: Accounting
unsignable_metadata[event_history][executed][0][abstract] string Comments on execution
unsignable_metadata[event_history][postponed][0][date] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
unsignable_metadata[event_history][postponed][0][reference] string Resolution reference
unsignable_metadata[event_history][postponed][0][due_by] string xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z

Requirements

Content
Replaces header if set

{
  "status": "ok",
  "file": {
    "name": "4026e6d5f2231f30f7e4d5fd9da9831f52022a1bK3kBh9",
    "digest": "SHA1 checksum of signed file content",
    "content": "Base64 encoded signed file content"
  }
}

Time stamping

POST /timestamp.json

This API method adds a qualified timestamp for the existing signatures.

Required params

Name Type Example Description
type string pdf Possible values: adoc, mdoc, pdf, pdflt
file[name] string test.pdf File name
file[content] string base64_encode(file) Base64 encoded file content
file[digest] string 6256a099cd2a3d3606acc86e7eacbdcf4cd067db 3a1d46930d77886d96fd226e SHA256 checksum of file content

Optional params

Name Type Required Description
signatures[][id] string false Signature ID (only for ADoc documents)

Requirements

Parameters

Content
Replaces header if set

{
  "status": "ok",
  "structure": {
    "signatures": [
      {
        "id": "Signature1",
        "signing_time": "2018-10-15 09:49:31",
        "signature_timestamp_time": "2018-10-15 09:49:31",
        "grace_period_end_time": "2018-10-16 09:49:31",
        "certificate": {
          "name": "CN=DEMO of SK TSA 2014,OU=TSA,O=AS Sertifitseerimiskeskus,C=EE",
          "subject": {
            "organisation": "AS Sertifitseerimiskeskus",
            "organisation_unit": "TSA",
            "country": "EE",
            "common_name": "DEMO of SK TSA 2014"
          },
          "issuer": {
            "organisation": "AS Sertifitseerimiskeskus",
            "country": "EE",
            "common_name": "TEST of EE Certification Centre Root CA",
            "email": "[email protected]"
          },
          "valid_from": "2014-09-02 13:06:51",
          "valid_to": "2024-09-02 13:06:51",
          "value": "Base64 encoded PEM certificate"
        },
        "is_ltv_timestamp": true,
        "is_archived": true,
        "is_valid": true,
        "valid_to": "2024-09-02 13:06:51",
        "signature_value": "Base64 encoded signature value"
      }
    ],
    "standard": "PDF",
    "category": "PDF/A-1B",
    "is_valid": true,
    "valid_to": "2024-09-02 13:06:51"
  },
  "file": {
    "name": "3db647dceab7c8c7d363f39417ff5310d620cd90",
    "digest": "52880e5e898a3dac5a64f24730f633fa3f555f7f",
    "content": "Base64 encoded file content"
  }
}

11. Document Sealing

Your access token must be configured to use this method. Please contact our developers if you need this feature here.

Seal document

POST /seal.json

This method is used for document e-sealing using Advanced Electronic Seal supported by Qualified Certificate. Private key is securely stored in HSM. Qualified Certificate for electronic seal can be issued by any qualified Certification Authority.

Required params

Name Type Example Description
type string pdf Document format. Possible values: pdf, pdflt, bdoc, edoc, adoc, adoc.cedoc, adoc.bedoc, adoc.gedoc, adoc.ggedoc, mdoc, mdoc.cedoc, mdoc.bedoc, mdoc.gedoc, mdoc.ggedoc, asice, xades (for XML files).
timestamp boolean true Timestamp.
language string EN Possible values: LT, LV, ET, IS, EN, RU.

Optional params

Name Type Required Description
pdf[files][0][name] string true File name (required for PDF signing)
pdf[files][0][content] string true Base64 encoded file content (required for PDF signing)
pdf[files][0][digest] string true SHA256 checksum of file content (required for PDF signing)
pdf[contact] string true Full name (required for PDF signing)
pdf[signing_purpose] string false Possible values: signature, registration. Default: signature.
pdf[reason] string false Text that will be displayed in visible signature
pdf[location] string true Signing location (required for PDF signing). Example: Vilnius
pdf[annotation][page] string false Page index for visible signature. Default: 1
pdf[annotation][top] string false Visible signature position from top. Default: 1
pdf[annotation][left] string false Visible signature position from left. Default: 1
pdf[annotation][width] string false Visible signature width. Default: 100
pdf[annotation][height] string false Visible signature height. Default: 40
pdf[annotation][text] string false Custom text for visible signature. Example: Signature: Jonas Jonaitis
pdf[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdf[certify] boolean false Certify document. Default: false
pdflt[files][0][name] string true File name (required for PDF-LT signing)
pdflt[files][0][content] string true Base64 encoded file content (required for PDF-LT signing)
pdflt[files][0][digest] string true SHA256 checksum of file content (required for PDF-LT signing)
pdflt[compliance_level] string false A|B (Required if not already set in document)
pdflt[titles][0][name] string false Document title (Required if not already set in document)
pdflt[titles][0][language] string false Title language (ex. lt-LT, required if not already set in document)
pdflt[authors][0][name] string false Author's full name or company name (Required if not already set in document)
pdflt[authors][0][code] string false Personal code or company code
pdflt[authors][0][address] string false 1428 Elm Street
pdflt[authors][0][email] string false E-mail of person or company
pdflt[authors][0][individual] boolean false true or false (Required if not already set in document)
pdflt[contact] string true Signer's full name (required for PDF-LT signing)
pdflt[reason] string false Text that will be displayed in visible signature
pdflt[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, resolution, end-of-execution, notarisation, copy-certification, authenticity
pdflt[location] string false Signing location. Example: Vilnius
pdflt[role] string false Signer role. Example: Manager
pdflt[note] string false Additional note about signing. Example. visa note
pdflt[signer_registration][date] string false Signer registration date. Example: 2012-01-01T12:12:12Z
pdflt[signer_registration][number] string false Signer registration number
pdflt[signer_registration][code] string false Signer registration code
pdflt[signer_reception][date] string false Signer reception date. Example: 2012-01-01T12:12:12Z
pdflt[signer_reception][number] string false Signer reception number
pdflt[signer_reception][code] string false Signer reception code
pdflt[signer_reception][receiver][name] string false Receiver's full name or company name (must be specified for reception)
pdflt[signer_reception][receiver][code] string false Personal code or company code
pdflt[signer_reception][receiver][address] string false 1428 Elm Street
pdflt[signer_reception][receiver][email] string false E-mail of person or company
pdflt[signer_reception][receiver][individual] boolean false true or false
pdflt[recipients][0][name] string false Recipient's full name or company name
pdflt[recipients][0][code] string false Personal code or company code
pdflt[recipients][0][address] string false 1428 Elm Street
pdflt[recipients][0][email] string false E-mail of person or company
pdflt[recipients][0][individual] boolean false true or false
pdflt[original_registrations][0][date] string false Original registration date. Example: 2012-01-01T12:12:12Z
pdflt[original_registrations][0][number] string false Original registration number
pdflt[original_registrations][0][code] string false Original registration code
pdflt[original_receptions][0][date] string false Original reception date. Example: 2012-01-01T12:12:12Z
pdflt[original_receptions][0][number] string false Original reception number
pdflt[original_receptions][0][code] string false Original reception code
pdflt[original_receivers][0][name] string false Receiver's full name or company name
pdflt[original_receivers][0][code] string false Personal code or company code
pdflt[original_receivers][0][address] string false 1428 Elm Street
pdflt[original_receivers][0][email] string false E-mail of person or company
pdflt[original_receivers][0][individual] boolean false true or false
pdflt[instance_identifier] string false Document instance identifier
pdflt[annotation][page] string false Page index for visible signature. Default: 1
pdflt[annotation][top] string false Visible signature position from top. Default: 1
pdflt[annotation][left] string false Visible signature position from left. Default: 1
pdflt[annotation][width] string false Visible signature width. Default: 100
pdflt[annotation][height] string false Visible signature height. Default: 40
pdflt[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdflt[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
adoc[files][0][name] string true File name (required for ADoc signing)
adoc[files][0][content] string true Base64 encoded file content (required for ADoc signing)
adoc[files][0][digest] string true SHA256 checksum of file content (required for ADoc signing)
adoc[files][0][type] string true Possible values: main, appendix, attachment
adoc[title] string false Document title. Required for BeDOC, GeDOC, GGeDOC when creating new ADOC document.
adoc[sort] string false Document sort.
adoc[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, notarisation, copy-certification
adoc[signer_individual_name] string false Full name (required for ADoc signing)
adoc[signer_position_name] string false Position, example: Director (required for ADoc signing)
adoc[signer_structural_subdivision] string false Department or division. Example: Accounting
adoc[signing_structure][content][] array false Define file element ID to sign it
adoc[signing_structure][signatures][] array false Define Signature elements ID`s to sign
adoc[signing_structure][metadata][signable][document][] array false Define document metadata element ID`s to sign
adoc[signing_structure][metadata][signable][authors][] array false Define author element ID`s to sign
adoc[signing_structure][metadata][signable][recipients][] array false Define recipient element ID`s to sign
adoc[signing_structure][metadata][signable][restrictions][] array false Define restriction element ID`s to sign
adoc[signing_structure][metadata][signable][registrations][] array false Define registration element ID`s to sign
adoc[signing_structure][metadata][signable][receptions][] array false Define reception element ID`s to sign
adoc[authors][0][name] string false Full name or company name
adoc[authors][0][code] string false Personal code or company code
adoc[authors][0][address] string false 1428 Elm Street
adoc[authors][0][individual] boolean false true or false
adoc[case_id][0] string false Index of the case (volume) the document is assigned to
adoc[storage] string false Storage location
adoc[recipients][0][name] string false Full name or company name
adoc[recipients][0][code] string false Personal code or company code
adoc[recipients][0][address] string false 1428 Elm Street
adoc[recipients][0][individual] boolean false true or false
adoc[restrictions][0][content_restriction] boolean false true or false
adoc[restrictions][0][metadata_restriction] boolean false true or false
adoc[restrictions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[restrictions][0][reason] string false Restricted use
adoc[registrations][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[registrations][0][number] string false Document registration number
adoc[registrations][0][registrar][individual_name] string false Full name
adoc[registrations][0][registrar][position_name] string false Position, example: Director
adoc[registrations][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[registrations][0][code] string false Code of the company or institution which registered the document
adoc[receptions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[receptions][0][number] string false Document’s registration number assigned upon reception
adoc[receptions][0][registrar][individual_name] string false Full name
adoc[receptions][0][registrar][position_name] string false Position, example: Director
adoc[receptions][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[receptions][0][receiver][name] string false Receiver’s full name or company name
adoc[receptions][0][receiver][code] string false Receivers personal or company code
adoc[receptions][0][receiver][address] string false Receiver’s address
adoc[receptions][0][receiver][individual] boolean false true or false
adoc[agent][responsibilities][0][area] string false Possible values: creation, management, relocation, storage, deletion
adoc[agent][responsibilities][0][responsible][individual_name] string false Full name
adoc[agent][responsibilities][0][responsible][position_name] string false Position, example: Director
adoc[agent][responsibilities][0][responsible][structural_subdivision] string false Department or division. Example: Accounting
bdoc[files][0][name] string true File name (required for BDoc signing)
bdoc[files][0][content] string true Base64 encoded file content (required for BDoc signing)
bdoc[files][0][digest] string true SHA256 checksum of file content (required for BDoc signing)
bdoc[country] string false Estonia
bdoc[city] string false Tallinn
bdoc[postal_code] string false 01234
bdoc[position] string false Manager
edoc[files][0][name] string true File name (required for EDoc signing)
edoc[files][0][content] string true Base64 encoded file content (required for EDoc signing)
edoc[files][0][digest] string true SHA256 checksum of file content (required for EDoc signing)
edoc[country] string false Riga
edoc[city] string false Latvia
edoc[postal_code] string false 01234
edoc[position] string false Manager
asice[files][0][name] string true File name (required for ASiCe signing)
asice[files][0][content] string true Base64 encoded file content (required for ASiCe signing)
asice[files][0][digest] string true SHA257 checksum of file content (required for ASiCe signing)
asice[country] string false Estonia
asice[city] string false Tallinn
asice[postal_code] string false 01234
asice[position] string false Manager
xades[files][0][name] string true File name (required for XML signing)
xades[files][0][content] string true Base64 encoded file content (required for XML signing)
xades[files][0][digest] string true SHA257 checksum of file content (required for XML signing)
xades[signature_level] string false Signature level, possible values: B (XAdES-BASELINE-B), T (XAdES-BASELINE-T), LT (XAdES-BASELINE-LT)

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "signature_id": "Signature1",
    "file": {
        "name": "4cbd00b6d9c0ad58d0763ff77951d8aa246413e8_signed.pdf",
        "content": "Base64 encoded e-sealed file content",
        "digest": "SHA1 checksum of e-sealed file content"
    },
}

12. Deprecated

Get user certificates

POST /mobile/certificate.json

Method is deprecated, please use /v2/mobile/certificate.json instead.

Required params

Name Type Example Description
phone string +37200000766 Phone number
code string 60001019906 Personal code

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "signing_certificate": {
        "name": "/C=LT/CN=TESTNUMBER,SEVENTH/SN=TESTNUMBER/GN=SEVENTH/serialNumber=PNOLT-60001019906",
        "subject": {
            "country": "LT",
            "common_name": "TESTNUMBER,SEVENTH",
            "surname": "TESTNUMBER",
            "name": "SEVENTH",
            "serial_number": "PNOLT-60001019906"
        },
        "issuer": {
            "country": "EE",
            "organisation": "AS Sertifitseerimiskeskus",
            "common_name": "TEST of EID-SK 2016",
        },
        "valid_from": "2016-09-19T17:33:02+03:00",
        "valid_to": "2020-09-17T23:59:59+03:00",
        "value": "Base64 encoded PEM certificate"
    },
    "authentication_certificate": {
        "name": "/C=LT/CN=TESTNUMBER,SEVENTH/SN=TESTNUMBER/GN=SEVENTH/serialNumber=PNOLT-60001019906",
        "subject": {
            "country": "LT",
            "common_name": "TESTNUMBER,SEVENTH",
            "surname": "TESTNUMBER",
            "name": "SEVENTH",
            "serial_number": "PNOLT-60001019906"
        },
        "issuer": {
            "country": "EE",
            "organisation": "AS Sertifitseerimiskeskus",
            "common_name": "TEST of EID-SK 2016"
        },
        "valid_from": "2016-09-19T17:33:00+03:00",
        "valid_to": "2020-09-17T23:59:59+03:00",
        "value": "Base64 encoded PEM certificate"
    },
    "country": "LT",
    "code": "60001019906",
    "name": "SEVENTH",
    "surname": "TESTNUMBER"
}

Login

POST /mobile/login.json

Method is deprecated, please use /v2/mobile/login.json instead.

Required params

Name Type Example Description
phone string +37200000766 Phone number
code string 60001019906 Personal code

Optional params

Name Type Required Description
language string false Language for messages displayed on the phone screen.
message string false Message displayed on the phone screen.

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "country": "LT",
    "certificate": {
        "name": "/C=LT/O=TELIA LT/CN=TESTNUMBER,SEVENTH/SN=TESTNUMBER/GN=SEVENTH/serialNumber=PNOLT-60001019906",
        "subject": {
            "country": "LT",
            "common_name": "TESTNUMBER,SEVENTH",
            "surname": "TESTNUMBER",
            "name": "SEVENTH",
            "serial_number": "PNOLT-60001019906"
        },
        "issuer": {
            "country": "EE",
            "organisation": "AS Sertifitseerimiskeskus",
            "common_name": "TEST of EID-SK 2016"
        },
        "valid_from": "2016-09-19T17:33:00+03:00",
        "valid_to": "2020-09-17T23:59:59+03:00",
        "value": "Base64 encoded PEM certificate"
    },
    "code": "60001019906",
    "name": "SEVENTH",
    "token": "1542053873",
    "control_code": "4001",
    "surname": "TESTNUMBER"
}

Login Status

GET /mobile/login/status/{token}.json

Method is deprecated, please use /v2/mobile/login/status/{token}.json instead.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Token received from /mobile/login call

Requirements

Content
Replaces header if set

{
    "status": "waiting"
}

or

{
    "status": "ok"
}

Check certificate before signing hash

POST /sc/certificate/check.json

Check if given certificate can be used for signing. Method checks if certificate is valid, trusted and not revoked.

Required params

Name Type Example Description
certificate string Base64 encoded PEM certificate

Requirements

Content
Replaces header if set

{
    "status": "ok"
}

Verify signature value against certificate

POST /sc/hash/verify.json

Check if signature value was generated with private key related to given certificate.

Required params

Name Type Example Description
certificate string Base64 encoded PEM certificate
hash string OGVlMjZjMDQ1MzY5ZTg5OWIwOGNhN2FlMmM0MWM0 ZTg3MGU4MDA4YQ== Hash to sign
hash_algorithm string SHA256 Digest algorithm used for signing (SHA1|SHA256|SHA512)
signature_value string Kzm1vL6Q== Base64 encoded signature value

Requirements

Content
Replaces header if set

{
    "status": "ok"
}

Login

POST /sc/login.json

Initializes user identification with given certificate.

Method returns a session token. data-to-be-signed along with the user data extracted from certificate. Session token is required if you want to fetch the signed document.

Required params

Name Type Example Description
certificate string Base64 encoded PEM certificate

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "token": "142783ae43430b3c733dddcd6bde25e616e8a837",
    "dtbs": "NjcwZmVmZTA5YzUzODY4ZjEyYzQ1ZDFkNjliMDE5NTRjMjM3YWQ2NA==",
    "algorithm": "sha256",
    "name": "Dokobit",
    "surname": "Sandbox Login Certificate",
    "code": "",
    "email": "[email protected]",
    "country": "LT",
    "certificate": {
        "name": "/C=LT/L=Vilnius/OU=Dokobit Sandbox/CN=Dokobit Sandbox Login Certificate/[email protected]",
        "subject": {
            "country": "LT",
            "organisation_unit": "Dokobit Sandbox",
            "common_name": "Dokobit Sandbox Login Certificate",
            "email": "[email protected]"
        },
        "issuer": {
            "country": "LT",
            "organisation": "Dokobit",
            "organisation_unit": "Dokobit Sandbox",
            "common_name": "Dokobit Sandbox Root CA",
            "email": "[email protected]"
        },
        "valid_from": "2015-02-12T15:30:38+02:00",
        "valid_to": "2025-02-09T15:30:38+02:00",
        "value": "Base64 encoded PEM certificate"
    }
}

Login Verification

POST /sc/login/verify.json

Checks signature value received from SmartCard device to confirm user identification. Returns “ok” - on success, “waiting” - when process is pending or “unknown” when process has timed out or has been canceled.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Session token received from /sc/login call
signature_value string Signature value

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "name": "TEST",
    "surname": "CARD",
    "code": "60001019906",
    "email": "[email protected]",
    "country": "LT"
}

SC Prepare

POST /sc/prepare.json

Prepares the document for signing with a SmartCard. Similarly to the mobile signing this method accepts a list of common and a list of document format-specific parameters.

Method returns a session token and data-to-be-signed. Provide received data for Dokobit applet to sign and use session token if you want to fetch the signed document.

Required params

Name Type Example Description
certificate string Base64 encoded PEM certificate
type string pdf Document format. Possible values: pdf, pdflt, bdoc, edoc, adoc, adoc.cedoc, adoc.bedoc, adoc.gedoc, adoc.ggedoc, mdoc, mdoc.cedoc, mdoc.bedoc, mdoc.gedoc, mdoc.ggedoc, asice.
timestamp boolean true Timestamp
language string EN Possible values: LT, EN, ET, IS

Optional params

Name Type Required Description
pdf[files][0][name] string true File name
pdf[files][0][content] string true Base64 encoded file content
pdf[files][0][digest] string true SHA256 checksum of file content
pdf[contact] string true Full name
pdf[signing_purpose] string false Possible values: signature, registration. Default: signature.
pdf[reason] string false Text that will be displayed in visible signature
pdf[location] string true Signing location. Example: Vilnius
pdf[attachments][0][name] string true File name
pdf[attachments][0][content] string true Base64 encoded file content
pdf[attachments][0][digest] string true SHA256 checksum of file content
pdf[attachments][0][description] string false Description of attachment file
pdf[annotation][page] string false Page index for visible signature. Default: 1
pdf[annotation][top] string false Visible signature position from top. Default: 1
pdf[annotation][left] string false Visible signature position from left. Default: 1
pdf[annotation][width] string false Visible signature width. Default: 100
pdf[annotation][height] string false Visible signature height. Default: 40
pdf[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdf[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdf[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
pdflt[files][0][name] string true File name
pdflt[files][0][content] string true Base64 encoded file content
pdflt[files][0][digest] string true SHA256 checksum of file content
pdflt[compliance_level] string false A|B (Required if not already set in document)
pdflt[titles][0][name] string false Document title (Required if not already set in document)
pdflt[titles][0][language] string false Title language (ex. lt-LT, required if not already set in document)
pdflt[authors][0][name] string false Author's full name or company name (Required if not already set in document)
pdflt[authors][0][code] string false Personal code or company code
pdflt[authors][0][address] string false 1428 Elm Street
pdflt[authors][0][email] string false E-mail of person or company
pdflt[authors][0][individual] boolean false true or false
pdflt[contact] string true Signer's full name
pdflt[reason] string false Text that will be displayed in visible signature
pdflt[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, resolution, end-of-execution, notarisation, copy-certification, authenticity
pdflt[location] string false Signing location. Example: Vilnius
pdflt[role] string false Signer role. Example: Manager
pdflt[note] string false Additional note about signing. Example. visa note
pdflt[signer_registration][date] string false Signer registration date. Example: 2012-01-01T12:12:12Z
pdflt[signer_registration][number] string false Signer registration number
pdflt[signer_registration][code] string false Signer registration code
pdflt[signer_reception][date] string false Signer reception date. Example: 2012-01-01T12:12:12Z
pdflt[signer_reception][number] string false Signer reception number
pdflt[signer_reception][code] string false Signer reception code
pdflt[signer_reception][receiver][name] string false Receiver's full name or company name (must be specified for reception)
pdflt[signer_reception][receiver][code] string false Personal code or company code
pdflt[signer_reception][receiver][address] string false 1428 Elm Street
pdflt[signer_reception][receiver][email] string false E-mail of person or company
pdflt[signer_reception][receiver][individual] boolean false true or false
pdflt[recipients][0][name] string false Recipient's full name or company name
pdflt[recipients][0][code] string false Personal code or company code
pdflt[recipients][0][address] string false 1428 Elm Street
pdflt[recipients][0][email] string false E-mail of person or company
pdflt[recipients][0][individual] boolean false true or false
pdflt[original_registrations][0][date] string false Original registration date. Example: 2012-01-01T12:12:12Z
pdflt[original_registrations][0][number] string false Original registration number
pdflt[original_registrations][0][code] string false Original registration code
pdflt[original_receptions][0][date] string false Original reception date. Example: 2012-01-01T12:12:12Z
pdflt[original_receptions][0][number] string false Original reception number
pdflt[original_receptions][0][code] string false Original reception code
pdflt[original_receivers][0][name] string false Receiver's full name or company name
pdflt[original_receivers][0][code] string false Personal code or company code
pdflt[original_receivers][0][address] string false 1428 Elm Street
pdflt[original_receivers][0][email] string false E-mail of person or company
pdflt[original_receivers][0][individual] boolean false true or false
pdflt[instance_identifier] string false Document instance identifier
pdflt[annotation][page] string false Page index for visible signature. Default: 1
pdflt[annotation][top] string false Visible signature position from top. Default: 1
pdflt[annotation][left] string false Visible signature position from left. Default: 1
pdflt[annotation][width] string false Visible signature width. Default: 100
pdflt[annotation][height] string false Visible signature height. Default: 40
pdflt[annotation][text] string false Custom text for visible signature. Example: Signature: \n Jonas Jonaitis
pdflt[annotation][type] string false Custom annotation type. Available types: text, image. Default: image
pdflt[annotation][add_personal_code] boolean false Render personal code in annotation. Default: false
adoc[files][0][name] string true File name
adoc[files][0][content] string true Base64 encoded file content
adoc[files][0][digest] string true SHA256 checksum of file content
adoc[files][0][type] string true Possible values: main, appendix, attachment
adoc[title] string false Document title. Required for BeDOC, GeDOC, GGeDOC when creating new ADOC document.
adoc[sort] string false Document sort.
adoc[signing_purpose] string false Possible values: signature, confirmation, visa, conciliation, registration, registration-of-incomming-documents, acknowledgement, notarisation, copy-certification
adoc[signer_individual_name] string false Full name
adoc[signer_position_name] string false Position, example: Director
adoc[signer_structural_subdivision] string false Department or division. Example: Accounting
adoc[signing_structure][content][] array false Define file element ID to sign it
adoc[signing_structure][signatures][] array false Define Signature elements ID`s to sign
adoc[signing_structure][metadata][signable][document][] array false Define document metadata element ID`s to sign
adoc[signing_structure][metadata][signable][authors][] array false Define author element ID`s to sign
adoc[signing_structure][metadata][signable][recipients][] array false Define recipient element ID`s to sign
adoc[signing_structure][metadata][signable][restrictions][] array false Define restriction element ID`s to sign
adoc[signing_structure][metadata][signable][registrations][] array false Define registration element ID`s to sign
adoc[signing_structure][metadata][signable][receptions][] array false Define reception element ID`s to sign
adoc[authors][0][name] string false Full name or company name
adoc[authors][0][code] string false Personal code or company code
adoc[authors][0][address] string false 1428 Elm Street
adoc[authors][0][individual] boolean false true or false
adoc[case_id][0] string false Index of the case (volume) the document is assigned to
adoc[storage] string false Storage location
adoc[recipients][0][name] string false Full name or company name
adoc[recipients][0][code] string false Personal code or company code
adoc[recipients][0][address] string false 1428 Elm Street
adoc[recipients][0][individual] boolean false true or false
adoc[restrictions][0][content_restriction] boolean false true or false
adoc[restrictions][0][metadata_restriction] boolean false true or false
adoc[restrictions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[restrictions][0][reason] string false Restricted use
adoc[registrations][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[registrations][0][number] string false Document registration number
adoc[registrations][0][registrar][individual_name] string false Full name
adoc[registrations][0][registrar][position_name] string false Position, example: Director
adoc[registrations][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[registrations][0][code] string false Code of the company or institution which registered the document
adoc[receptions][0][date] string false xsd:dateTime or xsd:date with specified timezone fragment. Example: 1994-11-05T13:15:30Z
adoc[receptions][0][number] string false Document’s registration number assigned upon reception
adoc[receptions][0][registrar][individual_name] string false Full name
adoc[receptions][0][registrar][position_name] string false Position, example: Director
adoc[receptions][0][registrar][structural_subdivision] string false Department or division. Example: Accounting
adoc[receptions][0][receiver][name] string false Receiver’s full name or company name
adoc[receptions][0][receiver][code] string false Receivers personal or company code
adoc[receptions][0][receiver][address] string false Receiver’s address
adoc[receptions][0][receiver][individual] boolean false true or false
adoc[agent][responsibilities][0][area] string false Possible values: creation, management, relocation, storage, deletion
adoc[agent][responsibilities][0][responsible][individual_name] string false Full name
adoc[agent][responsibilities][0][responsible][position_name] string false Position, example: Director
adoc[agent][responsibilities][0][responsible][structural_subdivision] string false Department or division. Example: Accounting
bdoc[files][0][name] string true File name
bdoc[files][0][content] string true Base64 encoded file content
bdoc[files][0][digest] string true SHA256 checksum of file content
bdoc[country] string false Estonia
bdoc[city] string false Tallinn
bdoc[postal_code] string false 01234
bdoc[position] string false Manager
edoc[files][0][name] string true File name
edoc[files][0][content] string true Base64 encoded file content
edoc[files][0][digest] string true SHA256 checksum of file content
edoc[country] string false Latvia
edoc[city] string false Riga
edoc[postal_code] string false 01234
edoc[position] string false Manager
asice[files][0][name] string true File name
asice[files][0][content] string true Base64 encoded file content
asice[files][0][digest] string true SHA256 checksum of file content
asice[country] string false Estonia
asice[city] string false Tallinn
asice[postal_code] string false 01234
asice[position] string false Manager
hash_algorithm string false Hash algorithm used for signing

Requirements

Parameters

Content
Replaces header if set

{
    "status": "ok",
    "algorithm": "sha256",
    "token": "6e790b4da4328f832d2dfbc3052be6578759e339",
    "dtbs_hash": "ebaf8c71e22a708d4aee873bcd26ee6906ccf0e31c7b108d1b675d71d98e1f1b",
    "dtbs": "MYGEMBgGCSqGSIb3DQEJAzELBgkqhkiG9w0BBwEwLwYJKoZIhvcNAQkEMSIEIJ2TWXRPehKU84agQCzkipoPp5QolU42VfMaAVeYSlHPMDcGCyqGSIb3DQEJEAIvMSgwJjAkMCIEIO1Yq8OVGZ/4lYnin17GP3U3Ojb0v2vaIudEM5rOSOhw"
}

SC Sign

POST /sc/sign.json

Returns the signed document.

Required params

Name Type Example Description
token string 32165a4d65a4sda654d5asd32a1sd3a2d1 Session token received from /sc/prepare call
signature_value string Signature value

Requirements

Content
Replaces header if set

{
    "status": "ok",
    "signature_id": "Signature1",
    "file": {
        "name": "4cbd00b6d9c0ad58d0763ff77951d8aa246413e8_signed.pdf",
        "content": "Base64 encoded signed file content",
        "digest": "SHA1 checksum of signed file content"
    },
}