Preview Document
Purpose
To open a document in preview or read-only mode in Zoho Writer.
HTTP Request URL
https://{api.office-integrator_domain}/writer/officeapi/v1/document/preview
Request Parameters
Parameter | Data Type | Description |
Mandatory Parameters | ||
apikey | 423s***** | Uniquely identifies the web application in which the Writer editor is integrated. |
document or url | File or String | Method of providing the input file depending on its location. document - if the input file is from your local drive or desktop. url - if the input file is from a publicly accessible Web URL. |
Optional Parameters | ||
lang | String | Enables the editor interface to open in Writer supported languages. Default value: en (English) |
document_info | { "document_name":"New" } | Set a display name for the document. |
permissions | { "document.print":true, } | Define document permissions for user. Option to allow or revoke document "Print" access. |
Preview Document - Error Codes
Code | Description |
1831 | Error occurred. Parameter value is either incorrect or invalid. |
1852 | File format you're trying to import is not supported. |
1868 | Invalid parameter name for uploaded content. |
For a full list of error handling cases in Preview Document, refer here.