/snippets (aka Templates)

Lists templates or snippets that you have access to (including those shared with you)

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
ParameterTypeDescription
  • id
StringUnique ID.
userIdStringUser _id of the snippet owner. Note that this isn't always your userId, since the template might be shared with you.
createdAtDateTimestamp of when the snippet was created.
savedAtDateTimestamp of when the snippet last modified.
savedByStringID of the user that last saved the snippet.
deletedAtDateTimestamp of when the snippet was deleted.
archivedAtDateTimestamp of when the snippet was archived.
titleStringThe string to use for the subject of the message this template is inserted into.
sourceStringHTML source of the template.
nameStringThe name of this template. Not used anywhere when the template is inserted.
sharedObjectSee docs.
customShortcutStringThe shortcut this snippet can be identified by for quick insertion.

Searching

The search string will match either name or the subject of the snippet. In addition, the following search operators are supported (see below). Multiple-word values for search operators must be escaped in quotes (e.g. name:"my sales template"). This does not currently support searching the body of the snippet.

What you can search bySearch operator & example
The snippet's name

name:"my template name"

This search only applies to the snippet's name. Matches case-sensitively. Only one name: search operator supported.

The snippet's subject

name:"my template subject"

This search only applies to the snippet's subject.
Matches case-sensitively. Only one subject: search operator supported.

The snippet's tag

folder:"my awesome sales pitches"

Search snippets in the specified folder. Matches folder name case-sensitively. Only one folder: search operator supported.

The snippet's creator

owner:myself
owner:"my team"
owner:[email protected]

Search snippets belonging to yourself, your team, or a particular email. Matches case-insensitively. Only one owner: search operator supported.

The snippet's custom shortcut

customShortcut:"hi"

This search only applies the the snippet's custom shortcut, matches case insensitively.

Query Params
string
Defaults to no search

(Optional) See table below.

boolean
Defaults to false

(Optional) True to ONLY return snippets that you do not own (i.e. shared with you)

boolean
Defaults to false

(Optional) returns snippet marked for deleted

string
Defaults to no sort

(Optional) field to sort by

boolean
Defaults to false

(Optional) true to sort ascending

string

(Optional) Separate multiple expand queries using comma (ex: expand=analytics,userId). Pass expand=analytics to return analytics for each snippet. Pass expand=userId on the querystring to expand this to include the email of the owner. Pass expand=snippetId to retrieve your snippets' snippet tag IDs - set as an object on the snippet's _id field like { _id: { _id: <snippet ID>, tagId: <snippet tag ID> }, ... <other snippet document fields> }.

boolean

(Optional) False to only return templates and true to only return snippets (they don't include subject lines and can't be sent individually).

Response

Language
Credentials
Header
LoadingLoading…
Response
Choose an example:
application/json
Psst... like working with APIs? Come join us!