
Send an Email Using a Template
template_send_email.Rd
Sends an email using a predefined template.
Usage
template_send_email(
from,
to,
id,
template_model,
msg_stream,
tag = NULL,
track_opens = FALSE,
token = NULL
)
Arguments
- from
Character scalar. Email address of the sender.
- to
Character vector. Email addresses of recipients (max 50).
- id
A single integer. The template ID in Postmark.
- template_model
A named list. Variables to be populated in the template.
- msg_stream
Character scalar. Either "outbound" or "broadcast".
- tag
A single character string. Optional tag for categorizing the email. Maximum 1000 characters. Default is NULL.
- track_opens
A logical value. Whether to track when recipients open the email. Default is FALSE.
- token
Character string. Your Postmark API token. If NULL (default), the function will attempt to retrieve the token using
get_token()
POSTMARK_SERVER_TOKEN
as an environment variable. Check the Postmark's API documentation on how to get a server token.