From 696521a3003b8d2f67127a605e1518c86bb2e8ff Mon Sep 17 00:00:00 2001 From: Mary Zhong Date: Tue, 16 Apr 2024 17:34:59 -0400 Subject: [PATCH] feat: Support reply to email name for custom templates --- template.go | 1 + template/client.go | 12 +++++++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/template.go b/template.go index c96b184..16709b5 100644 --- a/template.go +++ b/template.go @@ -20,6 +20,7 @@ type Template struct { CanRevert bool `json:"can_revert"` CanDelete bool `json:"can_delete"` FromEmailName *string `json:"from_email_name,omitempty"` + ReplyToEmailName *string `json:"reply_to_email_name,omitempty"` DeliveredByClerk bool `json:"delivered_by_clerk"` Subject string `json:"subject"` Markup string `json:"markup"` diff --git a/template/client.go b/template/client.go index 01d65dd..a94c204 100644 --- a/template/client.go +++ b/template/client.go @@ -48,6 +48,7 @@ type UpdateParams struct { Markup *string `json:"markup,omitempty"` Body *string `json:"body,omitempty"` FromEmailName *string `json:"from_email_name,omitempty"` + ReplyToEmailName *string `json:"reply_to_email_name,omitempty"` DeliveredByClerk *bool `json:"delivered_by_clerk,omitempty"` TemplateType clerk.TemplateType `json:"-"` Slug string `json:"-"` @@ -123,11 +124,12 @@ func (c *Client) ToggleDelivery(ctx context.Context, params *ToggleDeliveryParam type PreviewParams struct { clerk.APIParams - Subject *string `json:"subject,omitempty"` - Body *string `json:"body,omitempty"` - FromEmailName *string `json:"from_email_name,omitempty"` - TemplateType clerk.TemplateType `json:"-"` - Slug string `json:"-"` + Subject *string `json:"subject,omitempty"` + Body *string `json:"body,omitempty"` + FromEmailName *string `json:"from_email_name,omitempty"` + ReplyToEmailName *string `json:"reply_to_email_name,omitempty"` + TemplateType clerk.TemplateType `json:"-"` + Slug string `json:"-"` } // Preview returns a preview of a template.