Samples overview

The following topics describe the samples provided with OPS, based on the name of the applicable subfolder in the Sample folder.

BasicSample

This sample presents a very basic text conversion job with a subsequent result download. No arguments are needed unless you wish to change the service URL.

DocumentClassificationSample

This sample presents a new job that classifies one or more documents according to the predefined types in a .dcp file. With this sample, for example, you can decide if a supplied document is an invoice or a business letter.

FileShareSample

FileShareSample contains the same setup as SimpleJobSample and shows how to submit input files located on a file share to OPS. This sample is built into SimpleJobSample for Java and Python as an optional argument, so in those cases a separate folder is not available..

FormProcessingSample

This sample presents a new job that processes a form in accordance with predefined parameters and returns the raw data. An.ftl file provides the processing parameters.

HandlingFolderWatcherResultSample

This sample keeps track of the finished FolderWatcher jobs and the results from those copied into a user-defined folder. This sample is only provided in C#/.NET since it does not make use of the OPS API.

NotificationSample

This samples presents details on how to submit a job to OPS, for which you will be notified about its completion by the server. You can notice that the .NET versions are split into separate client and server samples, which must be run separately. The Java and Python versions utilize a simpler port-listening technique in the same sample, and this code runs right after job submission. The approach you implement in your programs will depend entirely on the deployment environment.

SimpleJobSample

This sample presents, as the name implies, a simple job setup. It builds on the BasicSample and adds a range of parameters, such as languages, quality, deskew, tradeoffs, rotations, and form recognition.

StatusServiceSample

The StatusServiceSample is a simple example of how to poll OPS for its status. This sample does not submit a job but merely polls the API.

WorkflowSample

This sample demonstrates how to submit a job with a workflow described in an .xml file. The Workflow file is submitted as an input file with with Workflow as the enum type.