Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions _data/full_tree.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,16 +64,16 @@ tree_list:
path: /extended-usage/file-import.html
- name: Configuring System Messages
path: /extended-usage/system-message-configuration.html
- name: Set Up the Dynamsoft Service
- name: Set Up the Dynamic Web TWAIN Service
path: /extended-usage/dynamsoft-service-configuration.html
- name: UI Customization
path: /extended-usage/ui-customization.html
- name: Using the DWT RESTful API
path: /extended-usage/restful-api.html
- name: Barcode Recognition
path: /extended-usage/barcode-processing.html
- name: PDF Handling
path: /extended-usage/pdf-processing.html
#- name: PDF Compressor (Beta)
# path: /extended-usage/pdf-compression.html
- name: Buffer Caching
path: /extended-usage/buffer-caching.html
- name: Remote Scan
Expand All @@ -88,7 +88,7 @@ tree_list:
# # path: /getstarted/helloworld.html
# - name: License
# path: /about/license.html
# - name: Set up Dynamsoft Service
# - name: Set up Dynamic Web TWAIN Service
# path: /indepth/deployment/service.html
# - name: Deploy to Server
# path: /indepth/deployment/server.html
Expand Down
3 changes: 2 additions & 1 deletion _includes/version-list.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<span class="fullVersionHistory">
<ul class="fullVersionInfo">
<li onclick="changeVersion(this)">Latest Version (18.5.1)</li>
<li onclick="changeVersion(this)">Latest Version (19.0)</li>
<li onclick="changeVersion(this)">Version 18.5.1</li>
<li onclick="changeVersion(this)">Version 18.4</li>
<li onclick="changeVersion(this)">Version 18.3</li>
<li onclick="changeVersion(this)">Version 18.1</li>
Expand Down
2 changes: 1 addition & 1 deletion _layouts/default-layout-OLD.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
</footer>

<script type="text/javascript">
$(".currentVersion").text("latest version (18.5.1)");
$(".currentVersion").text("latest version (19.0)");
anchors.add();
UrlReplace();
FullTreeMenuList('{{page.needAutoGenerateSidebar}}', '{{page.needGenerateH3Content}}');
Expand Down
4 changes: 2 additions & 2 deletions articles/extended-usage/advanced-initialization.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ permalink: /extended-usage/advanced-initialization.html

As presented in the standard [initialization guide]({{site.general-usage}}initialization.html), DWT instantiates a default `WebTwain` object in its default configuration. Here, we offer some alternative ways to instantiate `WebTwain` objects, as well as ways to alter the configuration of `WebTwain` objects.

