GET - Download Specific Attachment of a Group/Personal Task

Purpose

This API is used to download a specific attachment of a group/personal task. In case, there are multiple attachments in a task, send separate request for each attachment with the respective attachment detail.

OAuth Scope

Use the scope

ZohoMail.tasks.ALL (or) ZohoMail.tasks.READ

to generate the Authtoken.

ALL - Full access to tasks.

READ - Retrieve the attachments from a group/personal task.

Request URL

Method: GET

Group task:

https://mail.zoho.com/api/tasks/groups/{zgid}/{taskId}/attachments/{attachmentId}

Personal task:

https://mail.zoho.com/api/tasks/me/{taskId}/attachments/{attachmentId}

 

Path Parameters

* - Mandatory parameter

Response Codes

Refer here for the response codes and their meaning.

Sample Request - Group Task

Copiedcurl "https://mail.zoho.com/api/tasks/groups/5******048/48184******91002/attachments/13930*********0020" \
-X GET \
-H "Accept: application/octet-stream" \
-H "Authorization: Zoho-oauthtoken ****************"

Sample Request - Personal Task

Copiedcurl "https://mail.zoho.com/api/tasks/me/48184******91002/attachments/13930*********0053" \
-X GET \
-H "Accept: application/octet-stream" \
-H "Authorization: Zoho-oauthtoken ****************"

Sample Success Response - Group & Personal Task

CopiedThe attachment corresponding to the file ID provided in the Request is extracted and the entire content stream is provided in the response as a downloadable file. 

Sample Failure Response - Group & Personal Task

Copied{
  "status": {
    "code": 0,
    "description": "The input passed is invalid"
  },
  "data": {}
}