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

# Create an email notifier

Create an email notifier to send monitor alerts to a specific email address. Before you
create the notifier, identify the destination email address.

Select from the following methods to create an email notifier. You can use
[variables](/investigate/alerts/notifications/notifiers#use-variables-in-notifiers) in your
notifiers.

<Tabs>
  <Tab title="Web" id="create-email-notifier">
    1. In the navigation menu select
       **<Icon icon="bell" /> Alerting <span aria-label="and then">></span> Notifiers**.
    2. Click **Create notifier**.
    3. Enter a descriptive name for the notifier.
    4. Select **Email** as the type of notifier you want to create.
    5. In the **Email** field, add the destination email address.
    6. Optional: In the **Body** field, enter HTML or text body content.
    7. Optional: Select **Notify when resolved** to send a resolved alert notification.
    8. Click **Save**.
  </Tab>

  <Tab title="Chronoctl" id="email-chronoctl">
    To create one or more notifiers using [Chronoctl](/tooling/chronoctl), create a YAML file
    that defines them and apply the configuration to your instance.

    <Note>
      You can use the `notifiers scaffold` command to generate an example notifier, and
      then copy the resource definition for your notifier type:

      ```shell theme={null}
      chronoctl notifiers scaffold
      ```
    </Note>

    1. Define the resource definition for your email notifier:

       ```yaml /NAME/ /SLUG/ /ADDRESS/ theme={null}
       api_version: v1/config
       kind: Notifier
       spec:
         name: NAME
         slug: SLUG
         skip_resolved: true
         email:
           - to: ADDRESS
             html: '<b>Alert triggering</b>'
             text: 'Alert triggering'
       ```

       Replace the following:

       * *`NAME`*: A descriptive name, such as `team-email`.
       * *`SLUG`*: A unique identifier, such as `team-email`.
       * *`ADDRESS`*: An email address destination for the notifier.

    2. Optional: Update the `html` or `text` keys to include custom HTML or text body
       content.

    3. Apply the changes:

       ```shell /FILE_NAME/ theme={null}
       chronoctl apply -f FILE_NAME.yaml
       ```

       Replace *`FILE_NAME`* with the name of your notifier YAML file.
  </Tab>

  <Tab title="Terraform" id="email-terraform">
    To create an email notifier:

    1. Create an email notifier with Terraform by using the
       `chronosphere_email_alert_notifier` type followed by a name in a resource
       declaration:

       ```terraform theme={null}
       resource "chronosphere_email_alert_notifier" "email_notifier" {
         name = "Email Notifier"

         # Optional slug of the email notifier.
         slug = "email-notifier"

         ## Notifier-specific required configuration
         # For detailed definitions, see
         # https://prometheus.io/docs/alerting/latest/configuration/#email_config
         to = "your-address@example.com"

         ## Notifier-specific optional configurations
         html = "<b>Alert triggering</b>"
         text = "Alert triggering"
       }
       ```

    2. Modify the `to` key to add the destination email address.

    3. Optional: Update the `html` or `text` keys to include custom HTML or text body
       content.

    4. Run `terraform apply` to create the notifier resource.

       ```shell theme={null}
       terraform apply
       ```
  </Tab>

  <Tab title="API" id="email-api">
    To complete this action with the Chronosphere API, use the `email` object in the
    [`CreateNotifier`](/tooling/api-info/definition/operations/CreateNotifier) endpoint.

    Because the Chronosphere API requires authentication, include an API token with your
    `curl` request, as shown in the following example. For more details, see
    [Create an API token](/tooling/api-info#create-an-api-token).

    ```shell /"TOKEN"/ /INSTANCE/ /METHOD/ /ENDPOINT_PATH/ theme={null}
    export CHRONOSPHERE_API_TOKEN="TOKEN"
    export CHRONOSPHERE_DOMAIN="INSTANCE.chronosphere.io"

    curl -H "API-Token: ${CHRONOSPHERE_API_TOKEN}" \
         -X METHOD "https://${CHRONOSPHERE_DOMAIN}/ENDPOINT_PATH"
    ```

    Replace the following:

    * *`TOKEN`*: Your API token.
    * *`INSTANCE`*: The subdomain name for your organization's Observability Platform instance.
    * *`METHOD`*: The HTTP method to use with the request, such as `GET` or `POST`.
    * *`ENDPOINT_PATH`*: The specific endpoint you want to access.
  </Tab>
</Tabs>
