Converting a Word Document into a given output format (Deprecated)
This API converts an agreement Word document into a specific output format using the parameters, such as agreementId and docFormat. This API is deprecated.
API |
Signature |
---|---|
convertAgreementWordDoc |
|
Request Parameters |
|||
---|---|---|---|
Name |
Type |
Description |
Required? |
agreementId |
|
The id of the agreement providing the content for the document. |
Yes |
docId |
|
The id of the agreement document to convert in a different output format. |
Yes |
docFileName |
|
The file name for the Word document. |
Yes |
docFormat |
|
Indicates whether the document will be:
|
Yes |
pLevel |
|
The protection level to apply to the document. Valid values are:
|
Yes |
addWatermark |
|
Indicates whether a draft watermark should be added to the output document. |
Yes |
removeWatermark |
|
Indicates whether a draft watermark on the source word document should be removed from the resulting document. |
Yes |
agreementNbr |
|
The agreement number of the document, upserted in the header. |
Yes |
dateFormat |
|
The date format for the footer of the document. |
Yes |
sessionId |
|
The Salesforce session id. |
Yes |
serverUrl |
|
The Salesforce server URL. |
Yes |
Response Parameter |
||
---|---|---|
Name |
Type |
Description |
result |
|
The id of the converted document. |
Code Sample
ID agreementId = 'a016100000Che3D';
ID docId = 'a0Y61000002K6IR';
String docFileName = 'Agreement';
String docFormat = 'PDF';
String pLevel = 'Full access';
Boolean addWatermark = true;
Boolean removeWatermark = false;
String agreementNbr = '1234';
String dateFormat = 'M/d/yyyy HH:mm:ss';
String sessionId = sessionId; //This is the session Id.
String serverUrl = System.Url.getSalesforceBaseUrl().toExternalForm() + '/services/Soap/u/50.0/' + UserInfo.getOrganizationId();
ID ConvertedDocId = Apttus.MergeWebService.convertAgreementWordDoc(agreementId,docId,docFileName,docFormat,pLevel,addWatermark,removeWatermark,agreementNbr,dateFormat,sessionId,serverUrl);