DOCTAG Documentation

With Doctag, you can have every existing PDF document electronically signed by business partners and customers in real time. It is specially designed for cross-company processes and any existing process can be mapped. The platform works peer-to-peer without a central data pool and with encryption technology.

Wherever several parties work together on the same document or need to access a valid version of it including signatures of the parties, Doctag is the right solution.

Typical use cases:

  • Electronic consignment or delivery notes
  • Fraud-proof electronic diplomas and testimonials
  • Electronic licences or concessions
  • Real-time evidence in international trade
  • QR label on goods instead of printed documents
  • Replace paper documents in transport, trade and administrative processes
  • and many more…

Subsections of DOCTAG Documentation

Chapter 1

1. Getting started

The decentral approach is very important to us. That is why Doctag is available in two versions: You can host this web service yourself (DOCTAG/own) or use the managed version (DOCTAG/cloud).

First step: Which installation to choose?

Subsections of 1. Getting started

Which installation to choose?

The decentral approach is very important to us. That is why Doctag is available in two versions: You can host this web service yourself (DOCTAG/own) or use the managed version (DOCTAG/cloud).

Hosted instance: DOCTAG/cloud

For a simple and quick start, choose the DOCTAG/cloud variant. Here, we handle the operation, maintenance and backup for your Doctag server. No IT expertise is required. In a few minutes, you will receive your fully functional Doctag server.

Start with hosted version

On-premise instance: DOCTAG/own

The second option is to operate Doctag on your own private server. This variant is for users who have solid knowledge of operating their own web server.

The installation is carried out according to the steps shown in the chapter Installation.

Start with on-premise version

Requirements

Only for DOCTAG/own on-premise instances

Note

The hosted service DOCTAG/cloud has no requirements.

Your own server will have to meet the following requirements:

  • Web server with root access
  • Java
  • MongoDB
  • optional: reverse proxy

Installation

Only for DOCTAG/own on-premise instances

Note

The hosted service DOCTAG/cloud has an easy step-by-step start-up procedure under setup.doctag.de

Installation on Debian/Ubuntu

1. Installing the basic technology

To install the required software use

sudo apt-get install openjdk-14-jre

sudo apt-get install mongodb

2. Download latest release of DOCTAG/own

Load the release from https://www.doctag.de/download/

Example command:

wget https://www.doctag.de/download/docsrv-2023-11-29.jar

# Rename file
mv docsrv-2023-11-29.jar docsrv.jar

java -jar docsrv.jar

Now visit http://127.0.0.1:16097/install in your browser to initially setup database hostname and root user.

3. Running as systemd service

Create a systemd service file named /etc/systemd/system/docsrv.service with the following content:

[Unit]
Description=Docserver for serving documents
After=network.service

[Service]
Restart=always
RestartSec=10
TimeoutSec=300
# Please customize the working directory
WorkingDirectory=/root/ 
ExecStart=/usr/bin/java -Xms256m -Xmx512m -XX:MaxDirectMemorySize=512M -XX:MaxGCPauseMillis=50 -jar docsrv.jar


[Install]
WantedBy=multi-user.target

Reload systemd and start Doctag instance

sudo systemctl daemon-reload
sudo service docsrv start

To view the log output please execute

sudo journalctl -u docsrv.service -f

To automatically boot service on system start

sudo systemctl enable docsrv.service

4. Create cronjob for automatic mail import (if required)

The import of documents can be automated using the automatic mail import function. The mail import can be executed at a desired interval using the following cron job:

crontab -e
*/15 * * * * curl https://<your Docserver domain>/internal/cron > /var/log/doctag_cron.log

In this example, the job is executed every 15 minutes.

5. Ready to login and work

Now DOCTAG/own is ready to work. Open http://127.0.0.1:16097/ in your browser and login with the root user you created in step 2.

For correct operation of the server, the server needs to have a valid SSL certificate and a domain. Please refer to the chapter Donain and SSL to get more information.

Domain and SSL

Only for DOCTAG/own on-premise instances

Note

The hosted service DOCTAG/cloud has no domain and SSL requirements.

We recommend caddy for terminating SSL traffic and for certificate generation. Please follow the instruction to get a working installation that provides you with SSL certificates for your Doctag domain.

Please Note: It is impossible for Doctag to share a domain name with other http based services. Thus please give Doctag a dedicated subdomain e.g. doctag.your_hostname.com.

Most importantly, please make sure to have a valid DNS record pointing to the host where Doctag is running.

To setup Doctag behind a TLS terminating reverse proxy please install caddy first. Once you have caddy installed on your machine, please edit the caddy config file in /etc/caddy/Caddyfile. It shall have the following content:

doctag.your_hostname.com {
   reverse_proxy 127.0.0.1:16097
}

Please note that you have to replace doctag.your_hostname.com with the acutal hostname you want to use. Once you created that config file, you can reload caddy by executing:

sudo service caddy reload

Caddy will now automatically fetch Let’s Encrypt certificates and make sure that your Doctag instance is only accessible via TLS. The certificates will be automatically managed by caddy, so you don’t need to renew them repeatetly.

Doctag is now available behind a reverse proxy and has valid TLS certificates.

Updating

Only for DOCTAG/own on-premise instances

Note

The hosted service DOCTAG/cloud is automatically kept up to date. No updates need to be installed.

1. Download latest release of DOCTAG/own

