Skip to main content

Create/Upload Documents

Purpose 

To create or upload documents. The document that is created can be accessed in the recent files of your Writer account.

HTTP Request URL

https://{zohoapis_domain}/writer/api/v1/documents

Body Parameters

ParameterData TypeDescription
Optional Parameters
filenameStringSpecify a unique name for the writer document. If this param is not passed, a blank untitled document will be created.
resource_typeString

Specify the type of document which needs to be created.

Possible values: fillable/merge/sign

Note: You can also create or upload documents using the deluge task, followed by the parameters zoho.writer.uploadDocument(.....);

Sample Request

Copiedcurl "https://www.zohoapis.com/writer/api/v1/documents"
-X POST
-H "Authorization: Zoho-oauthtoken xyz"
CopiedFile1 = ("sampleText").toFile("sample.docx");
result = zoho.writer.uploadDocument(File1, "new file name", 'fsp7g03c1cd18ebb2484da087150b6f21f157', "password", "writer_crm");

Sample Response

Copied{
  "created_time": "2018-05-08T13:54:41Z",
  "role": "OWNER",
  "owner_id": "4579020",
  "parent_folder_id": "40dgcFOLDER4579020",
  "open_url": "https://writer.zoho.com/writer/open/ponaz526afbc307254800b4308c163f376769",
  "is_favourite": false,
  "document_id": "ponaz526afbc307254800b4308c163f376769",
  "created_by": “Amelia”,
  "version": "1.0",
  "document_name": “Press release”,
  "modified_time": "2018-05-08T13:54:41Z",
  "preview_url": "https://writer.zoho.com/writer/preview/ponaz526afbc307254800b4308c163f376769",
  "creator_id": "4579020",
  "download_url": "https://writer.zoho.com/api/v1/download/ponaz526afbc307254800b4308c163f376769",
  "document_properties": "https://writer.zoho.com/api/v1/documents/ponaz526afbc307254800b4308c163f376769",
  "lastmodified_by": [
    {
      "email_id": “amelia@zylker.com”,
      "profile_photo": "https://contacts.zoho.com/file?t=user&ID=4579020&fs=thumb",
      "user_id": "4579020",
      "display_name": “Amelia”
    }
  ]
}