POST api/ProcessFileAsync?ocrLib={ocrLib}

POST: Used to upload a file (Multipart MIME) for OCR. The file will be queued up for processing. Use GetProcessedFile to try to retrieve the resulting .txt file. The client will need to keep checking to see if the file is ready since processing time is variable. Query String parameter ocrLib is either 'std' (default) or 'pro' (?ocrLib={std|pro})

Request Information

URI Parameters

NameDescriptionTypeAdditional information
ocrLib

string

Default value is std

Body Parameters

None.

Response Information

Resource Description

The path to the output file. (a .txt file) Use that path when trying to retrieve the processed file via GetProcessed file API

ProcessFileResult
NameDescriptionTypeAdditional information
_inputFile

echoes back the name of the input file. Use to confirm the file sent

string

None.

_inputFileLength

# of bytes received. Use to confirm all the data was transmitted

integer

None.

_outputFilePath

For the async operation, use this to retreive the output file

string

None.

Response Formats

application/json, text/json

Sample:
{
  "_inputFile": "sample string 1",
  "_inputFileLength": 2,
  "_outputFilePath": "sample string 3"
}

application/xml, text/xml

Sample:
<ProcessFileResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/OCRService.Controllers">
  <_inputFile>sample string 1</_inputFile>
  <_inputFileLength>2</_inputFileLength>
  <_outputFilePath>sample string 3</_outputFilePath>
</ProcessFileResult>