Load the release from https://www.doctag.de/download/

Example command:

wget https://www.doctag.de/download/docsrv-2023-11-29.jar

# Rename file
mv docsrv-2023-11-29.jar docsrv.jar

2. Restart services

Reload systemd and start Doctag instance

sudo systemctl daemon-reload
sudo service docsrv restart

3. Check log

To view the log output please execute

sudo journalctl -u docsrv.service -f

Database backup

Only for DOCTAG/own on-premise instances

Note

The hosted service DOCTAG/cloud performs automatic backups. No configuration is necessary.

The instructions for the database backup are in progress.

Chapter 2

2. User guide

This chapter deals with the practical use of DOCTAG.

Subsections of 2. User guide

1. Initial login and creation of the participant certificate

Every Doctag instance needs at minimum one participant certificate to work properly.

Log in with the access data provided during setup. Go to the settings and create the first participant certificate for a location. In order for your Doctag server to work, you need at least one participant certificate. A free certificate is included with DOCTAG/cloud. If you install DOCTAG/own on your own server, you will later have to pay for the certificates.

You will receive a registration letter by post, which serves to validate your address. As soon as you have carried out the steps mentioned in the letter, the certificate will be shown as valid in the portal and your Doctag server is ready for use. The next logical steps would be to create users and configure a workflow.

2. Creating users

Under the menu item Settings, you will find the menu item Users. Here, you create a user for all individuals who are to use Doctag. After storing the user, additional advanced settings are available to you via the Edit function, such as changing a password or deleting users. In the coming version, you will also be able to specify at this point whether a user is allowed to make changes to the settings of the Doctag server – i.e. has an admin role.

Furthermore, you can generate a QR code via the menu item Doctag App, with which the user can connect to your Doctag server via DOCTAG App. You can also easily share this QR code with the user via e-mail.

For more information on the DOCTAG App, please watch the corresponding video.

3. Creating a workflow

Workflows represent the system’s core. Here, each company creates the required roles within the document, as well as additional fields. The workflows are located under Settings > System > Workflows.

First, we create a new workflow and give it a name. Now we add the roles needed for the document – for example, sender, carrier and consignee. In the last step, we now consider which fields the respective contractual partner needs, in order to fulfil its rights and obligations as per the document.

Workflow data types / fields

Type Description
Text input Free text field for entering remarks, numbers or indicators
Checkbox A box to check off, allowing a question to be answered with yes or no
Attach file Creates a field that can be used to upload additional, subordinate documents
Signing A field in which a person can sign or draw a sketch, for example
E-Mail A field in which a person can enter an e-mail address to get a copy of the document after having signed it

In most cases, it makes sense to create a separate role for document upload. By doing so, a document can be uploaded by one of the participants at any time, and independently of a specific role.

The workflow structure shown serves as an example. There are no limits to your creativity, and any special requirement should be able to be mapped.

4. Start with first document

Take any sample document in PDF format. Make sure you have defined a workflow beforehand, as shown in the corresponding section.

Click on “Add Document” in the document list. Select the sample document and click Upload. Place the QR code in a free space in the document by dragging it with the mouse and select the workflow that applies to the document.

Now the document is available in the document list and the signature process can be initiated.

Each document has a detail page that provides additional information. You can access this page by clicking on the Folder open symbol.

The document upload can also be automated. To do this, watch the video on Configuring Mailimport.

5. Configure Mailimport

In addition to the manual upload of PDFs, the Doctag server also has a mail import function. This makes it very easy to import the documents by e-mail. The import function can also be automated to permanently retrieve new documents in a future release.

Mailimport checks whether the e-mail contains a PDF file. Then a check is made if the PDF document contains a valid Doctag in the form of a QR code. Only if this check is also successful the document will be imported. This lends the mail import function a certain level of spam protection.

If there are several QR codes in the document (e.g. one on each page of the PDF), the document is separated before each QR code and created as a separate document in the Doctag server.

Just how you can create a Doctag in the form of a QR code can be found in the corresponding section.

You can reach the menu item Mailimport via Settings > System > E-mail. The access data for a mailbox are required here. The mailbox should only be used by the Doctag server.

The mail import function always uses the standard workflow of the Doctag server. This is the workflow marked with an asterisk in the settings.

Chapter 3

3. Use cases

In this chapter we present some specific adaptations in detail

Subsections of 3. Use cases

Electronic Consignment Note

The Electronic Consignment Note with Doctag enables simple cooperation at document level with minimal access requirements – even between unknown partners. The process can be individually adapted to every company’s own processes.

Doctag converts every PDF document into an unchangeable and falsification-proof consignment note. The latest encryption technology is used here, which is also used by cryptocurrencies, for example.

The workflows represent the system’s core. Here, each company creates the required roles within the freight contract, as well as additional fields. These can be fields for free text entries – such as HGV registration numbers or notes – or a field for uploading additional documents to be attached to the consignment note. Examples include delivery notes, customs or dangerous goods documents.

The original document forms page 1 of the consignment note. The individual signature protocol is shown form from page 2 onwards.

Chapter 4

4. Common issues

Here is an overview of common issues when using the Docserver: Common issues

Subsections of 4. Common issues

Common Issues

Here is an overview of common issues when using the Docserver:

**Issue:**When using the mailimport, the Docserver creates sign requests instead of importing the documents. Why?