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

# Publish Template

> Publish a draft version of a template to make it the active production version.

Promote an in-progress draft template into the published, active template used for sending via the Mailofly API.

### Path Parameters

**id** `string` *required*

The unique identifier of the template to publish.

### Response

**data** `object`

**id** `string`

The template ID.

**status** `string`

Published status (`published`).

**publishedAt** `string`

Timestamp when the template was published.

```bash cURL theme={null}
curl -X POST https://api.mailofly.com/templates/tmpl_123/publish \
  -H "Authorization: Bearer mf_live_your_api_key"
```

```json 200 OK theme={null}
{
  "data": {
    "id": "tmpl_123",
    "status": "published",
    "publishedAt": "2026-09-11T13:45:00Z"
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.