Copy Template
Purpose
To retrieve a copy of a specific template.
Quick Reference
| Property | Value |
|---|---|
| Method | POST |
| Request URL | https://{zohoapis_domain}/writer/api/v1/templates/{template_id}/copy |
| Scopes | ZohoWriter.documentEditor.ALL, ZohoPC.files.ALL, WorkDrive.files.ALL, WorkDrive.organization.ALL, WorkDrive.workspace.ALL |
| Rate Limit | See Writer API throttle limits |
Parameters
Path Parameters
| Parameter | Data Type | Mandatory/Optional | Description |
|---|---|---|---|
| template_id | String | Mandatory | Specify the unique id for the template. |
Body Parameters
| Parameter | Data Type | Mandatory/Optional | Description |
|---|---|---|---|
| type | String | Optional | Specify the type (either personal or organization ) of templates that needs to be copied. For example: type = personal / organization By default, the type value will be 'personal'. Hence, personal templates will be copied. |
| name | String | Optional | Specify a unique name for the template. By default, the template name will be "Copy of the Original template name". |
Notes
- This API will not work for Automation (Merge, Sign and Fillable) templates.
- For possible errors, refer to error codes.
Sample Request
Copiedcurl -X POST "https://www.zohoapis.com/writer/api/v1/templates/{template_id}/copy" \
-H "Authorization: Zoho-oauthtoken <ACCESS_TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"type": "personal",
"name": "Copied Template"
}'Copiedparam = Map();
param.put("type","personal");
response = invokeurl
[
url :"https://www.zohoapis.com/writer/api/v1/templates/{template_id}/copy"
type :POST
parameters:param
connection:"<connection_name>"
];
info response;Sample Response
Copied{
"created_time": "2019-08-28T16:30:33Z",
"modified_time_ms": 1567009834477,
"owner_id": "14335411",
"last_opened_time": "2019-08-28T16:30:33Z",
"open_url": "https://writer.zoho.com/writer/template/a7iyybadb",
"last_opened_time_ms": 1567009833936,
"type": "template",
"thumbnail_url":"https://writer.zoho.com/writer/thumbnail/a7iyybadb",
"created_by": "amelia",
"created_time_ms": 1567009833936,
"modified_time": "2019-08-28T16:30:34Z",
"preview_url": "https://writer.zoho.com/writer/zwpreview/a7iyybadbb8",
"creator_id": "11122329",
"name": " Sample Name",
"id": "a7iyybadbb8b74e1147638bad04abc161e79e",
"permalink": "https://docs.zoho.com/file/a7iyybadb"
"status": "active"
}