Peacemaker.Mailer.IntensiveDetails (Peacemaker v3.3.5-rc.7) View Source

Primary module for building the payload to be used for SendGrid templates during Intensive purchases. Sends the schedule of the upcoming classes as well other useful information like the recordings delivery date and the names of the upcoming class.

Link to this section Summary

Link to this section Types

Specs

intensive_details() :: %{
  payload: %{
    transaction_id: String.t(),
    order_total: String.t(),
    schedule: schedule(),
    first_class_date: String.t(),
    last_class_date: String.t(),
    recordings_delivery_date: String.t(),
    is_all_access: Boolean.t(),
    email: String.t()
  },
  email: String.t(),
  template_id: String.t()
}

Specs

schedule() :: %{date: String.t(), full_date_name: String.t(), title: String.t()}

Link to this section Functions

Specs

build(%{
  webinar_keys: [String.t()],
  order_id: String.t(),
  order_total: String.t(),
  sku: String.t(),
  email: String.t(),
  first_name: String.t(),
  token: String.t(),
  is_all_access: Boolean.t()
}) :: [intensive_details()]
Link to this function

send_email(list_of_tokens)

View Source