Class: PreludeSDK::Models::NotifySendBatchParams::Document

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/prelude_sdk/models/notify_send_batch_params.rb

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(template_id:, to:, callback_url: nil, correlation_id: nil, document: nil, expires_at: nil, from: nil, locale: nil, preferred_channel: nil, schedule_at: nil, variables: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see PreludeSDK::Models::NotifySendBatchParams for more details.

Parameters:

  • template_id (String)

    The template identifier configured by your Customer Success team.

  • to (Array<String>)

    The list of recipients’ phone numbers in E.164 format.

  • callback_url (String) (defaults to: nil)

    The URL where webhooks will be sent for delivery events.

  • correlation_id (String) (defaults to: nil)

    A user-defined identifier to correlate this request with your internal systems.

  • document (PreludeSDK::Models::NotifySendBatchParams::Document) (defaults to: nil)

    A media attachment to include in the message header. Supported on

  • expires_at (Time) (defaults to: nil)

    The message expiration date in RFC3339 format. Messages will not be sent after t

  • from (String) (defaults to: nil)

    The Sender ID. Must be approved for your account.

  • locale (String) (defaults to: nil)

    A BCP-47 formatted locale string.

  • preferred_channel (Symbol, PreludeSDK::Models::NotifySendBatchParams::PreferredChannel) (defaults to: nil)

    Preferred channel for delivery. If unavailable, automatic fallback applies.

  • schedule_at (Time) (defaults to: nil)

    Schedule delivery in RFC3339 format. Marketing sends may be adjusted to comply w

  • variables (Hash{Symbol=>String}) (defaults to: nil)

    The variables to be replaced in the template.

  • request_options (PreludeSDK::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# File 'lib/prelude_sdk/models/notify_send_batch_params.rb', line 115

class Document < PreludeSDK::Internal::Type::BaseModel
  # @!attribute url
  #   HTTPS URL of the media file. The file extension must match the template's
  #   registered header format (PDF for DOCUMENT; PNG/JPG/JPEG/WEBP for IMAGE; MP4/3GP
  #   for VIDEO).
  #
  #   @return [String]
  required :url, String

  # @!attribute filename
  #   Filename displayed to the recipient. Required for templates with a `DOCUMENT`
  #   header; ignored for `IMAGE` and `VIDEO` headers.
  #
  #   @return [String, nil]
  optional :filename, String

  # @!method initialize(url:, filename: nil)
  #   Some parameter documentations has been truncated, see
  #   {PreludeSDK::Models::NotifySendBatchParams::Document} for more details.
  #
  #   A media attachment to include in the message header. Supported on WhatsApp
  #   templates registered with a `DOCUMENT`, `IMAGE`, or `VIDEO` header. The media
  #   type is determined by the template's registered header format; send the matching
  #   file type for each.
  #
  #   - `DOCUMENT` headers accept PDF and other document formats; `filename` is
  #     required and displayed to the recipient.
  #   - `IMAGE` headers accept `.png`, `.jpg`, `.jpeg`, and `.webp` URLs; `filename`
  #     is ignored.
  #   - `VIDEO` headers accept `.mp4` and `.3gp` URLs; `filename` is ignored.
  #
  #   @param url [String] HTTPS URL of the media file. The file extension must match the template's regist
  #
  #   @param filename [String] Filename displayed to the recipient. Required for templates with a `DOCUMENT` he
end

Instance Attribute Details

#filenameString?

Filename displayed to the recipient. Required for templates with a ‘DOCUMENT` header; ignored for `IMAGE` and `VIDEO` headers.

Returns:

  • (String, nil)


129
# File 'lib/prelude_sdk/models/notify_send_batch_params.rb', line 129

optional :filename, String

#urlString

HTTPS URL of the media file. The file extension must match the template’s registered header format (PDF for DOCUMENT; PNG/JPG/JPEG/WEBP for IMAGE; MP4/3GP for VIDEO).

Returns:

  • (String)


122
# File 'lib/prelude_sdk/models/notify_send_batch_params.rb', line 122

required :url, String