---
title: "Design a template from a brief"
description: "A designer builds a new block template from what you write."
url: "https://openemail.uk/docs/api/templates/design"
area: "API"
category: "Mailbox"
---

# Design a template from a brief

A designer builds a new block template from what you write.

`POST /templates/design`

## POST /templates/design

A designer builds a new block template from what you write.

## Example

Needs `templates:write`. `brief` holds everything the design must say and look like. `starter` builds on a starter design, `imageFileIds` places up to ten images, and `publish` makes it live at once. Answers 201 with the template and `design`.

**curl**

```
curl -X POST "$OE/templates/design" -H "$AUTH" -H "Content-Type: application/json" \
  -d '{ "name": "Spring launch", "brief": "A launch email for our spring collection: a hero image, three product cards and a button to the shop. Green and cream, friendly tone." }'
```

**Response**

```
{
  "object": "template",
  "id": "tpl_8f3a1c2e9b7d4a60",
  "name": "Spring launch",
  "slug": "spring-launch",
  "status": "draft",
  "publishedVersion": null,
  "latestVersion": 1,
  "design": {
    "subject": "Spring is here",
    "notes": [],
    "imageProblems": []
  }
}
```

> It spends one AI action and can take up to a minute. A design that cannot be made valid is a 422 `invalid_template`, and a workspace out of AI actions a 429 `ai_quota_exceeded`.

> An image a key limited to some addresses cannot reach is left out and named in `design.imageProblems`.

## Reference

- [`POST /templates/design`](https://openemail.uk/docs/api/reference/templates#post-templates-design): full reference
