> ## Documentation Index
> Fetch the complete documentation index at: https://www.courier.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Courier Create API

> HTTP reference for Courier Create tenant template endpoints used by Design Studio (Elemental content, draft and publish flows).

This page covers the REST API for **tenant notification templates**. These endpoints let you create, update, list, read, version, and publish templates within a specific [tenant](/platform/tenants/tenants-overview). For workspace-wide templates (`/notifications/...`), use the [Templates API](/platform/content/templates-api).

<Tip>
  Check out the [Courier Create API tutorial](/tutorials/content/how-to-use-courier-create-api) for a detailed walkthrough with code samples.
</Tip>

## Base URL and authentication

All paths are rooted at `https://api.courier.com`. Send your [API key](/platform/workspaces/environments-api-keys) in the `Authorization` header as `Bearer <token>`. For browser-embedded [Courier Create](/platform/create/installation), use a JWT with the right tenant template scopes instead of the workspace key; see [Courier Create authentication](/platform/create/authentication).

## Endpoint guide

The sections below describe **Courier Create** routes in the API Reference. Each one links to the matching operation for schemas, query parameters, and status codes.

### List templates

[`GET /tenants/{tenant_id}/templates`](/api-reference/courier-create/list-templates-in-tenant) returns a **paginated** list of templates for one tenant. Use `limit` and `cursor` from the response to walk pages (default page size 20, max 100).

### Create or replace

[`PUT /tenants/{tenant_id}/templates/{template_id}`](/api-reference/courier-create/create-or-update-a-tenant-template) **creates** a template when the ID is new (**201**) or **updates** it in place when it already exists (**200**). Notification content uses Elemental (`ElementalContentSchema`). Build the same JSON you would use with the [Elemental overview](/platform/content/elemental/elemental-overview): a `version`, an `elements` array, plus routing or channel data when you need it.

**Request body** (`PutTenantTemplateRequest`):

| Field       | Type    | Required | Description                                              |
| ----------- | ------- | -------- | -------------------------------------------------------- |
| `template`  | object  | Yes      | `TenantTemplateInput` (see below)                        |
| `published` | boolean | No       | Default `false`. If `true`, save and publish in one step |

**`template` object** (`TenantTemplateInput`):

| Field       | Type      | Required | Description                                         |
| ----------- | --------- | -------- | --------------------------------------------------- |
| `content`   | Elemental | Yes      | `ElementalContent`: `version` plus `elements` array |
| `routing`   | object    | No       | `MessageRouting`; multi-channel routing             |
| `channels`  | object    | No       | `MessageChannels`; per-channel config               |
| `providers` | object    | No       | `MessageProviders`; provider overrides              |

### Get current template

[`GET /tenants/{tenant_id}/templates/{template_id}`](/api-reference/courier-create/get-a-template-in-tenant) returns the **current** template for that tenant and ID. Use it when you need the latest merged view without requesting a specific version string.

### Get a specific version

[`GET /tenants/{tenant_id}/templates/{template_id}/versions/{version}`](/api-reference/courier-create/get-a-specific-template-version) returns one version of the template. The `version` path segment accepts `latest`, `published`, or a concrete identifier such as `v1` or `v2`.

### Publish

[`POST /tenants/{tenant_id}/templates/{template_id}/publish`](/api-reference/courier-create/publish-a-tenant-template) publishes a draft so it becomes what recipients resolve when sending. The optional request body can include a `version` string; it defaults to `latest` (publish the newest draft). The template must already exist for the tenant.

## Common responses

Each **Courier Create** operation documents its own `responses` in `openapi-specs/openapi.documented.yml` in the mintlify-docs repo (paths under `/tenants/{tenant_id}/templates`). Typical codes:

| Status | Meaning                                                                                                               |
| ------ | --------------------------------------------------------------------------------------------------------------------- |
| 200    | Successful read, list, or publish with a response body; or template updated (`PUT` when the template already existed) |
| 201    | Template created (`PUT` when the template is new)                                                                     |
| 400    | Bad request / validation error                                                                                        |
| 404    | Tenant, template, or version not found (where that operation defines it)                                              |
| 413    | Payload too large (`PUT /tenants/{tenant_id}/templates/{template_id}` only)                                           |

## Tenant templates vs workspace templates

These routes are **tenant-scoped**: paths start with `/tenants/{tenant_id}/templates/...` and isolate template data per [tenant](/platform/tenants/tenants-overview). For the **workspace** catalog (`/notifications/...`) shared across the account, use the [Templates API](/platform/content/templates-api).

## What's Next

<CardGroup cols={2}>
  <Card title="How to Use the Courier Create API" icon="book" href="/tutorials/content/how-to-use-courier-create-api">
    Draft, update, publish, and verify with code
  </Card>

  <Card title="Design Studio overview" icon="palette" href="/platform/content/design-studio/design-studio-overview">
    Editing experience in the UI
  </Card>

  <Card title="Elemental" icon="code" href="/platform/content/elemental/elemental-overview">
    Build `template.content`
  </Card>

  <Card title="Courier Create authentication" icon="key" href="/platform/create/authentication">
    JWT scopes for embedded template editing
  </Card>
</CardGroup>
