Web Services

9/6/2018


With DocVacBasic, DocVacGold or DocVacEnterprise, you can upload documents, check on their status and retrieve information once document processing is complete using our web services.  Our documentation is based on the C#/Visual Studio code that is used to test them and which would be our default choice writing any custom code to integrate their usage with your IT systems. However you can use different clients to test or use most of them (not involving file upload/download), one example of which is Postman and another is Excel 2016.

The sample code shows both the standard Http status codes that can be returned e.g. 200=OK and how to use the information embedded in anything returned by the web service.  A schedule of charges for using our web services can be found here. These usage charges are designed to be be minimal or zero if the web services are used correctly.  There are no usage charges with normal use of the documentvacuum.com website by an individual with a browser (automated use is billed the same way as using web services and will result in account suspension or termination). 

A. Document Status

You retrieve document status using https://documentvacuum.com/api/PDocDetailNcApi/GetPDocDetailNcLatest?version=0.  You can call this every 5 minutes with no charge, or a total of 288 calls in a day.  When invoked, the service retrieves document status with a cache timeout of 120 seconds, therefore at any point in time, you know the status as of somewhere between 0 and 7 minutes ago and immediately after invoking the call you know the status as of somewhere between 0 and 2 minutes ago. The web service retrieves your documents that have been active in the last 4 hours.  The C# code use to test GetPDocDetailNcLatest can be found here, further information on the PDocDetail class used to create the list of PDocDetails returned by the web service can be found here and more information on the various status levels can be found here.  If you prefer to use an https endpoint, please let us know.

B. Upload Files

You upload files using https://documentvacuum.com/api/MyDocNcApi/UploadFiles?version=0&uploadMode=anonymousAuth where the last parameter takes one of three values: normal, reference and anonymousAuth.  The webservice consumes a list of documents, we suggest uploading one document per web service call, especially if the file uploaded is large.  The C# code used to test UploadFiles can be found here and more information on uploadMode can be found here.

C. PDocDetailNc for 1 PDocDetail by pDocId

You retrieve document status for one document using https://documentvacuum/api/PDocDetailNcApi/GetPDocDetailNc?version=0&pDocId=911 where the id field 911 or some other integer is a valid id for one of your documents.  You can use this when the status is more than 4 hours old and the document no longer appears in the information returned by GetPDocDetailNcLatest.  The C# code used to test GetPDocDetailNc can be found here.

D. PDocRowXmlNc

You can retrieve the underlying XML extracted from a document using https://documentvacuum.com/api/PDocRowXmlNcApi/GetPDocRowXmlNc?version=0&pDocId=911 where the id field of 911 or some other integer is a valid id for one of your documents.  The underlying XML can be useful for debugging why a particular search does not work, although we would generally use the website to do this.  We provide the same information as a web service to faciliate additional user provided logic and extraction using the raw data.  The data is not quite raw since certain cleanup logic is applied post extraction.  The C# code used to test GetPDocRowXmlNc can be found here and further information on the PDocRowXmlNc class used to create the list of PDocRowXmlNc returned by the web service, including how the location coordinates work, can be found here.

E. PDocRowClassificationNc for Normal Documents (DocVacGold and DocVacEnterprise

You can retrieve the conclusions for a document processed in normal mode using https://documentvacuum.com/api/PDocRowClassificationNcApi/GetPDocRowClassificationNc?version=0&pDocId=911 where the id field of 911 or some other integer is a valid id for one of your documents.  The C# code used to test GetPDocRowClassificationNc can be found here and further information on the PDocRowClassificationNc class used to create the list of PDocRowClassificationNc returned by the web service can be found here.

F. PdrxstnMappingNc for anonymousAuth and Reference Documents

You can retrieve information for a document processed in either anonymousAuth or reference mode using https://documentvacuum.com/api/PdrxstnMappingNcApi/GetPdrxstnMappingNc?version=0&pDocId=911 where the id field of 911 or some other integer is a valid id for one of your documents.  The C# code used to test GetPdrxstnMappingNc can be found here and further information on the PdrxstnMappingNc class used to create the list of PdrxstnMappingNc returned by the web service can be found here.

G. PdrxDataTypeNc

Data types consist of standard data types e.g. integer and custom data types that are specific to your reference document(s) e.g. DogBreed, values {Basset Hound, Beagle}.  You can retrieve a combined list of data types using https://documentvacuum.com/api/PdrxDataTypeNcApi/GetPdrxDataTypeNc?version=0.  The C# code used to test GetPdrxDataTypeNc can be found here and further information on the PdrxDataTypeNc class used to create the list of PdrxDataTypeNc returned by the web service can be found here.

H. GetDataTableNc

You can retrieve the tables extracted from a document when the document is uploaded with TableExtraction = true using https://documentvacuum.com/api/DocVacDataTableNcApi/GetDataTableNc?version=0&pDocId=911 where pDocId is a valid document id.  The C# code used to test GetDataTableNc can be found hereand further information on the DocVacDataTableNc class used to create the list of DocVacDataTableNc returned by the web service can be found here .

I. GetDataTableRowNc

You can retrieve the rows associated with tables extracted from a document when the document is uploaded with TableExtraction = true using https://documentvacuum.com/api/DocVacDataTableRowNcApi/GetDataTableRowNc?version=0&pDocId=911 where pDocId is a valid document id.  The C# code used to test GetDataTableRowNc can be found hereand further information on the DocVacDataTableRowNc class used to create the list of DocVacDataTableRowNc returned by the web service can be found here.

J. GetDataTablePdrxNc

You can retrieve data points associated with tables extracted from a document when the document is uploaded with TableExtraction = true using https://documentvacuum.com/api/DocVacDataTablePdrxNcApi/GetDataTablePdrxNc?version=0&pDocId=911 where pDocId is a valid document id.  The C# code used to test GetDataTablePdrxNc can be found here and further information on the DocVacDataTablePdrxNc class used to create a list of DocVacDataTablePdrxNc returned by the web service can be found here.


See also:
DocVac Basic vs. DocVac Gold vs DocVac Enterprise

Other articles:
Billing - DocVacBasic & DocVacGold
Web Services - Ws - GetPDocPageClassificationNc
Web Services - Usage Charges
Postman
Web Services - Class - PDocDetailNc
Web Services - Class - PDocPageNc
Web Services - Class - PDocRowClassificationNc
Web Services - Class - PDocRowXmlNc
Web Services - Class - PdrxDataTypeNc
Web Services - Class - PdrxstnMappingNc
more