- Switch from using
HTTPoisonto usingTesla - Switch from using
PoisontoJasonfor JSON serialization SendGrid.Emailis now responsible for configuring its own JSON serialization- An API key can be set manually for any API call as a keyword option, bypassing the need for a global API key
- An API key can be set with the
{:system, "ENV_VAR"}to use values at runtime - Add dialyzer for validing typespecs
- Add support for dynamic template data
- Add struct for handling Contact Recipient encoding
- Working config added for testing
- Add support for multiple personalizations in a single sent Email request
- Typespecs are now correct
SendGrid.Mailerhas been renamed toSendGrid.Mailto better reflect the actual shape of SendGrid's API structureSendGrid.Contacts.Recipients.addnow requires a recipient to be built withSendGrid.Contacts.Recipient.build/2SendGrid.Contacts.Lists.addreturns{:ok, map()}instead of{:ok, integer()}.
- Raise runtime error whenever API isn't configured whenever making an API call
- custom headers are properly sent when V3 of the SendGrid API
- Add
add/1,all_recipients/3, anddelete_recipient/2toSendGrid.Contacts.Lists - Remove compile warnings for
Phoenix.View
- Relax dependency versions
- add
put_phoenix_layout/2inSendGrid.Emailto render views in
put_phoenix_template/3now expects an atom for implicit template rendering
- update docs
- upgrade to Elixir 1.4
- add support for Phoenix Views
- update
httpoisonto 0.11.0 andpoisonto 3.0 - clean up compiler warnings when using Elixir 1.3
- add
add_custom_argfor custom arguments - remove
raisewhen no API key is provided at compile-time
- add
add_attachmentfor attachments - bump
:poisonversion to 2
- add
add_headerto be sent with an email
- replace documentation using to
put_towithadd_to
- [Mailer] sandbox mode is fetched during runtime instead of compile time
- [Mailer] add missing insertion of template id
- [Email] Make an exposed method private
- [Email] multiple TO recipients can be added with
add_to/2andadd_to/3 - [Email] BCC recipients can be supported
- [Email] Reply-to name can be specified as third param of
put_reply_to/3 - [Email] added
put_send_at/2for delayed sending of email - [Mailer] uses V3 of the SendGrid mail send API
- [Mailer] sandbox mode can be enabled through a config setting
put_to/2no longer exists; useadd_to/2oradd_to/3insteadadd_cc/2when submitting a list of addresses no longer existsput_from_name/2no longer exists; useput_from/3and set the from_name as the third paramdelete_cc/2no longer exists
- Updated HTTPoison version for less compiler warnings when using Elixir 1.3
- Added some API to add email addresses for marketing campaigns
:sendgrid needs to be added to the list of applications in the mix.exs file.
def application do
[applications: [:sendgrid]]
end- Updated some docs