This resource is part of the v1alpha1 API and is subject to change. Fields and behavior may change in future releases.
Identity
| |
|---|
| Group | notification.miloapis.com |
| Version | v1alpha1 |
| Kind | Email |
| Scope | Project |
Overview
An Email represents a concrete message that Datum Cloud should send to a recipient. It references an EmailTemplate to render, names the recipient (either a User resource or a literal address), and supplies the variables needed to fill in the template. Use it to trigger a one-off notification e-mail within a Project; the platform renders the template, resolves the recipient, and delivers the message, recording the outcome in the resource status.
Spec fields
| Field | Type | Required | Description |
|---|
spec.templateRef | Object | Yes | References the EmailTemplate that should be rendered. |
spec.templateRef.name | string | Yes | Name of the referenced EmailTemplate. |
spec.recipient | Object | Yes | The recipient of the e-mail. Provide exactly one of userRef or emailAddress. |
spec.recipient.userRef | Object | No | References the User resource that will receive the message. Mutually exclusive with emailAddress. |
spec.recipient.userRef.name | string | No | Name of the User resource that will receive the e-mail. Required when userRef is set. |
spec.recipient.emailAddress | string | No | Literal e-mail address for the recipient instead of a User reference. Mutually exclusive with userRef. |
spec.variables | []Object | No | Name/value pairs substituted into the template. Each entry requires name (as declared in the template) and value. |
spec.priority | string | No | Influences the order in which pending e-mails are processed. One of low, normal, high. |
spec.cc | []string | No | Additional addresses that receive a carbon copy. Maximum 10 addresses. |
spec.bcc | []string | No | Addresses that receive a blind-carbon copy. Maximum 10 addresses. |
Status fields (read-only)
| Field | Type | Description |
|---|
status.conditions | []Object | Latest observations of the e-mail’s state; the standard Delivered condition tracks delivery. |
status.emailAddress | string | The final recipient address used for delivery, after resolving any referenced User. |
status.subject | string | The subject line used for the e-mail. |
status.htmlBody | string | The rendered HTML content of the e-mail. |
status.textBody | string | The rendered plain-text content of the e-mail. |
status.providerID | string | Identifier returned by the underlying e-mail provider when the message is accepted for delivery, used to track delivery status. |
Usage
apiVersion: notification.miloapis.com/v1alpha1
kind: Email
metadata:
name: welcome-message
spec:
templateRef:
name: welcome-template
recipient:
emailAddress: person@example.com
variables:
- name: firstName
value: Alex
priority: normal
datumctl apply -f email.yaml --project my-project
datumctl get emails --project my-project
datumctl describe emails welcome-message --project my-project
Run datumctl explain emails --recursive to see the full, live field tree for this resource.