Skip to content

chore: add consts for event types #85

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions helpers.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package mailersend

// Activity-related event constants
const (
EventActivitySent = "activity.sent" // Fired when your email is sent from our sending servers.
EventActivityDelivered = "activity.delivered" // Fired when your email is successfully delivered with no errors.
EventActivitySoftBounced = "activity.soft_bounced" // Fired when your email is not delivered because it soft bounced.
EventActivityHardBounced = "activity.hard_bounced" // Fired when your email is not delivered.
EventActivityOpened = "activity.opened" // Fired when the recipient receives your email and opens it.
EventActivityOpenedUnique = "activity.opened_unique" // Fired when the recipient receives your email and opens it only for the first time.
EventActivityClicked = "activity.clicked" // Fired when the recipient clicks a link in your email.
EventActivityClickedUnique = "activity.clicked_unique" // Fired when the recipient clicks a link in your email only for the first time.
EventActivityUnsubscribed = "activity.unsubscribed" // Fired when the recipient unsubscribes from your emails.
EventActivitySpamComplaint = "activity.spam_complaint" // Fired when the recipient marks your emails as spam or junk.
EventActivitySurveyOpened = "activity.survey_opened" // Fired when the recipient opens an email containing a survey for the first time.
EventActivitySurveySubmitted = "activity.survey_submitted" // Fired when the recipient answers all available questions in a survey-based email or after an idle time of 30 minutes.
)

// Sender identity-related event constants
const (
EventSenderIdentityVerified = "sender_identity.verified" // Fired when the sender identity has been successfully verified.
)

// Maintenance-related event constants
const (
EventMaintenanceStart = "maintenance.start" // Fired when the maintenance period begins.
EventMaintenanceEnd = "maintenance.end" // Fired when the maintenance period ends.
)

// Inbound forward-related event constants
const (
EventInboundForwardFailed = "inbound_forward.failed" // Fired when an inbound message fails to forward.
)