Skip to content

Commit

Permalink
Add MessageStream to TemplatedEmail
Browse files Browse the repository at this point in the history
Allows use of new stream concept when using templates.
See https://postmarkapp.com/message-streams
  • Loading branch information
wendorf committed Dec 2, 2020
1 parent 1f0f4d2 commit 0c58c74
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion email.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ type Email struct {
Attachments []Attachment `json:",omitempty"`
// Metadata: metadata
Metadata map[string]string `json:",omitempty"`
// MessageStream: metadata
// MessageStream: Set message stream ID that's used for sending. If not provided, message will default to the outbound transactional stream.
MessageStream string `json:",omitempty"`
}

Expand Down
2 changes: 2 additions & 0 deletions templates.go
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,8 @@ type TemplatedEmail struct {
TrackOpens bool `json:",omitempty"`
// Attachments: List of attachments
Attachments []Attachment `json:",omitempty"`
// MessageStream: Set message stream ID that's used for sending. If not provided, message will default to the outbound transactional stream.
MessageStream string `json:",omitempty"`
}

// SendTemplatedEmail sends an email using a template (TemplateId)
Expand Down

0 comments on commit 0c58c74

Please sign in to comment.