List templates
Retrieves a list of all templates in the workspace. Supports optional filtering by category and channel.
get/api/templates.list
Query parameters
workspace_idstring required
The ID of the workspace
category'marketing' | 'transactional' | 'welcome' | 'opt_in' | 'unsubscribe' | 'bounce' | 'blocklist' | 'blog' | 'other'
Filter templates by category
channel'email' | 'web'
Filter templates by channel
Response
List of templates retrieved successfully
Example response
{
"templates": [
{
"id": "welcome_email",
"name": "Welcome Email",
"version": 1,
"channel": "email",
"email": {
"sender_id": "sender_123",
"reply_to": "support@example.com",
"subject": "Welcome, {{user_name}}!",
"subject_preview": "Get started with your account",
"visual_editor_tree": {
"type": "mjml",
"children": []
}
},
"category": "transactional",
"test_data": {
"user_name": "John Doe",
"action_url": "https://example.com/action"
}
}
]
}