Should you not find your question in this FAQ, please visit our forum to pose your question to the TWAIN Direct® user community.
For more detailed information about TWAIN Direct®, please visit our specification page and download the TWAIN Direct® User’s Guide
The Basics
What is TWAIN Direct®?
- TWAIN Direct is a new standard, a new common protocol that eliminates the need for scanner drivers at the OS-level. It also makes connectivity by applications easier whether they are desktop, mobile or browser-based apps.
- TWAIN Direct supports application-to-scanner communication through a network connection (wired or wireless). Users select the scanner from their app without having to install a scanner driver for that scanner on their local device. (Think “AirPrint” for scanners.)
- TWAIN Direct is zero-footprint, mobile-ready, and royalty-free!
- TWAIN Direct is simple and easy to use while expediting application development for a feature-rich end user experience.
How is TWAIN Direct® different from TWAIN Classic?
Historically, developers had to decide which Image Capture API to use (e.g., TWAIN Classic, WIA, ISIS, SANE, ICA, etc.) in order to “image-enable” an application. This decision was primarily influenced by the operating system and the API’s supported by the scanner hardware, which presented challenges for developers to switch to different operating systems, different scanner products, or to support new ones.
Now, using the TWAIN Direct specification, developers have a protocol to allow their applications to communicate with scanners without the need for proprietary scanner drivers regardless of operating system. The TWAIN Direct initiative is designed to minimize the coding required to support fully-featured image capture solutions in developer applications.
TWAIN Direct reduces development time from weeks to days, supports modern programming languages, and delivers better user experience with a full feature set best suited for any application. Additionally, developers with existing TWAIN Classic drivers can take advantage of TWAIN Direct today.
What is TWAIN Local?
TWAIN Local is a secure RESTful API protocol for local area networks. Discovery follows Google’s Privet 1.0 specification. Once a scanner has been discovered and a communication channel is established the TWAIN Direct language is used for commands, responses, and metadata. PDF/raster is used for transferring images.
What is TWAIN Cloud?
TWAIN Cloud is a secure RESTful API protocol for the cloud. It extends the TWAIN Local protocol with additional commands for registering and pairing applications and scanners. Once a communication channel is established the TWAIN Direct language is used for commands, responses, and metadata. PDF/raster is used for transferring images.
What is TWAIN Bridge?
TWAIN Bridge can turn any USB TWAIN scanner in to a TWAIN Direct device. As the name suggests, TWAIN Bridge is a piece of software that runs on a PC to provide support between existing scanners that support the TWAIN Classic specification today and the new TWAIN Direct specification. TWAIN Bridge makes scanners available to mobile or any other devices on the LAN.
TWAIN Bridge makes a traditional USB-scanner look like a fully-embedded TWAIN Direct scanner to any TWAIN Direct-enabled application because by using TWAIN Bridge, the device IS effectively a TWAIN Direct device.
What is TWAIN Sidecar?
TWAIN Sidecar is small, self-contained device that connects to the network and a USB scanner. It contains TWAIN Direct code, scanner-specific code and handles all job traffic between the network and the scanner. An example might be a Raspberry Pi device, developed and offered by the OEM. It contains code for one or more scanners, perhaps the OEMs entire scanner line so that the OEM can offer one Sidecar device to be connected with any of their products. Suddenly traditional USB-connected, driver-based scanners can become network attached to TWAIN Direct devices by simply adding the TWAIN Sidecar option.
How are TWAIN Local and TWAIN Cloud different? What are the benefits to implementing one or the other, or both?
TWAIN Cloud is an extension to the TWAIN Local protocol. TWAIN Local assumes that the local area network is secure, there is no authentication step, however all communication between the client and the scanner is through HTTPS. TWAIN Cloud requires authentication with the cloud. It also requires that images are encrypted at rest.
What operating systems can I code TWAIN Direct for?
TWAIN Direct is a cloud or web based protocol so operating system is irrelevant. Scanning can be accomplished via a web browser through the cloud or server based web application.
Benefits
How does TWAIN Direct® benefit me or my organization?
APPLICATION DEVELOPERS
Now, using the TWAIN Direct specification, developers have a protocol to allow their applications to communicate with scanners without the need for proprietary scanner drivers regardless of operating system. The TWAIN Direct initiative is designed to minimize the coding required to support fully-featured image capture solutions in developer applications.
TWAIN Direct reduces development time from weeks to days, supports modern programming languages, and delivers better user experience with a full feature set best suited for any application. Additionally, developers with existing TWAIN Classic drivers can take advantage of TWAIN Direct today.
TWAIN Direct is primarily focused on application vendors. Applications represent the needs of the end users, and there are considerably more application writers than scanner vendors. Improving the development experience in this area offers the most potential for influencing the market. The expectation is that focusing on this segment will inevitably lead to benefits for the other segments.
The design of TWAIN Direct makes it reasonable to customize parts of a system while still being TWAIN compliant. You are not locked in to certain ecosystems and instead are using a universal standard. TWAIN Direct eliminates the need for drivers which slow things down and require a lot of testing on multiple clients and operating systems. With TWAIN Direct, you now have the ability to switch between scanner vendors and know you can work with the output.
MANUFACTURERS / OEMs
Support & Development: The majority of engineering development, OS-compatibility, updates and end user support is consumed by scanner driver development and support. By eliminating the scanner driver from the configuration, the end user or IT support agent is no longer responsible or impacted by driver issues. Scanner support is built into the TWAIN Direct code and becomes a single addressable connection by the end user through the application.
TWAIN Bridge and Sidecar: While a network scanner that is fully-configured with TWAIN Direct services presents a single and complete solution, it is not the only path to TWAIN Direct, especially for scanners with no network connectivity. Scanner OEMs do not need to do substantial development to convert their product line of traditional USB-connection, driver-based scanners to TWAIN Direct. As the industry transitions to TWAIN Direct, today’s OEMs can offer TWAIN Direct solutions through TWAIN Bridge & Sidecar.
Without changing their current hardware SKUs or configurations, OEMs can offer a companion Bridge or Sidecar to their current scanners. These (Bridge or Sidecar) will connect to their current USB-connection scanners to the network and register them as TWAIN Direct devices, appearing as full TWAIN Direct citizens. OEMs minimize their risk, development schedules and expenses. Distribution also benefits by keeping SKU counts low, not doubling so that each hardware scanner has a USB and TWAIN Direct version.
What are some of the features available when scanning documents?
TWAIN direct standard offer a wide range of common features most document scanners have by default, like simplex/duplex, blank page removal, resolution, etc… The nice thing about TD is that if a feature is not available on a device a document is still generated minus the requested feature requested by the scanner. OEMS who offer TWAIN directly natively on their device can customize available feature for use within a TWAIN direct environment adding additional value.
What document security features are available?
TWAIN Direct does support the ability of adding encrypted transmissions & passwords between device and application adding an additional layer of security beyond transmission protocols.
Adoption & Implementation
Why should I adopt TWAIN Direct®?
TWAIN Direct accesses the full functionality of scanners with less code, it is human readable, and it can be added using any of today’s popular programming languages.
Also important to note is that TWAIN Direct focuses on scanning success. It strives to deliver an image to the user, even when the scanner is unable to support some or all of the application’s requests. The application handles any conflict resolution for unsupported scanner features. In the end, the scan always happens at the best capability of the scanner.
TWAIN will supply tools for supporting legacy TWAIN devices and TWAIN Direct devices. Application writers will be able to develop TWAIN Direct code using existing TWAIN scanners. As native TWAIN Direct scanners come into the market, they’ll replace the older legacy scanners with no changes to the application code.
How do I implement TWAIN Direct®?
The TWAIN Working Group (TWG) provides a Specification document that describes how to generate and interpret TWAIN Direct. Today, the TWAIN Working Group provides free open source sample code to its members, but does not sell any TWAIN Direct products. Once released in Q3-2019, the TWAIN Direct code will be freely available to the industry. Application and scanner vendors use this Specification (and sample code) to develop their own products while adding their own UI/UX and branding customizations.
How long does it take to implement TWAIN Direct®?
TWAIN Direct reduces development time from weeks to days, supports modern programming languages, and delivers better user experience with a full feature set best suited for any application. Additionally, developers with existing TWAIN Classic drivers can take advantage of TWAIN Direct today.
If I already use TWAIN Classic, how do I move over to TWAIN Direct®? How does this impact my development or product line?
TWAIN Bridge has the potential to turn any USB TWAIN scanner in to a TWAIN Direct experience. As the name suggests, TWAIN Bridge is a piece of software that runs on a PC to provide support between existing scanners that support the TWAIN Classic specification today and the new TWAIN Direct specification. TWAIN Bridge makes scanners available to mobile or any other devices on the LAN.
There is a way for existing USB scanners to expose a TWAIN Direct interface without modifying the base hardware (referred to as a sidecar solution). To accomplish this, the scanner is plugged into a small device that implements TWAIN Direct for it. This device could come from the scanner vendor or a third party provider.
What additional security considerations are needed in TWAIN Direct vs. TWAIN Classic?
With TWAIN Classic the network endpoint was the USB-attached computer which had an IP address and things such as software firewall, SSL certificate and a login authentication, to name a few things. However, with TWAIN Direct, there is no computer with the scanner is attached directly to the network. So all the things needed to secure a traditional computer endpoint with an IP address still need to be considered and whether an organization implements them or not, they need to be considered.
Which current USB scanners can be retro-fitted via TWAIN Bridge and/or a side car to become TWAIN Direct compatible?
While we’ve only heard of limited testing with several manufacturers and several scanner models, theoretically any scanner that support TWAIN Classic can become a TWAIN Direct-compatible scanner via TWAIN Bridge. It’s important to note that TWAIN Bridge is intended to be a utility to enable TWAIN Direct compatibly for USB-attached scanners until TWAIN Direct is widely accepted and embedded directly into the scanners themselves eventually.
How do I compile the PDF Raster images in my application?
There are a variety of PDF libraries that can be used the compile the individual raster pages in to a multi-page documents.
How secure is TWAIN Direct and what are my available communication protocols.
Currently TWAIN direct has limited authentication capabilities to the cloud, however the next release of TWAIN direct will include support for OATH 2 and SAML 2.0. for multifactor /enterprise authentication.
Getting Started
When will TWAIN Direct®become available?
TWAIN Direct will become publicly available in Q3 of 2019. TWAIN Working Group member companies can access the code today for development. For more information on membership, please contact Erin Dempsey (erin.dempsey@twain.org)
How can I differentiate myself from competitors using TWAIN Direct® (TWAIN Cloud)?
The open source sample code for TWAIN Cloud serves as a passthrough for commands and data. Cloud developers can extend TWAIN Cloud by adding additional services to this code.
The TWAIN Direct language is also extensible. Scanner vendors can expose custom features. Client applications can take advantage of these features, either optionally, letting the scanner continue if the feature isn’t supported. Or the client application can require the scanner to reject a task if a required feature isn’t available.
The authentication system provided in the open source sample is based on OpenId Connect. The authorization token is OAuth2. Vendors can enhance security and asset control using standards like SAML 2.0
What resources are available to implement TWAIN Direct?
- The TWAIN Working group provides a Specification document that describes how to generate and interpret TWAIN Direct
- The TWAIN Working group provides free open source sample code, but does not sell any TWAIN Direct products
- Application and scanner vendors use this Specification (and sample code) to develop their own products. The sample code available from TWG is developer sample code, not intended to be released to end-users as is. This gives each developer the opportunity to add their own UI/UX and branding customizations.
What platforms or operating systems does TWAIN Direct® support?
TWAIN Direct will work on any platform or operating system. Open source sample code is provided for Windows, Android, and iOS. With a little work the sample code can be made to work on Linux and macOS.
Will support for TWAIN Classic end with the introduction of TWAIN Direct®?
No, the TWAIN Working Group will continue to provide support for the TWAIN Classic specification (latest v 2.4).
I’ve downloaded the TWAIN Direct code from GitHub but I’m not quite sure where to start?
TWAIN Direct is an open source project supported by the TWAIN Working Group so we provide the best support we can as a non-profit organization. So for the best support of a TWAIN Direct project we suggest organizations to join with one of our two membership options. Membership offers premium access to participate in technical meetings where you can learn, ask questions and contribute to the overall direction of the project. It’s well worth the investment.