> Note: jsDelivr currently has problems delivering the Dynamsoft Service installer (`https://cdn.jsdelivr.net/npm/dwt@latest/dist/dist/DynamsoftServiceSetup.msi`) due to [size restrictions](https://www.jsdelivr.com/documentation#id-configuring-a-default-file-in-packagejson); please consider hosting this particular resource file elsewhere. UKPKG is currently unaffected. For information about the Dynamsoft Service, learn more [here]({{site.extended-usage}}dynamsoft-service-configuration.html).
> Note: jsDelivr currently has problems delivering the Dynamic Web TWAIN Service installer (`https://cdn.jsdelivr.net/npm/dwt@latest/dist/dist/DynamicWebTWAINServiceSetup.msi`) due to [size restrictions](https://www.jsdelivr.com/documentation#id-configuring-a-default-file-in-packagejson); please consider hosting this particular resource file elsewhere. UKPKG is currently unaffected. For information about the Dynamic Web TWAIN Service, learn more [here]({{site.extended-usage}}dynamsoft-service-configuration.html).

## Auto-Loading with CDN/Package Manager Resources

Expand Down Expand Up @@ -77,7 +77,7 @@ APIs used:

Setting values for `Dynamsoft.DWT.AutoLoad` and `Dynamsoft.DWT.Containers` results in identical startup behavior for resources obtained from CDNs and package managers to resources obtained from the official SDK.

> Note: jsDelivr currently has problems delivering the Dynamsoft Service installer (`https://cdn.jsdelivr.net/npm/dwt@latest/dist/dist/DynamsoftServiceSetup.msi`) due to [size restrictions](https://www.jsdelivr.com/documentation#id-configuring-a-default-file-in-packagejson); please consider hosting this particular resource file elsewhere. UKPKG is currently unaffected. For information about the Dynamsoft Service, learn more [here]({{site.extended-usage}}dynamsoft-service-configuration.html).
> Note: jsDelivr currently has problems delivering the Dynamic Web TWAIN Service installer (`https://cdn.jsdelivr.net/npm/dwt@latest/dist/dist/DynamicWebTWAINServiceSetup.msi`) due to [size restrictions](https://www.jsdelivr.com/documentation#id-configuring-a-default-file-in-packagejson); please consider hosting this particular resource file elsewhere. UKPKG is currently unaffected. For information about the Dynamic Web TWAIN Service, learn more [here]({{site.extended-usage}}dynamsoft-service-configuration.html).

## Configuring Default `WebTwain` Instances

Expand Down
20 changes: 10 additions & 10 deletions articles/extended-usage/buffer-caching.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
layout: default-layout
needAutoGenerateSidebar: true
title: Dynamic Web TWAIN SDK Guide - Buffer Caching
keywords: Dynamic Web TWAIN, Documentation, Deployment, Dynamsoft Service, caching, buffer,
breadcrumbText: Dynamsoft Service
description: Dynamic Web TWAIN SDK Documentation Dynamsoft Service Page
keywords: Dynamic Web TWAIN, Documentation, Deployment, Dynamic Web TWAIN Service, caching, buffer,
breadcrumbText: Dynamic Web TWAIN Service
description: Dynamic Web TWAIN SDK Documentation Dynamic Web TWAIN Service Page
permalink: /extended-usage/buffer-caching.html
---

# Buffer Caching

The DWT image buffer is controlled by the Dynamsoft Service. The Dynamsoft Service can run in either 32-bit mode or 64-bit mode. Before DWT version 15.0, the service ran in 32-bit mode by default. This meant it could not address more than 2GB of physical memory. <!--We introduced the 64-bit version of the service in DWT version 14.0. -->Starting in version 15.0, the Dynamsoft Service runs as 64-bit by default on 64-bit operating systems, which removes the 2GB memory limit. To limit memory usage, DWT can cache data to disk to free up memory.
The DWT image buffer is controlled by the Dynamic Web TWAIN Service(formerly known as Dynamsoft Service). The Dynamic Web TWAIN Service can run in either 32-bit mode or 64-bit mode. Before DWT version 15.0, the service ran in 32-bit mode by default. This meant it could not address more than 2GB of physical memory. <!--We introduced the 64-bit version of the service in DWT version 14.0. -->Starting in version 15.0, the Dynamic Web TWAIN Service runs as 64-bit by default on 64-bit operating systems, which removes the 2GB memory limit. To limit memory usage, DWT can cache data to disk to free up memory.

## Disk Caching

Expand All @@ -24,17 +24,17 @@ You can also set how much memory `Dynamic Web TWAIN` can use before images start

Although you can scan and load as many images as you like, you may want to handle them in smaller volumes when doing further processing. For example, when dealing with extremely large volumes, you should not try to upload or save the images all at once as that would be too time consuming and prone to errors.

## Save the encrypted image caches in local Dynamsoft Service folder
## Save the encrypted image caches in local Dynamic Web TWAIN Service folder

In certain scenarios, there may be requirements to store encrypted image caches on a local disk for temporary data storage or backup purposes. For instance, when scanning a large batch of documents, accidentally closing the web page can result in the loss of scanned data, necessitating scanning the documents again. This issue can be mitigated by backing up the data before closing the page.

Starting from version 18.5, Dynamic Web TWAIN introduces a new feature that facilitates developers in securely storing image caches in encrypted form within the Dynamsoft Service folder. This feature offers several advantages:
Starting from version 18.5, Dynamic Web TWAIN introduces a new feature that facilitates developers in securely storing image caches in encrypted form within the Dynamic Web TWAIN Service(formerly known as Dynamsoft Service) folder. This feature offers several advantages:

- Data is stored securely in encrypted form.
- The speed of storing data locally and loading it back into the Dynamic Web TWAIN buffer is fast.
- The stored data remains intact even when the `WebTwain` instance is destroyed.

> Note: Since the storage folder is located within the Dynamsoft Service directory, the stored data will be lost if Dynamsoft Service is uninstalled. Upgrading the Dynamsoft Service will not affect the storage folder.
> Note: Since the storage folder is located within the Dynamic Web TWAIN Service directory, the stored data will be lost if Dynamic Web TWAIN Service is uninstalled. Upgrading the Dynamic Web TWAIN Service will not affect the storage folder.

### Create a storage folder

Expand All @@ -50,9 +50,9 @@ var storageItemUid = await DWTObject.createLocalStorage(folderSettings);
Please ensure to set a strong password to enhance data security, especially in multi-user login scenarios.

The local directory of the created storage folder is under
- Windows: `C:\Windows\SysWOW64\Dynamsoft\DynamsoftServicex64_{versionnumber}\storage`
- macOS: `Go > Applications > Dynamsoft > DynamsoftServicex64_{versionnumber} > {installed version No.} > storage`
- Linux: `/opt/dynamsoft/DynamsoftService/storage`
- Windows: `C:\Program Files (x86)\Dynamsoft\Dynamic Web TWAIN Service {versionnumber}\storage`(version 18.5.1 and earlier `C:\Windows\SysWOW64\Dynamsoft\DynamsoftServicex64_{versionnumber}\storage`)
- macOS: `Go > Applications > Dynamsoft > Dynamic Web TWAIN Service {versionnumber} > storage`(version 18.5.1 and earlier `Go > Applications > Dynamsoft > DynamsoftServicex64_{versionnumber} > {installed version No.} > storage`)
- Linux: `/opt/dynamsoft/Dynamic Web TWAIN Service {versionnumber}/storage`(version 18.5.1 and earlier `/opt/dynamsoft/DynamsoftService/storage`)

**Save image caches**

Expand Down
44 changes: 22 additions & 22 deletions articles/extended-usage/dynamsoft-service-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,32 @@
layout: default-layout
needAutoGenerateSidebar: true
noTitleIndex: true
title: Dynamic Web TWAIN SDK Deployment - Dynamsoft Service
keywords: Dynamic Web TWAIN, Documentation, Deployment, Dynamsoft Service
breadcrumbText: Dynamsoft Service
description: Dynamic Web TWAIN SDK Documentation Dynamsoft Service Page
title: Dynamic Web TWAIN SDK Deployment - Dynamic Web TWAIN Service
keywords: Dynamic Web TWAIN, Documentation, Deployment, Dynamic Web TWAIN Service
breadcrumbText: Dynamic Web TWAIN Service
description: Dynamic Web TWAIN SDK Documentation Dynamic Web TWAIN Service Page
permalink: /extended-usage/dynamsoft-service-configuration.html
---

# Configuring the Dynamsoft Service
# Configuring the Dynamic Web TWAIN Service

> This article is meant exclusively for the Desktop Service Edition of Dynamic Web TWAIN.

The Dynamsoft Service is the core piece of Dynamic Web TWAIN when running in Service mode. It handles the communication between hardware (scanner, webcam, etc.) and browser, manages the image buffer, and coordinates data between different modules.
The Dynamic Web TWAIN Service is the core piece of Dynamic Web TWAIN when running in Service mode. It handles the communication between hardware (scanner, webcam, etc.) and browser, manages the image buffer, and coordinates data between different modules.

### IP and ports

The Dynamsoft Service uses `localhost` and `18622` `18625` ports for HTTP connection and `18623` `18626` ports for HTTPS connection.
The Dynamic Web TWAIN Service uses `localhost` and `18622` `18625` ports for HTTP connection and `18623` `18626` ports for HTTPS connection.
These ports can be configured in the `DSConfiguration.ini` file located in:
- Windows: `C:\Windows\SysWOW64\Dynamsoft\DynamsoftServicex64_{versionnumber}`
- macOS: `Go > Applications > Dynamsoft > DynamsoftServicex64_{versionnumber} > {installed version No.}`
- Linux: `/opt/dynamsoft/DynamsoftService`
- Windows: `C:\Program Files (x86)\Dynamsoft\Dynamic Web TWAIN Service {versionnumber}`(version 18.5.1 and earlier `C:\Windows\SysWOW64\Dynamsoft\DynamsoftServicex64_{versionnumber}`)
- macOS: `Go > Applications > Dynamsoft > Dynamic Web TWAIN Service {versionnumber}`(version 18.5.1 and earlier `Go > Applications > Dynamsoft > DynamsoftServicex64_{versionnumber} > {installed version No.}`)
- Linux: `/opt/dynamsoft/Dynamic Web TWAIN Service {versionnumber}`(version 18.5.1 and earlier `/opt/dynamsoft/DynamsoftService`)

### Access-Control-Allow-Origin

For security purposes, you may want the Dynamsoft Service to only respond to requests from specified origins. Starting from Dynamic Web TWAIN version 18.5, this can be achieved by adding `Access-Control-Allow-Origin` in the `DSConfiguration.ini` file.
For security purposes, you may want the Dynamic Web TWAIN Service to only respond to requests from specified origins. Starting from Dynamic Web TWAIN version 18.5, this can be achieved by adding `Access-Control-Allow-Origin` in the `DSConfiguration.ini` file.

By default, the `Access-Control-Allow-Origin` setting is not configured in the ini file. This means that the Dynamsoft Service can respond to requests from any origin.
By default, the `Access-Control-Allow-Origin` setting is not configured in the ini file. This means that the Dynamic Web TWAIN Service can respond to requests from any origin.

You can set multiple origins by using commas as the separator, and `http://` or `https://` needs to be specified before each origin. If there is a port for the origin, please remember to specify it. If not specified, the default port is 80.

Expand Down Expand Up @@ -59,9 +59,9 @@ When a request comes from a different origin, a CORS error message will be displ

![CORS-error-console]({{site.assets}}imgs/CORS-error-console.png)

## Installation of Dynamsoft Service
## Installation of Dynamic Web TWAIN Service

On a desktop, when a new user accesses a web page using Dynamic Web TWAIN SDK for the first time, he will be prompted to install the Dynamsoft Service. This is a built-in behaviour of the library. The prompt will display the download link. Once the installer is downloaded, the installation process will take just a few seconds.
On a desktop, when a new user accesses a web page using Dynamic Web TWAIN SDK for the first time, he will be prompted to install the Dynamic Web TWAIN Service. This is a built-in behaviour of the library. The prompt will display the download link. Once the installer is downloaded, the installation process will take just a few seconds.

The prompt comes up when you try to [create a WebTwain instance]({{site.indepth}}features/initialize.html#creating-the-webtwain-instance) in Service mode.

Expand All @@ -74,26 +74,26 @@ On **Linux**, instead of double clicking, the downloaded installer needs to be r
- Debian / Ubuntu

```bash
sudo dpkg -i DynamsoftServiceSetup.deb
sudo dpkg -i DynamicWebTWAINServiceSetup.deb
```

- Fedora

```bash
sudo rpm -ivh DynamsoftServiceSetup.rpm
sudo rpm -ivh DynamicWebTWAINServiceSetup.rpm
```

Once the installation is done, the users can click the orange sentence 'click here to verify completion' or refresh the page to start using Dynamic Web TWAIN.

![Initialization]({{site.assets}}imgs/Initialization-2.png)

### Msg: Dynamsoft service is not installed / Dynamic Web TWAIN is not installed
### Msg: Dynamic Web TWAIN Service is not installed / Dynamic Web TWAIN is not installed

If Dynamsoft Service is not installed, users may receive the error 'The Dynamic Web TWAIN module is not installed' when accessing an application that uses Dynamic Web TWAIN.
If Dynamic Web TWAIN Service is not installed, users may receive the error 'The Dynamic Web TWAIN module is not installed' when accessing an application that uses Dynamic Web TWAIN.

## Related Resources:

* <a href="{{site.faq}}what-does-dynamsoft-service-do-on-end-user-machine.html" target="_blank">What does Dynamsoft Service do?</a>
* <a href="{{site.faq}}service-prompting-to-install-repeatedly.html" target="_blank">I have installed the Dynamsoft Service on an end-user machine but still got asked to install it repeatedly. Why?</a>
* <a href="{{site.faq}}how-to-uninstall-dynamsoft-service.html" target="_blank">How to uninstall Dynamsoft Service?</a>
* <a href="{{site.faq}}can-i-install-dynamsoft-service-silently.html" target="_blank">Can I install Dynamsoft Service silently?</a>
* <a href="{{site.faq}}what-does-dynamsoft-service-do-on-end-user-machine.html" target="_blank">What does Dynamic Web TWAIN Service do?</a>
* <a href="{{site.faq}}service-prompting-to-install-repeatedly.html" target="_blank">I have installed the Dynamic Web TWAIN Service on an end-user machine but still got asked to install it repeatedly. Why?</a>
* <a href="{{site.faq}}how-to-uninstall-dynamsoft-service.html" target="_blank">How to uninstall Dynamic Web TWAIN Service?</a>
* <a href="{{site.faq}}can-i-install-dynamsoft-service-silently.html" target="_blank">Can I install Dynamic Web TWAIN Service silently?</a>
2 changes: 1 addition & 1 deletion articles/extended-usage/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ This set of guides builds on the fundamental features covered in the standard us

- [Advanced DWT Initialization]({{site.extended-usage}}advanced-initialization.html)
- [Configuring System Messages]({{site.extended-usage}}system-message-configuration.html)
- [Set Up the Dynamsoft Service]({{site.extended-usage}}dynamsoft-service-configuration.html)
- [Set Up the Dynamic Web TWAIN Service]({{site.extended-usage}}dynamsoft-service-configuration.html)
- [UI Customization]({{site.extended-usage}}ui-customization.html)
- [Barcode Recognition]({{site.extended-usage}}barcode-processing.html)
- [PDF Handling]({{site.extended-usage}}pdf-processing.html)
Expand Down
23 changes: 23 additions & 0 deletions articles/extended-usage/restful-api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
layout: default-layout
needAutoGenerateSidebar: true
title: Using the RESTful API
keywords: Dynamic Web TWAIN, extended guide, advanced, RESTful API, REST, REST service, RESTful service, webtwain, Dynamic Web TWAIN Service, RESTful integration
breadcrumbText: RESTful API
description: RESTful API
permalink: /extended-usage/restful-api.html
---

# Using the RESTful API

By default, Dynamic Web TWAIN consists of the Dynamic Web TWAIN Service installed and running on a system, connected to a web application which integrates the Dynamic Web TWAIN SDK. To use DWT to access scanners on other platforms and using other programming languages, you can use the [DWT Service RESTful API]({{ site.api }}restful.html). This allows desktop, mobile, and server-side applications to access the DWT Service installed on the scanner host (local or server) in a simple, stateless, and standardized manner.

The RESTful API simply returns scanned documents as streams of image files to the client, and **does not use the DWT Viewer**. This is because **the RESTful API functions entirely using the DWT Service**, and is viewer-agnostic. You may choose to feed the scanned images to any viewer, including a DWT Viewer in your application that you instantiate separately, if desired.

Here is a collection of tutorials on creating sample applications that use the DWT RESTful API in various platforms and languages.

- [Node.js](https://www.dynamsoft.com/codepool/rest-api-node-document-scanning.html)
- [Flutter](https://www.dynamsoft.com/codepool/flutter-twain-scanner-digitize-document.html)
- [Java](https://www.dynamsoft.com/codepool/java-twain-document-scanning.html)
- [Python](https://www.dynamsoft.com/codepool/python-twain-wia-sane-document-scanner.html)
- [.NET](https://www.dynamsoft.com/codepool/dotnet-twain-wia-sane-document-scanner.html)
Loading