Objective
It allows to change the content of document, where the new content is provided in Base64Binary format. (Only the content is changed, the profile is not modified). DST must be provided.
Parameters
Parameter | Description | Type |
document | The content of the document to upload to the DM Library. | String |
form | The name of the form used to create new folders. | String |
library | eDOCS library | String |
user | User name | String |
password | User password | String |
docNumber | Document number. Only one document number is allowed. | String |
version | Version number of the document. (1, 2, 3 …). | String |
subVersion | Subversion letter (A, B, C, …). No letter will be used by default. | String |
client | Optional parameter for the client code | String |
project | Optional parameter for the project code | String |
Rest Invoke
- http://localhost:port/GSService/xml/ or http://localhost:port/GSService/json/
- UriTemplate:
- “/ReplaceContentAsBinary/?document={document}&form={form}&library={library}&user={user}&password={password}&docNumber={docNumber}&version={version}&subVersion={subVersion}&client={client}&project={project}”
- “/ReplaceContentAsBinaryDST/?document={document}&form={form}&library={library}&user={user}&dst={dst}&docNumber={docNumber}&version={version}&subVersion={subVersion}&client={client}&project={project}”
Example
http://localhost:8732/GSService/xml/ReplaceContentAsBinary/document=RXN0byBlcyB1bmEgcHJ1ZWJhIHBhcmEgc3ViaXIgdW4gZG9jdW1lbnRvIHkgY29udmVydGlyIHN1IGNvbnRlbmlkbyBhIEJhc2U2NA==&form=LAWPROF&library=DMTESTLEGAL&user=admin&password=owc123&docNumber=756&version=1&subVersion=!
The method returns the document number if the content of the document has been successfully replaced.
DST Example
http://localhost:8732/GSService/xml/ReplaceContentAsBinaryDST/?document=RXN0byBlcyB1bmEgcHJ1ZWJhIHBhcmEgc3ViaXIgdW4gZG9jdW1lbnRvIHkgY29udmVydGlyIHN1IGNvbnRlbmlkbyBhIEJhc2U2NA==&form=LAWPROF&library=DMTESTLEGAL&user=admin&dst=afd448a5d0f9b...55355b8c677ad16&docNumber=756&version=1&subVersion=!
Error
Check the event.log file if you find errors.