Class: Dodopayments::Models::Customers::EmailLogItem

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/dodopayments/models/customers/email_log_item.rb,
sig/dodopayments/models/customers/email_log_item.rbs

Overview

See Also:

  • Dodopayments::Resources::Customers::Emails#list

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(category:, created_at:, email_log_id:, email_type:, has_preview:, policies:, status:, failure_code: nil, failure_reason: nil, from: nil, recipient: nil, subject: nil) ⇒ Object

Some parameter documentations has been truncated, see Dodopayments::Models::Customers::EmailLogItem for more details.

Parameters:

  • The group this email belongs to: payments, refunds, subscriptions,

  • When this email was sent.

  • Identifies this email. Use it to read the body or to send it again.

  • What kind of email this is, for example payment_successful.

  • Whether this email has content to show. The content endpoint can still

  • What you may do with this email.

  • Where the email got to: sent, delivered, failed, complained or blocked.

  • (defaults to: nil)

    Why the email did not arrive. It is null unless the email failed.

  • (defaults to: nil)

    A sentence that explains failure_code. It is null unless the email

  • (defaults to: nil)

    The address the email was sent from.

  • (defaults to: nil)

    The address the email reached.

  • (defaults to: nil)

    The subject line as it was sent. Empty until the provider replicates.



# File 'lib/dodopayments/models/customers/email_log_item.rb', line 82

Instance Attribute Details

#categoryString

The group this email belongs to: payments, refunds, subscriptions, dunning_recovery, entitlements or auth.

Parameters:

Returns:



13
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 13

required :category, String

#created_atTime

When this email was sent.

Parameters:

Returns:



19
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 19

required :created_at, Time

#email_log_idString

Identifies this email. Use it to read the body or to send it again.

Parameters:

Returns:



25
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 25

required :email_log_id, String

#email_typeString

What kind of email this is, for example payment_successful.

Parameters:

Returns:



31
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 31

required :email_type, String

#failure_codeSymbol, ...

Why the email did not arrive. It is null unless the email failed.

Parameters:

Returns:



56
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 56

optional :failure_code, enum: -> { Dodopayments::Customers::EmailFailureCode }, nil?: true

#failure_reasonString?

A sentence that explains failure_code. It is null unless the email failed.

Parameters:

Returns:



62
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 62

optional :failure_reason, String, nil?: true

#fromString?

The address the email was sent from.

Parameters:

Returns:



68
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 68

optional :from, String, nil?: true

#has_previewBoolean

Whether this email has content to show. The content endpoint can still refuse, because the content is removed after 180 days.

Parameters:

Returns:



38
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 38

required :has_preview, Dodopayments::Internal::Type::Boolean

#policiesDodopayments::Models::Customers::EmailPolicies

What you may do with this email.

Parameters:

Returns:



44
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 44

required :policies, -> { Dodopayments::Customers::EmailPolicies }

#recipientString?

The address the email reached.

Parameters:

Returns:



74
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 74

optional :recipient, String, nil?: true

#statusSymbol, Dodopayments::Models::Customers::EmailLogStatus

Where the email got to: sent, delivered, failed, complained or blocked.

Parameters:

Returns:



50
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 50

required :status, enum: -> { Dodopayments::Customers::EmailLogStatus }

#subjectString?

The subject line as it was sent. Empty until the provider replicates.

Parameters:

Returns:



80
# File 'lib/dodopayments/models/customers/email_log_item.rb', line 80

optional :subject, String, nil?: true

Instance Method Details

#to_hash{

Returns:



60
# File 'sig/dodopayments/models/customers/email_log_item.rbs', line 60

def to_hash: -> {