Class: WhopSDK::Models::AudienceCreateParams::ColumnMapping

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/audience_create_params.rb,
sig/whop_sdk/models/audience_create_params.rbs

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(country: nil, email: nil, first_name: nil, last_name: nil, phone: nil) ⇒ Object

Maps supported identity fields to CSV column headers. Map at least one of email or phone.

Parameters:

  • country (String) (defaults to: nil)

    CSV header for ISO 3166-1 alpha-2 country codes, such as US.

  • email (String) (defaults to: nil)

    CSV header for email addresses.

  • first_name (String) (defaults to: nil)

    CSV header for first names.

  • last_name (String) (defaults to: nil)

    CSV header for last names.

  • phone (String) (defaults to: nil)

    CSV header for phone numbers.



49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/whop_sdk/models/audience_create_params.rb', line 49

class ColumnMapping < WhopSDK::Internal::Type::BaseModel
  # @!attribute country
  #   CSV header for ISO 3166-1 alpha-2 country codes, such as `US`.
  #
  #   @return [String, nil]
  optional :country, String

  # @!attribute email
  #   CSV header for email addresses.
  #
  #   @return [String, nil]
  optional :email, String

  # @!attribute first_name
  #   CSV header for first names.
  #
  #   @return [String, nil]
  optional :first_name, String

  # @!attribute last_name
  #   CSV header for last names.
  #
  #   @return [String, nil]
  optional :last_name, String

  # @!attribute phone
  #   CSV header for phone numbers.
  #
  #   @return [String, nil]
  optional :phone, String

  # @!method initialize(country: nil, email: nil, first_name: nil, last_name: nil, phone: nil)
  #   Maps supported identity fields to CSV column headers. Map at least one of
  #   `email` or `phone`.
  #
  #   @param country [String] CSV header for ISO 3166-1 alpha-2 country codes, such as `US`.
  #
  #   @param email [String] CSV header for email addresses.
  #
  #   @param first_name [String] CSV header for first names.
  #
  #   @param last_name [String] CSV header for last names.
  #
  #   @param phone [String] CSV header for phone numbers.
end

Instance Attribute Details

#countryString?

CSV header for ISO 3166-1 alpha-2 country codes, such as US.

Parameters:

  • (String)

Returns:

  • (String, nil)


54
# File 'lib/whop_sdk/models/audience_create_params.rb', line 54

optional :country, String

#emailString?

CSV header for email addresses.

Parameters:

  • (String)

Returns:

  • (String, nil)


60
# File 'lib/whop_sdk/models/audience_create_params.rb', line 60

optional :email, String

#first_nameString?

CSV header for first names.

Parameters:

  • (String)

Returns:

  • (String, nil)


66
# File 'lib/whop_sdk/models/audience_create_params.rb', line 66

optional :first_name, String

#last_nameString?

CSV header for last names.

Parameters:

  • (String)

Returns:

  • (String, nil)


72
# File 'lib/whop_sdk/models/audience_create_params.rb', line 72

optional :last_name, String

#phoneString?

CSV header for phone numbers.

Parameters:

  • (String)

Returns:

  • (String, nil)


78
# File 'lib/whop_sdk/models/audience_create_params.rb', line 78

optional :phone, String

Instance Method Details

#to_hash{

Returns:

  • ({)


78
# File 'sig/whop_sdk/models/audience_create_params.rbs', line 78

def to_hash: -> {