---
title: "Add base email message"
method: POST
path: "/api/v1/messages/email"
tags: ["Messages"]
---

# Add base email message

`POST /api/v1/messages/email`

## Request

- Base URL: `https://yespo.io` (the document declares no server; this is the origin it was published from)
- URL: `https://yespo.io/api/v1/messages/email`
- Auth: HTTP basic

The method is used for adding/updating the language version of a message identified by the internal ID (for multilingual messages).

## Request body

- BaseEmailMessage
  - `id` integer: Message ID.
  - `name` string, required: Message name.
  - `languageCode` string: Language code.
  - `tags` string[]: List of tags.
  - `subscriptionsKeys` string[]: Subscription categories keys, assigned to a message.
  - `languages` string[]: An array with the language codes for multilingual messages. Available for the GET method only.
  - `from` string, required: <b>Required parameter.</b><br> Sender name and email address, e.g. "from": "\"name\" &lt;info@test.com&gt;"
  - `subject` string, required: Message subject
  - `htmlText` string, required: Message HTML code
  - `rawHtml` string: Message HTML code without styles.
  - `ampHtml` string: Message AMP code
  - `css` string: Message styles
  - `updatedDate` string, date-time: Message updated date
  - `translations` EmailMessage[]: The array of the language versions for the current message. Available for the GET method only.
    - `id` integer: Message ID.
    - `name` string, required: Message name.
    - `languageCode` string: Language code.
    - `tags` string[]: List of tags.
    - `subscriptionsKeys` string[]: Subscription categories keys, assigned to a message.
    - `languages` string[]: An array with the language codes for multilingual messages. Available for the GET method only.
    - `from` string, required: <b>Required parameter.</b><br> Sender name and email address, e.g. "from": "\"name\" &lt;info@test.com&gt;"
    - `subject` string, required: Message subject
    - `htmlText` string, required: Message HTML code
    - `rawHtml` string: Message HTML code without styles.
    - `ampHtml` string: Message AMP code
    - `css` string: Message styles
    - `updatedDate` string, date-time: Message updated date
    - `template` boolean
  - `template` boolean

## Response `200`

---

[API](https://skmtc.dev/yespo/apis/yespo-api.md) · [All operations](https://skmtc.dev/yespo/apis/yespo-api/llms.txt) · [OpenAPI document](https://skmtc.dev/yespo/apis/yespo-api/revisions/b662f92b6c40?raw)
