Get Stored Templates

This API allows you to get the list of templates stored in your account.

Request Type

  • GET

Request URL

https://campaigns.zoho.com/emailapi/v1/templates?start_index=1&end_index=1000

Content-Type

application/json

List of Request Parameters

ParametersData TypeDescription
start_indexIntegerStarting index of the number of objects to be obtained.
end_indexIntegerEnding index of the number of objects to be obtained.

List of Response Body Attributes

ParametersData TypeDescription
responseJSON ObjectContains the response details of the API.
codeIntegerSuccess or failure code.
messageStringSuccess or failure message returned by the API.
templatesJSON ArrayContains details about each template.
nameStringName of the template.
idStringUnique ID of the template which can be used in APIs.
zuidIntegerUser ID of the Zoho Account's user from whose account this API was called.
countIntegerTotal number of templates returned.
rangeJSON ObjectContains information about start and end index.
start_indexIntegerStarting index of the data range being returned. Indicates the position in the overall data set where the returned data begins.
end_indexIntegerEnding index of the data range being returned. Indicates the position in the overall data set where the returned data ends.
errorsJSON ObjectContains the error details of the API such as 'code' and 'message'

Sample Response - Success

Copied{
  "response": {
    "code": 200701,
    "message": "Successfully obtained the list of templates"
  },
  "templates": [
    {
      "name": "Newsletter Template",
      "id": "8000000131005",
      "zuid": 16304095
    },
    {
      "name": "Promotional Offer",
      "id": "8000000131003",
      "zuid": 16304095
    }
  ],
  "count": 2,
  "range": {
    "start_index": 1,
    "end_index": 1000
  }
}

Sample Response - Failure

Copied{
  "errors": [
    {
      "code": 500701,
      "message": "An error occurred in Templates API"
    }
  ]
}