Skip to content

Premade templates

The premade templates API serves Topol's library of 150+ ready-made email templates, so you can start from a designed template instead of a blank canvas.

What the API covers

  • List templates
    Return the available premade templates, with paging, a type filter (FREE or PRO), free-text search, filtering by category or keyword IDs, and sorting by date and other columns.

  • Get template details
    Request one template by ID to get its HTML and JSON. JSON for a PRO template is returned only when the request is authenticated with a plugin subscription; otherwise it comes back null, while the HTML is always present.

  • List categories and keywords
    Fetch the category list (Business, E-commerce, and the rest) and the keyword list to build the filters above. Both return id and name, and the filter parameters take the IDs.

How it works

1. Get an API key

These endpoints take an API key from either your account settings or your existing Plugin API Token.

For an account-settings key, open Settings, go to API Tokens, select "Create API Token", and grant the permissions the token needs. To reuse the Plugin API token that initialized your Plugin, copy it from the Plugin settings under "Show API keys".

The key unlocks PRO template JSON; the list and category endpoints respond without it, so the header is recommended rather than strictly required.

2. Set the request headers

Include these headers:

json
{
  "accept": "application/json",
  "Authorization": "Bearer <api-key>"
}

Servers

https://app.topol.io/apiProduction server

Get premade email templates

GET
/premade-templates

Retrieve a list of premade email templates.

Authorizations

BearerAuth

Use: Authorization: Bearer <api-key>

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"visible": true,
  
"published": true,
  
"type": "FREE",
  
"categories": [
  
  
1
  
],
  
"keywords": [
  
  
8
  
],
  
"sort_by": "order",
  
"sort_by_direction": "asc",
  
"search": "email",
  
"api_token": "0001f41e-a4b8-3e73-8d65-2b8500b54ff0",
  
"per_page": 25,
  
"current_page": 1
}

Responses

Templates fetched successfully

application/json
JSON
{
  
"success": true,
  
"data": {
  
  
"data": [
  
  
  
{
  
  
  
  
"id": 123,
  
  
  
  
"name": "Summer Promo",
  
  
  
  
"slug": "summer-promo",
  
  
  
  
"type": "email",
  
  
  
  
"img_thumb_url": "https://cdn.topol.io/templates/summer-thumb.jpg",
  
  
  
  
"category_id": 2,
  
  
  
  
"description": "Bright summer sale layout",
  
  
  
  
"keywords": [
  
  
  
  
  
{
  
  
  
  
  
  
"id": 8,
  
  
  
  
  
  
"keyword": "event",
  
  
  
  
  
  
"slug": "event",
  
  
  
  
  
  
"created_at": "2021-05-14T10:59:57.000000Z",
  
  
  
  
  
  
"updated_at": "2021-05-14T10:59:57.000000Z"
  
  
  
  
  
}
  
  
  
  
],
  
  
  
  
"created_at": "2025-02-04T10:21:33Z",
  
  
  
  
"updated_at": "2025-02-10T14:52:11Z"
  
  
  
}
  
  
],
  
  
"total_records": 360,
  
  
"current_page": 1,
  
  
"per_page": 25,
  
  
"next_page": 2,
  
  
"prev_page": 0,
  
  
"last_page": 15
  
}
}

Playground

Authorization
Body

Samples


Get premade email template

GET
/premade-templates/{premadeTemplate}

Get a premade template

Authorizations

BearerAuth

Use: Authorization: Bearer <api-key>

Type
HTTP (bearer)

Parameters

Path Parameters

premadeTemplate*

Premade template ID

Type
integer
Required

Responses

Template fetched successfully

application/json
JSON
{
  
"success": true,
  
"data": {
  
  
"id": 410,
  
  
"name": "Christmas Workshops",
  
  
"slug": "christmas-workshops",
  
  
"type": "PRO",
  
  
"json": "{"body":"<mj-text>Hello World</mj-text>"}",
  
  
"html": " <!doctype html> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Email Template</title> </head> <body> <p>Hello World</p> </body> </html> ",
  
  
"category_id": 7,
  
  
"order": 1009,
  
  
"description": "Come join us to get into the Advent spirit...",
  
  
"visible": true,
  
  
"created_at": "2025-10-06T14:08:08.000000Z",
  
  
"updated_at": "2025-10-06T14:08:19.000000Z",
  
  
"image_path": "/img/templates/410.jpg",
  
  
"image_thumb_path": "/img/templates/410_thumb.jpg",
  
  
"category": {
  
  
  
"id": 7,
  
  
  
"name": "Holidays",
  
  
  
"slug": "holidays",
  
  
  
"order": 7,
  
  
  
"created_at": "2021-05-14T10:59:57.000000Z",
  
  
  
"updated_at": "2021-05-14T10:59:57.000000Z"
  
  
},
  
  
"keywords": [
  
  
  
{
  
  
  
  
"id": 8,
  
  
  
  
"keyword": "event",
  
  
  
  
"slug": "event",
  
  
  
  
"created_at": "2021-05-14T10:59:57.000000Z",
  
  
  
  
"updated_at": "2021-05-14T10:59:57.000000Z"
  
  
  
}
  
  
]
  
}
}

Playground

Authorization
Variables
Key
Value

Samples


Premade template categories


Get a list of premade template categories

GET
/premade-template-categories

Retrieve a list of premade template categories

Authorizations

BearerAuth

Use: Authorization: Bearer <api-key>

Type
HTTP (bearer)

Responses

Template categories fetched successfully

application/json
JSON
{
  
"success": true,
  
"data": [
  
  
{
  
  
  
"id": 7,
  
  
  
"name": "Holidays",
  
  
  
"value": "holidays"
  
  
}
  
]
}

Playground

Authorization

Samples


Premade template keywords


Get a list of premade template keywords

GET
/premade-template-keywords

Retrieve a list of premade template keywords

Authorizations

BearerAuth

Use: Authorization: Bearer <api-key>

Type
HTTP (bearer)

Responses

Template keywords fetched successfully

application/json
JSON
{
  
"success": true,
  
"data": [
  
  
{
  
  
  
"id": 8,
  
  
  
"name": "event",
  
  
  
"value": "event"
  
  
}
  
]
}

Playground

Authorization

Samples


Powered by VitePress OpenAPI