Show/Hide Toolbars

Therefore Web API Programming Interface 1.0

If you need to add many streams to a new or already existing document, you can use batch operations to upload files on the server. Thus you can control uploading the files. For example, show uploading the progress or handle network errors for every file. Batch operations should also be used for uploading sets of huge files to save client and server resources.

 

Below you can see a typical scenario of creating a new document by using batch operations:

1.Execute the StartCreateDocumentBatch operation and store the BatchId.

2.Execute the UploadDocStreamToBatch operation for every stream of the document by using the BatchId from step 1.

3.Execute the SubmitCreateDocumentBatch operation to create a new document in Thereforeā„¢ with streams uploaded in step 2. In this step you can also specify the index data of the document.

 

For updating existing document you have to do the following steps:

1.Execute the StartUpdateDocumentBatch operation and store the BatchId.

2.Execute the UploadDocStreamToBatch operation for every stream of the document by using the BatchId from step 1.

3.Execute the SubmitUpdateDocumentBatch to update the document in Thereforeā„¢ with streams uploaded in step 2. In this step you can update the index data of the document as well.

 

 

Expiration period of batch:

 

note

Operations SubmitCreateDocumentBatch/SubmitUpdateDocumentBatch should be executed within a certain interval of time, after you have started the bath by StartCreateDocumentBatch/StartUpdateDocumentBatch respectively.
This interval is set to 30 minutes by default and can be changed by the Windows Registry setting BatchCacheItemExpirationMinutes. After this period of time, the bath expires and cannot be used anymore. When you try to execute operations with an expired BatchId you will get a fault exception.

Ā© 2024 Therefore Corporation, all rights reserved.