• Register

Email Template Sets

Resource URI

/emailTemplateSets/{emailTemplateSetId}

Items in curly braces represent variables.

Description

Email Template Sets manage the data necessary to send emails to developers. Notification emails are sent to the developers when they register for a new key or when the API calls reach or cross a specific limit. Notification emails can also be sent to notify developers about their API usage.

Resource Schema

Property Characteristics
id Type string
Sub-type
Create Rule Ignored
Update Rule Required (if not in context)
Fetch Rule Implicit
Description Object identifier.
created Type string
Sub-type datetime
Create Rule Ignored
Update Rule Ignored
Fetch Rule Implicit
Description Date/time the object was created.
updated Type string
Sub-type datetime
Create Rule Ignored
Update Rule Ignored
Fetch Rule Implicit
Description Date/time the object was updated.
name Type string
Sub-type
Create Rule Required
Update Rule Optional
Fetch Rule Implicit
Description Email template set name.
type Type string
Sub-type
Create Rule Optional
Update Rule Optional
Fetch Rule Implicit
Description Email template set type.
emailTemplates Type array
Sub-type EmailTemplate
Create Rule Optional
Update Rule Optional
Fetch Rule Explicit
Description Email templates that belong to this email template set

fetch all [GET]

Retrieves collection of Email Template Sets with their respective Email Templates belonging to the given Area.

Parameters

Parameter Required Type Description
fields false string Comma-separated list of property paths to include in response. Each property path is a dot-separated list of object property names. fields=<property\[.property...\]>\[,...\]\[&fields=...\]
filter false string Colon-separated name/value pair specifying the name of property whose value must contain the given value (as a substring). Results may also be filtered by nested collections' properties by specifying a dot-separated property path. filter=<property\[.property...\]>:<value>\[&filter=...\]
sort false string Comma-separated list of properties to sort by. Only root-level properties are supported. Each property name may be optionally followed by :asc or :desc to specify sort direction (defaults to asc). sort=<property\[:(asc\|desc)\]>\[,...\]\[&sort=...\]
limit false int Number of objects to return in the result. Defaults to 100.
offset false int 0-based index of first object in the list to return. Defaults to 0.

Returns

Success

Array of Email Template Sets for the Area If fields request parameter is not included, only those fields with "Fetch Rule" equal to "Implicit" will be returned. Otherwise, the fields contained in the URL parameter will be included in the response.

Failure

Array of validation responses

Examples

Request

curl -k 'https://api.mashery.com/v3/rest/emailTemplateSets' -H "Authorization: Bearer <insert your token here>" -H "Content-Type:application/json" 

Response

[
    {
        "id": "820baede-5414-41ba-821a-00b4df91e8b7",
        "created": "2014-03-19T22:45:29.000+0000",
        "updated": "2014-07-12T18:58:39.000+0000",
        "name": "pharetra magna",
        "type": "nullam sit amet"
    }
]

Request

curl -k 'https://api.mashery.com/v3/rest/emailTemplateSets' -H "Authorization: Bearer <insert your token here>" -H "Content-Type:application/json" 

Response

[
    {
        "id": "b147e013-e2e1-4b56-9b19-2b8065a7f6aa",
        "created": "2014-06-16T19:30:30.000+0000",
        "updated": "2014-03-27T06:08:26.000+0000",
        "name": "fermentum",
        "type": "non quam"
    }
]

fetch [GET]

Retrieves the Email Template Sets, returning a Email Template Set

Parameters

Parameter Required Type Description
emailTemplateSetId true string Email Template Set identifier.
fields false string Comma-separated list of property paths to include in response. Each property path is a dot-separated list of object property names. fields=<property\[.property...\]>\[,...\]\[&fields=...\]
filter false string Colon-separated name/value pair specifying the name of property whose value must contain the given value (as a substring). Results may also be filtered by nested collections' properties by specifying a dot-separated property path. filter=<property\[.property...\]>:<value>\[&filter=...\]
sort false string Comma-separated list of properties to sort by. Only root-level properties are supported. Each property name may be optionally followed by :asc or :desc to specify sort direction (defaults to asc). sort=<property\[:(asc\|desc)\]>\[,...\]\[&sort=...\]
limit false int Number of objects to return in the result. Defaults to 100.
offset false int 0-based index of first object in the list to return. Defaults to 0.

Returns

Success

Email Template Sets as identified If fields request parameter is not included, only those fields with "Fetch Rule" equal to "Implicit" will be returned. Otherwise, the fields contained in the URL parameter will be included in the response.

Failure

Array of validation responses

Examples

Request

curl -k 'https://api.mashery.com/v3/rest/emailTemplateSets/{emailTemplateSetId}' -H "Authorization: Bearer <insert your token here>" -H "Content-Type:application/json" 

Response

[
    {
        "id": "11891b52-7334-416f-9449-830880c0557b",
        "created": "2013-10-12T20:04:12.000+0000",
        "updated": "2013-08-12T20:57:45.000+0000",
        "name": "sit amet",
        "type": "in"
    }
]

Request

curl -k 'https://api.mashery.com/v3/rest/emailTemplateSets/{emailTemplateSetId}' -H "Authorization: Bearer <insert your token here>" -H "Content-Type:application/json" 

Response

[
    {
        "id": "7ba7eab4-d925-4775-a2f0-7ce6318b5cbe",
        "created": "2014-01-27T14:57:18.000+0000",
        "updated": "2013-12-25T02:50:48.000+0000",
        "name": "molestie lorem quisque",
        "type": "ipsum integer"
    }
]

Docs Navigation