Documentation ¶
Index ¶
- type APIConfiguration
- func (api *APIConfiguration) ExecuteRequest(req *http.Request) ([]byte, error)
- func (api *APIConfiguration) SendRequestWithBytes(ctx context.Context, method string, relativePath string, body []byte) ([]byte, error)
- func (api *APIConfiguration) SendRequestWithJSON(ctx context.Context, method string, relativePath string, body interface{}, ...) error
- func (api *APIConfiguration) SendRequestWithMaps(ctx context.Context, method string, relativePath string, ...) (map[string]json.RawMessage, error)
- func (api *APIConfiguration) SendRequestWithReader(ctx context.Context, method string, relativePath string, body io.Reader) ([]byte, error)
- type Audience
- type AudienceMember
- type AudienceResponse
- type AudienceResponseBody
- type AuditEvent
- type AuditEventActor
- type AuditEventTarget
- type Automation
- type AutomationInvokeBody
- type AutomationStep
- type AutomationTemplateInvokeBody
- type BrandColors
- type BrandEmail
- type BrandResponse
- type BrandSettings
- type BrandSnippetItem
- type BrandSnippets
- type BrandsResponse
- type Client
- func (c *Client) CancelMessage(ctx context.Context, messageID string) (*MessageResponse, error)
- func (c *Client) CancelNotificationSubmission(ctx context.Context, notificationID string, submissionID string) error
- func (c *Client) CreateJob(ctx context.Context, body interface{}) (string, error)
- func (c *Client) DeleteAudience(ctx context.Context, audienceId string) error
- func (c *Client) DeleteBrand(ctx context.Context, brandID string) error
- func (c *Client) DeleteList(ctx context.Context, listID string) error
- func (c *Client) DeleteTenant(ctx context.Context, tenantId string) error
- func (c *Client) GetAudience(ctx context.Context, audienceId string) (*AudienceResponseBody, error)
- func (c *Client) GetAudienceMembers(ctx context.Context, audienceId string, cursor string) (*GetAudienceMembersResponse, error)
- func (c *Client) GetAudiences(ctx context.Context, cursor string) (*GetAudiencesResponse, error)
- func (c *Client) GetAuditEvent(ctx context.Context, auditEventID string) (*AuditEvent, error)
- func (c *Client) GetBrand(ctx context.Context, brandID string) (*BrandResponse, error)
- func (c *Client) GetBrands(ctx context.Context, cursor string) (*BrandsResponse, error)
- func (c *Client) GetJob(ctx context.Context, jobID string) (*GetBulkJobResponse, error)
- func (c *Client) GetJobUsers(ctx context.Context, jobID string, cursor string) (*GetBulkJobUsersResponse, error)
- func (c *Client) GetList(ctx context.Context, listID string) (*ListResponse, error)
- func (c *Client) GetListSubscriptions(ctx context.Context, listID string, cursor string) (*ListSubscriptionsResponse, error)
- func (c *Client) GetLists(ctx context.Context, cursor string, pattern string) (*ListsResponse, error)
- func (c *Client) GetMessage(ctx context.Context, messageID string) (*MessageResponse, error)
- func (c *Client) GetNotificationContent(ctx context.Context, notificationID string) (*NotificationContentResponse, error)
- func (c *Client) GetNotificationDraftContent(ctx context.Context, notificationID string) (*NotificationContentResponse, error)
- func (c *Client) GetNotificationSubmissionChecks(ctx context.Context, notificationID string, submissionID string) (*NotificationSubmissionChecksResponse, error)
- func (c *Client) GetNotifications(ctx context.Context, cursor string) (*NotificationsResponse, error)
- func (c *Client) GetProfile(ctx context.Context, id string) (map[string]json.RawMessage, error)
- func (c *Client) GetTenant(ctx context.Context, tenantId string) (*Tenant, error)
- func (c *Client) GetTenants(ctx context.Context, limit string, cursor string) (*ListTenantsResponse, error)
- func (c *Client) IngestJob(ctx context.Context, jobID string, body interface{}) (*IngestBulkJobResponse, error)
- func (c *Client) InvokeAutomation(ctx context.Context, body interface{}) (string, error)
- func (c *Client) InvokeAutomationTemplate(ctx context.Context, templateId string, body interface{}) (string, error)
- func (c *Client) ListAuditEvents(ctx context.Context, cursor string) (*ListAuditEventsResponse, error)
- func (c *Client) ListSubscribe(ctx context.Context, listID string, recipientID string, body interface{}) error
- func (c *Client) ListUnsubscribe(ctx context.Context, listID string, recipientID string) error
- func (c *Client) MergeProfileBytes(ctx context.Context, id string, profile []byte) error
- func (c *Client) PostBrand(ctx context.Context, body PostBrandBody) (*BrandResponse, error)
- func (c *Client) PostListSubscriptions(ctx context.Context, listID string, body interface{}) error
- func (c *Client) PostNotificationDraftVariations(ctx context.Context, notificationID string, body interface{}) error
- func (c *Client) PostNotificationVariations(ctx context.Context, notificationID string, body interface{}) error
- func (c *Client) PutAudience(ctx context.Context, audienceId string, audience Audience) (*AudienceResponse, error)
- func (c *Client) PutBrand(ctx context.Context, brandID string, body PutBrandBody) (*BrandResponse, error)
- func (c *Client) PutList(ctx context.Context, listID string, body interface{}) error
- func (c *Client) PutListSubscriptions(ctx context.Context, listID string, body interface{}) error
- func (c *Client) PutNotificationSubmissionChecks(ctx context.Context, notificationID string, submissionID string, ...) error
- func (c *Client) PutTenant(ctx context.Context, tenantId string, body interface{}) (*Tenant, error)
- func (c *Client) RestoreList(ctx context.Context, listID string) error
- func (c *Client) RunJob(ctx context.Context, jobID string) error
- func (c *Client) Send(ctx context.Context, eventID, recipientID string, body interface{}) (string, error)
- func (c *Client) SendMap(ctx context.Context, eventID, recipientID string, body map[string]interface{}) (string, error)
- func (c *Client) SendMessage(ctx context.Context, body SendMessageRequestBody) (string, error)
- func (c *Client) SendMessageMap(ctx context.Context, body map[string]interface{}) (string, error)
- func (c *Client) SendMessageWithOptions(ctx context.Context, body map[string]interface{}, method string, ...) (string, error)
- func (c *Client) UpdateProfileBytes(ctx context.Context, id string, profile []byte) error
- type CreateJobBody
- type GetAudienceMembersResponse
- type GetAudiencesResponse
- type GetBulkJobResponse
- type GetBulkJobUsersResponse
- type HTTPError
- type IngestBulkJobResponse
- type IngestJobBody
- type Job
- type ListAuditEventsResponse
- type ListRecipient
- type ListResponse
- type ListSubscriptionBody
- type ListSubscriptionItem
- type ListSubscriptionRecipientBody
- type ListSubscriptionsResponse
- type ListTenantsResponse
- type ListsResponse
- type MessageResponse
- type NestedFilter
- type NotificationContentResponse
- type NotificationResponse
- type NotificationSubmissionChecksRequest
- type NotificationSubmissionChecksResponse
- type NotificationVariationsRequestBody
- type NotificationsResponse
- type Option
- type PagingResponse
- type PostBrandBody
- type ProvidersChannelResponse
- type ProvidersResponse
- type PutBrandBody
- type PutListBody
- type SendBody
- type SendMessageRequestBody
- type SingleFilter
- type SubmissionCheck
- type Tenant
- type WebhookResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIConfiguration ¶
APIConfiguration represents the core data needed to communicate with the Courier API
func (*APIConfiguration) ExecuteRequest ¶
func (api *APIConfiguration) ExecuteRequest(req *http.Request) ([]byte, error)
ExecuteRequest issues an HTTP request and sets headers expected by the Courier API
func (*APIConfiguration) SendRequestWithBytes ¶
func (api *APIConfiguration) SendRequestWithBytes(ctx context.Context, method string, relativePath string, body []byte) ([]byte, error)
SendRequestWithBytes wraps SendRequestWithReader
func (*APIConfiguration) SendRequestWithJSON ¶
func (api *APIConfiguration) SendRequestWithJSON(ctx context.Context, method string, relativePath string, body interface{}, response interface{}) error
SendRequestWithJSON wraps HTTPSendBytes
func (*APIConfiguration) SendRequestWithMaps ¶
func (api *APIConfiguration) SendRequestWithMaps(ctx context.Context, method string, relativePath string, body map[string]interface{}) (map[string]json.RawMessage, error)
SendRequestWithMaps wraps HTTPSendBytes
type AudienceMember ¶ added in v2.7.0
type AudienceResponse ¶ added in v2.7.0
type AudienceResponse struct {
Audience AudienceResponseBody `json:"audience"`
}
type AudienceResponseBody ¶ added in v2.7.0
type AuditEvent ¶ added in v2.7.0
type AuditEvent struct { AuditEventId string `json:"auditEventId"` Source string `json:"source"` Timestamp string `json:"timestamp"` Type string `json:"type"` Actor *AuditEventActor Target *AuditEventTarget }
AuditEvent is the type for audit event entity
type AuditEventActor ¶ added in v2.7.0
AuditEventActor is the type for audit event actor entity
type AuditEventTarget ¶ added in v2.7.0
AuditEventTarget is the type for audit event target entity
type Automation ¶ added in v2.1.0
type Automation struct { CancelationToken string `json:"cancelation_token,omitempty"` Steps []AutomationStep `json:"steps"` }
type AutomationInvokeBody ¶ added in v2.1.0
type AutomationInvokeBody struct { Automation Automation `json:"automation"` Brand string `json:"brand,omitempty"` Data interface{} `json:"data,omitempty"` Profile interface{} `json:"profile,omitempty"` Recipient string `json:"recipient,omitempty"` Template string `json:"template,omitempty"` }
type AutomationStep ¶ added in v2.1.0
type AutomationStep struct { Action string `json:"action"` Brand string `json:"brand,omitempty"` CancelationToken string `json:"cancelation_token,omitempty"` Data interface{} `json:"data,omitempty"` Duration string `json:"duration,omitempty"` If string `json:"if,omitempty"` List string `json:"list,omitempty"` Override interface{} `json:"override,omitempty"` Profile interface{} `json:"profile,omitempty"` Recipient string `json:"recipient,omitempty"` Ref string `json:"ref,omitempty"` Template string `json:"template,omitempty"` Until string `json:"until,omitempty"` }
type AutomationTemplateInvokeBody ¶ added in v2.1.0
type BrandColors ¶ added in v2.2.0
type BrandEmail ¶ added in v2.2.0
type BrandEmail struct { Header interface{} `json:"header,omitempty"` }
type BrandResponse ¶ added in v2.2.0
type BrandResponse struct { ID string Name string Created int64 Published int64 Updated int64 Settings BrandSettings Snippets BrandSnippets Version string }
type BrandSettings ¶ added in v2.2.0
type BrandSettings struct { Colors BrandColors `json:"colors,omitempty"` Email BrandEmail `json:"email,omitempty"` }
type BrandSnippetItem ¶ added in v2.2.0
type BrandSnippets ¶ added in v2.2.0
type BrandSnippets struct {
Items []*BrandSnippetItem `json:"items,omitempty"`
}
type BrandsResponse ¶ added in v2.2.0
type BrandsResponse struct { Paging *PagingResponse Results []*BrandResponse }
type Client ¶
type Client struct {
API *APIConfiguration
}
Client lets you communicate with the Courier API
func CreateClient ¶
CreateClient creates a new client for communicating with the Courier API
func (*Client) CancelMessage ¶ added in v2.12.0
CancelMessage calls the /messages/:id/cancel endpoint of the Courier API
func (*Client) CancelNotificationSubmission ¶ added in v2.4.0
func (c *Client) CancelNotificationSubmission(ctx context.Context, notificationID string, submissionID string) error
CancelNotificationSubmission calls the DELETE /notifications/{notification_id}/{submission_id}/checks endpoint of the Courier API
func (*Client) CreateJob ¶ added in v2.4.0
CreateJob calls the POST /bulk endpoint of the Courier API
func (*Client) DeleteAudience ¶ added in v2.7.0
func (*Client) DeleteBrand ¶ added in v2.2.0
DeleteBrand calls the DELETE /brands/{brand_id} endpoint of the Courier API
func (*Client) DeleteList ¶ added in v2.2.0
DeleteList calls the DELETE /lists/{list_id} endpoint of the Courier API
func (*Client) DeleteTenant ¶ added in v2.12.0
DeleteAccount calls the DELETE /accounts/:account_id endpoint of the Courier API
func (*Client) GetAudience ¶ added in v2.7.0
func (*Client) GetAudienceMembers ¶ added in v2.7.0
func (*Client) GetAudiences ¶ added in v2.7.0
func (*Client) GetAuditEvent ¶ added in v2.7.0
GetAuditEvent calls the GET /audit-events/:auditEventId endpoint of the Courier API
func (*Client) GetBrand ¶ added in v2.2.0
GetBrand calls the GET /brands/{brand_id} endpoint of the Courier API
func (*Client) GetBrands ¶ added in v2.2.0
GetBrands calls the GET /brands endpoint of the Courier API
func (*Client) GetJob ¶ added in v2.4.0
GetJob calls the GET /bulk/:jobId endpoint of the Courier API
func (*Client) GetJobUsers ¶ added in v2.4.0
func (c *Client) GetJobUsers(ctx context.Context, jobID string, cursor string) (*GetBulkJobUsersResponse, error)
GetJobUsers calls the GET /bulk/:jobId/users endpoint of the Courier API
func (*Client) GetList ¶ added in v2.2.0
GetList calls the GET /lists/{list_id} endpoint of the Courier API
func (*Client) GetListSubscriptions ¶ added in v2.2.0
func (c *Client) GetListSubscriptions(ctx context.Context, listID string, cursor string) (*ListSubscriptionsResponse, error)
GetListSubscriptions calls the GET /lists/{list_id}/subscriptions endpoint of the Courier API
func (*Client) GetLists ¶ added in v2.2.0
func (c *Client) GetLists(ctx context.Context, cursor string, pattern string) (*ListsResponse, error)
GetLists calls the GET /lists endpoint of the Courier API
func (*Client) GetMessage ¶
GetMessage calls the /messages/:id endpoint of the Courier API
func (*Client) GetNotificationContent ¶ added in v2.4.0
func (c *Client) GetNotificationContent(ctx context.Context, notificationID string) (*NotificationContentResponse, error)
GetNotificationContent calls the GET /notifications/{notification_id}/content endpoint of the Courier API
func (*Client) GetNotificationDraftContent ¶ added in v2.4.0
func (c *Client) GetNotificationDraftContent(ctx context.Context, notificationID string) (*NotificationContentResponse, error)
GetNotificationDraftContent calls the GET /notifications/{notification_id}/draft/content endpoint of the Courier API
func (*Client) GetNotificationSubmissionChecks ¶ added in v2.4.0
func (c *Client) GetNotificationSubmissionChecks(ctx context.Context, notificationID string, submissionID string) (*NotificationSubmissionChecksResponse, error)
GetNotificationSubmissionChecks calls the GET /notifications/{notification_id}/{submission_id}/checks endpoint of the Courier API
func (*Client) GetNotifications ¶ added in v2.4.0
func (c *Client) GetNotifications(ctx context.Context, cursor string) (*NotificationsResponse, error)
GetNotifications calls the GET /notifications endpoint of the Courier API
func (*Client) GetProfile ¶
GetProfile calls the GET /profiles/:id endpoint of the Courier API
func (*Client) GetTenant ¶ added in v2.12.0
GetTenant calls the GET /tenants/:tenantId endpoint of the Courier API
func (*Client) GetTenants ¶ added in v2.12.0
func (c *Client) GetTenants(ctx context.Context, limit string, cursor string) (*ListTenantsResponse, error)
GetAccounts calls the GET /tenants endpoint of the Courier API
func (*Client) IngestJob ¶ added in v2.4.0
func (c *Client) IngestJob(ctx context.Context, jobID string, body interface{}) (*IngestBulkJobResponse, error)
IngestJob calls the POST /bulk/:jobId endpoint of the Courier API
func (*Client) InvokeAutomation ¶ added in v2.1.0
Calls the POST /automations/invoke endpoint of the Courier API
func (*Client) InvokeAutomationTemplate ¶ added in v2.1.0
func (c *Client) InvokeAutomationTemplate(ctx context.Context, templateId string, body interface{}) (string, error)
Calls the POST /automations/:templateId/invoke endpoint of the Courier API
func (*Client) ListAuditEvents ¶ added in v2.7.0
func (c *Client) ListAuditEvents(ctx context.Context, cursor string) (*ListAuditEventsResponse, error)
ListAuditEvents calls the GET /audit-events endpoint of the Courier API
func (*Client) ListSubscribe ¶ added in v2.2.0
func (c *Client) ListSubscribe(ctx context.Context, listID string, recipientID string, body interface{}) error
ListSubscribe calls the PUT /lists/{list_id}/subscriptions/{recipient_id} endpoint of the Courier API
func (*Client) ListUnsubscribe ¶ added in v2.2.0
ListUnsubscribe calls the PUT /lists/{list_id}/subscriptions/{recipient_id} endpoint of the Courier API
func (*Client) MergeProfileBytes ¶
MergeProfileBytes calls the POST /profiles/:id endpoint of the Courier API
func (*Client) PostBrand ¶ added in v2.2.0
func (c *Client) PostBrand(ctx context.Context, body PostBrandBody) (*BrandResponse, error)
PostBrand calls the POST /brands endpoint of the Courier API
func (*Client) PostListSubscriptions ¶ added in v2.2.0
PostListSubscriptions calls the POST /lists/{list_id}/subscriptions endpoint of the Courier API
func (*Client) PostNotificationDraftVariations ¶ added in v2.4.0
func (c *Client) PostNotificationDraftVariations(ctx context.Context, notificationID string, body interface{}) error
PostNotificationDraftVariations calls the POST /notifications/{notification_id}/draft/variations endpoint of the Courier API
func (*Client) PostNotificationVariations ¶ added in v2.4.0
func (c *Client) PostNotificationVariations(ctx context.Context, notificationID string, body interface{}) error
PostNotificationVariations calls the POST /notifications/{notification_id}/variations endpoint of the Courier API
func (*Client) PutAudience ¶ added in v2.7.0
func (*Client) PutBrand ¶ added in v2.2.0
func (c *Client) PutBrand(ctx context.Context, brandID string, body PutBrandBody) (*BrandResponse, error)
PutBrand calls the PUT /brands/{brand_id} endpoint of the Courier API
func (*Client) PutList ¶ added in v2.2.0
PutList calls the PUT /lists/{list_id} endpoint of the Courier API
func (*Client) PutListSubscriptions ¶ added in v2.2.0
PutListSubscriptions calls the PUT /lists/{list_id}/subscriptions endpoint of the Courier API
func (*Client) PutNotificationSubmissionChecks ¶ added in v2.4.0
func (c *Client) PutNotificationSubmissionChecks(ctx context.Context, notificationID string, submissionID string, body interface{}) error
PutNotificationSubmissionChecks calls the PUT /notifications/{notification_id}/{submission_id}/checks endpoint of the Courier API
func (*Client) PutTenant ¶ added in v2.12.0
Calls the PUT /tenants/:tenantId endpoint of the Courier API
func (*Client) RestoreList ¶ added in v2.2.0
RestoreList calls the PUT /lists/{list_id}/restore endpoint of the Courier API
func (*Client) RunJob ¶ added in v2.4.0
RunJob calls the POST /bulk/:jobId/run endpoint of the Courier API
func (*Client) Send ¶
func (c *Client) Send(ctx context.Context, eventID, recipientID string, body interface{}) (string, error)
Send calls the /send endpoint of the Courier API (passing a struct)
func (*Client) SendMap ¶
func (c *Client) SendMap(ctx context.Context, eventID, recipientID string, body map[string]interface{}) (string, error)
SendMap calls the /send endpoint of the Courier API (passing maps)
func (*Client) SendMessage ¶ added in v2.5.0
SendMessage calls the enhanced /send endpoint of the Courier API with a message struct
func (*Client) SendMessageMap ¶ added in v2.5.0
SendMessageMap calls the enhanced /send endpoint of the Courier API with maps
func (*Client) SendMessageWithOptions ¶ added in v2.7.0
type CreateJobBody ¶ added in v2.4.0
type CreateJobBody struct {
Message interface{} `json:"message"`
}
CreateJobBody can be used as request body to POST /bulk
type GetAudienceMembersResponse ¶ added in v2.7.0
type GetAudienceMembersResponse struct { Items []*AudienceMember `json:"items"` Paging *PagingResponse `json:"paging"` }
type GetAudiencesResponse ¶ added in v2.7.0
type GetAudiencesResponse struct { Items []*AudienceResponseBody `json:"items"` Paging *PagingResponse }
type GetBulkJobResponse ¶ added in v2.4.0
type GetBulkJobResponse struct {
Job interface{} `json:"job"`
}
GetBulkJobResponse is type for the GET /bulk/:jobId response
type GetBulkJobUsersResponse ¶ added in v2.4.0
type GetBulkJobUsersResponse struct { Items []interface{} `json:"items"` Paging *PagingResponse }
GetBulkJobUsersResponse is type for the GET /bulk/:jobId/users response
type IngestBulkJobResponse ¶ added in v2.4.0
type IngestBulkJobResponse struct { Errors []interface{} `json:"errors"` Total int `json:"total"` }
IngestBulkJobResponse can be used to deserialize POST /bulk/:jobId response
type IngestJobBody ¶ added in v2.4.0
type IngestJobBody struct {
Users []interface{} `json:"users"`
}
IngestJobBody can be used as request body to POST /bulk/:jobId
type Job ¶ added in v2.4.0
type Job struct { Definition interface{} `json:"definition"` Enqueued int `json:"enqueued"` Failures int `json:"failures"` Received int `json:"received"` Status string `json:"status"` }
Job can be used to cast GET /bulk/jobId response to
type ListAuditEventsResponse ¶ added in v2.7.0
type ListAuditEventsResponse struct { Results []AuditEvent `json:"results"` Paging *PagingResponse }
ListAuditEventsResponse is type for the GET /audit-events response
type ListRecipient ¶ added in v2.2.0
type ListRecipient struct { RecipientID string `json:"recipientId,omitempty"` Preferences interface{} `json:"preferences,omitempty"` }
type ListResponse ¶ added in v2.2.0
type ListSubscriptionBody ¶ added in v2.2.0
type ListSubscriptionBody struct {
Recipients []ListRecipient `json:"recipients"`
}
type ListSubscriptionItem ¶ added in v2.2.0
type ListSubscriptionRecipientBody ¶ added in v2.2.0
type ListSubscriptionRecipientBody struct {
Preferences interface{} `json:"preferences,omitempty"`
}
type ListSubscriptionsResponse ¶ added in v2.2.0
type ListSubscriptionsResponse struct { Paging *PagingResponse Items []*ListSubscriptionItem }
type ListTenantsResponse ¶ added in v2.12.0
type ListTenantsResponse struct { Items []Tenant `json:"items"` HasMore bool `json:"has_more"` Url string `json:"url"` NextUrl string `json:"next_url,omitempty"` }
ListTenantsResponse is type for the GET /tenants response
type ListsResponse ¶ added in v2.2.0
type ListsResponse struct { Paging *PagingResponse Items []*ListResponse }
type MessageResponse ¶
type MessageResponse struct { ID string Event string Notification string Status string Error string Reason string Recipient string JobId string ListId string ListMessageId string RunId string Enqueued int64 Delivered int64 Sent int64 Clicked int64 Opened int64 CanceledAt int64 Providers []*ProvidersResponse }
MessageResponse represents the return of the /messages/* endpoints on the Courier API
type NestedFilter ¶ added in v2.7.0
type NestedFilter struct { Operator string `json:"operator"` Rules []SingleFilter `json:"rules"` }
type NotificationContentResponse ¶ added in v2.4.0
type NotificationContentResponse struct { Blocks []interface{} `json:"blocks"` Channels []interface{} `json:"channels,omitempty"` Checksum string `json:"checksum"` }
type NotificationResponse ¶ added in v2.4.0
type NotificationSubmissionChecksRequest ¶ added in v2.4.0
type NotificationSubmissionChecksRequest struct {
Checks []SubmissionCheck `json:"checks"`
}
type NotificationSubmissionChecksResponse ¶ added in v2.4.0
type NotificationSubmissionChecksResponse struct {
Checks []*SubmissionCheck
}
type NotificationVariationsRequestBody ¶ added in v2.4.0
type NotificationVariationsRequestBody struct { Blocks []interface{} `json:"blocks,omitempty"` Channels []interface{} `json:"channels,omitempty"` }
type NotificationsResponse ¶ added in v2.4.0
type NotificationsResponse struct { Paging *PagingResponse Results []*NotificationResponse }
type Option ¶ added in v2.7.0
type Option interface {
// contains filtered or unexported methods
}
func WithIdempotencyKey ¶ added in v2.7.0
func WithIdempotencyKeyExpiration ¶ added in v2.7.0
type PagingResponse ¶ added in v2.2.0
type PostBrandBody ¶ added in v2.2.0
type PostBrandBody struct { ID string `json:"id,omitempty"` Name string `json:"name"` Settings BrandSettings `json:"settings"` Snippets BrandSnippets `json:"snippets,omitempty"` }
type ProvidersChannelResponse ¶
ProvidersChannelResponse represents the channel section of the ProvidersResponse
type ProvidersResponse ¶
type ProvidersResponse struct { Channel *ProvidersChannelResponse Error string Status string Delivered int64 Sent int64 Clicked int64 Provider string ProviderResponse interface{} Reference interface{} }
ProvidersResponse represents the providers section of the MessageResponse
type PutBrandBody ¶ added in v2.2.0
type PutBrandBody struct { Name string `json:"name"` Settings BrandSettings `json:"settings"` Snippets BrandSnippets `json:"snippets,omitempty"` }
type PutListBody ¶ added in v2.2.0
type PutListBody struct { Name string `json:"name"` Preferences interface{} `json:"preferences,omitempty"` }
type SendBody ¶
type SendBody struct { Profile interface{} `json:"profile"` Data interface{} `json:"data"` Override interface{} `json:"override,omitempty"` Brand string `json:"brand,omitempty"` }
SendBody is the JSON body expected by Courier's /send endpoint
type SendMessageRequestBody ¶ added in v2.5.0
type SendMessageRequestBody struct {
Message interface{} `json:"message"`
}
SendMessageRequestBody is the JSON body expected by Courier's /send endpoint that accepts a message object
type SingleFilter ¶ added in v2.7.0
type SubmissionCheck ¶ added in v2.4.0
type Tenant ¶ added in v2.12.0
type Tenant struct { Id string `json:"id"` Name string `json:"name"` ParentTenantId string `json:"parent_tenant_id,omitempty"` DefaultPreferences interface{} `json:"default_preferences,omitempty"` Properties interface{} `json:"properties,omitempty"` UserProfile interface{} `json:"user_profile,omitempty"` BrandId string `json:"brand_id,omitempty"` }
Account is the type for account entity
type WebhookResponse ¶ added in v2.8.0
type WebhookResponse struct { Data MessageResponse `json:"data"` Type string `json:"type"` }
WebhookResponse represents the payload provided by an outbound webhook