sentdm 0.42.0 → 0.43.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 91298412ba815aa1aefa4431e1f16bac55ece7b215c03e96e6bd0dcec391cc59
4
- data.tar.gz: ac860df70dcee9fe90c2baf7625345a13ca6452f3385598f12a1e62f26e4373c
3
+ metadata.gz: a7d3a7f430c5492691ca1a23247fcbed3e2e2ff8e91844ba029537d709d9a963
4
+ data.tar.gz: 7d8d1051da8284366c7285bbeecc1f927a645b9cdcb18cf5a68bacbe3e009f73
5
5
  SHA512:
6
- metadata.gz: 4ee33c112e7872856f29d124fbaa5afe502d4cf6c1af80dca68fe886d2fafce869d94ef114720095fad54e8963f0f14eac3b1ebb83f76efc4c3f0f67a17ef357
7
- data.tar.gz: 6aef3d9014fbc182ee9c73b16f325c9d38218d2f236dc18e73bbcfa9b5a9aae77a3e45350eecd83eca36802a5578091f248522eee51d7a03c1b6bc755b3f839a
6
+ metadata.gz: 0756dc34c4532cfb11b7956b378108f455a48ad0c791b04a059db712335c4d91333c27f4d3275d388535dd69f6be360f3f7900aa554b1b5c040d727639702cb4
7
+ data.tar.gz: 35bbb4d69ac43c7f8bce02a02a6b87b3c709513ef1615ef597ef29aaf49ef675b0853a43c3c025beb562f53f09cbb2962d023639c657db7332ca5ee54749b6fa
data/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.43.0](https://github.com/sentdm/sent-dm-ruby/compare/v0.42.1...v0.43.0) (2026-11-03)
4
+
5
+
6
+ ### Features
7
+
8
+ * **api:** add messages.resend to resend a message on its id ([9a2f65f](https://github.com/sentdm/sent-dm-ruby/commit/9a2f65f47bee3c3dc784eb32fcb9a081f242ef50))
9
+
10
+ ## [0.42.1](https://github.com/sentdm/sent-dm-ruby/compare/v0.42.0...v0.42.1) (2026-10-30)
11
+
12
+
13
+ ### Documentation
14
+
15
+ * **api:** describe the default body type on template bodies ([39e5ddd](https://github.com/sentdm/sent-dm-ruby/commit/39e5ddd45ee5ca7dce4938cdbaa75b4cbe23e196))
16
+
3
17
  ## [0.42.0](https://github.com/sentdm/sent-dm-ruby/compare/v0.41.0...v0.42.0) (2026-10-30)
4
18
 
5
19
 
data/README.md CHANGED
@@ -17,7 +17,7 @@ To use this gem, install via Bundler by adding the following to your application
17
17
  <!-- x-release-please-start-version -->
18
18
 
19
19
  ```ruby
20
- gem "sentdm", "~> 0.42.0"
20
+ gem "sentdm", "~> 0.43.0"
21
21
  ```
22
22
 
23
23
  <!-- x-release-please-end -->
@@ -32,7 +32,7 @@ sent = Sentdm::Client.new(
32
32
  api_key: ENV["SENT_DM_API_KEY"] # This is the default and can be omitted
33
33
  )
34
34
 
35
- response = sent.messages.send_(
35
+ message_send_response = sent.messages.send_(
36
36
  channel: ["sms", "whatsapp"],
37
37
  template: {
38
38
  id: "7ba7b820-9dad-11d1-80b4-00c04fd430c8",
@@ -42,7 +42,7 @@ response = sent.messages.send_(
42
42
  to: ["+14155551234", "+14155555678"]
43
43
  )
44
44
 
45
- puts(response.data)
45
+ puts(message_send_response.data)
46
46
  ```
47
47
 
48
48
  ### Pagination
@@ -192,7 +192,7 @@ You can send undocumented parameters to any endpoint, and read undocumented resp
192
192
  Note: the `extra_` parameters of the same name overrides the documented parameters.
193
193
 
194
194
  ```ruby
195
- response =
195
+ message_send_response =
196
196
  sent.messages.send_(
197
197
  channel: ["sms"],
198
198
  template: {
@@ -208,7 +208,7 @@ response =
208
208
  }
209
209
  )
210
210
 
211
- puts(response[:my_undocumented_property])
211
+ puts(message_send_response[:my_undocumented_property])
212
212
  ```
213
213
 
214
214
  #### Undocumented request params
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Messages#resend
6
+ class MessageResendParams < Sentdm::Models::MutationRequest
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute id
11
+ #
12
+ # @return [String]
13
+ required :id, String
14
+
15
+ # @!attribute idempotency_key
16
+ #
17
+ # @return [String, nil]
18
+ optional :idempotency_key, String
19
+
20
+ # @!attribute x_profile_id
21
+ #
22
+ # @return [String, nil]
23
+ optional :x_profile_id, String
24
+
25
+ # @!method initialize(id:, idempotency_key: nil, x_profile_id: nil, request_options: {})
26
+ # @param id [String]
27
+ # @param idempotency_key [String]
28
+ # @param x_profile_id [String]
29
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
30
+ end
31
+ end
32
+ end
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Sentdm
4
4
  module Models
5
- # @see Sentdm::Resources::Messages#send_
5
+ # @see Sentdm::Resources::Messages#resend
6
6
  class MessageSendResponse < Sentdm::Internal::Type::BaseModel
7
7
  # @!attribute data
8
8
  # The result of a multi-recipient send.
@@ -19,7 +19,7 @@ module Sentdm
19
19
  # which of the two to answer with. From always returns this type.
20
20
  #
21
21
  # @return [Sentdm::Models::MessageSendResponse::Data, nil]
22
- optional :data, -> { Sentdm::Models::MessageSendResponse::Data }, nil?: true
22
+ optional :data, -> { Sentdm::MessageSendResponse::Data }, nil?: true
23
23
 
24
24
  # @!attribute error
25
25
  # Error information
@@ -58,8 +58,7 @@ module Sentdm
58
58
  # @!attribute recipients
59
59
  #
60
60
  # @return [Array<Sentdm::Models::MessageSendResponse::Data::Recipient>, nil]
61
- optional :recipients,
62
- -> { Sentdm::Internal::Type::ArrayOf[Sentdm::Models::MessageSendResponse::Data::Recipient] }
61
+ optional :recipients, -> { Sentdm::Internal::Type::ArrayOf[Sentdm::MessageSendResponse::Data::Recipient] }
63
62
 
64
63
  # @!attribute status
65
64
  # QUEUED: the batch is accepted. A request that carried scheduled_at is QUEUED
@@ -31,9 +31,9 @@ module Sentdm
31
31
  required :template, String
32
32
 
33
33
  # @!attribute type
34
- # The type of body content — send "text". It is dropped from the stored definition
35
- # when null, so a body posted without it is saved with no type key at all and the
36
- # template editor has nothing to render the block from.
34
+ # The type of body content. Defaults to "text" when omitted, which also fills it
35
+ # in when reading stored bodies saved without it; the template editor refuses to
36
+ # load a body with no type.
37
37
  #
38
38
  # @return [String, nil]
39
39
  optional :type, String, nil?: true
@@ -51,7 +51,7 @@ module Sentdm
51
51
  #
52
52
  # @param template [String] The body copy, with variables written as {{index:variable}}.
53
53
  #
54
- # @param type [String, nil] The type of body content — send "text". It is dropped from the stored definition
54
+ # @param type [String, nil] The type of body content. Defaults to "text" when omitted, which also fills it i
55
55
  #
56
56
  # @param variables [Array<Sentdm::Models::TemplateVariable>, nil] The variables referenced by the body copy, one entry per {{index:variable}} plac
57
57
  end
data/lib/sentdm/models.rb CHANGED
@@ -117,12 +117,16 @@ module Sentdm
117
117
 
118
118
  MessageEventPayload = Sentdm::Models::MessageEventPayload
119
119
 
120
+ MessageResendParams = Sentdm::Models::MessageResendParams
121
+
120
122
  MessageRetrieveActivitiesParams = Sentdm::Models::MessageRetrieveActivitiesParams
121
123
 
122
124
  MessageRetrieveStatusParams = Sentdm::Models::MessageRetrieveStatusParams
123
125
 
124
126
  MessageSendParams = Sentdm::Models::MessageSendParams
125
127
 
128
+ MessageSendResponse = Sentdm::Models::MessageSendResponse
129
+
126
130
  MutationRequest = Sentdm::Models::MutationRequest
127
131
 
128
132
  NumberLookupParams = Sentdm::Models::NumberLookupParams
@@ -25,6 +25,67 @@ module Sentdm
25
25
  # released yet. Cancelling is free, fires `message.cancelled`, and is final — a
26
26
  # cancelled message cannot be resent.
27
27
  class Messages
28
+ # Some parameter documentations has been truncated, see
29
+ # {Sentdm::Models::MessageResendParams} for more details.
30
+ #
31
+ # Resends a message you already sent, on the same message id, without rebuilding
32
+ # the request. The typical use is recovering a BLOCKED message — for example one
33
+ # refused for insufficient balance — after the account has been topped up.
34
+ #
35
+ # **A resend bills again.** Each accepted resend is a new delivery attempt and
36
+ # records a new charge against the same message id; a client that resends on every
37
+ # failure is charged on every loop.
38
+ #
39
+ # **Every policy runs again.** The resend goes back through the full send pipeline
40
+ # — consent, balance, KYC and channel quota, template approval, quiet hours and
41
+ # channel health — so it can land on BLOCKED, FILTERED or SCHEDULED again rather
42
+ # than being sent, exactly as a fresh send would. Status webhooks (message.sent,
43
+ # message.blocked, message.filtered, message.failed) fire again for the same
44
+ # message id, so consumers keyed on the id will see repeated transitions.
45
+ #
46
+ # **What can be resent.** A message in a terminal state — DELIVERED, FAILED, READ
47
+ # or BLOCKED — or one stuck at SENT for more than 15 minutes. A FILTERED message
48
+ # can never be resent: the recipient opted out or a routing rule refused the send.
49
+ # A message still in flight (QUEUED, PROCESSED, ROUTED), held for quiet hours
50
+ # (SCHEDULED), or SENT less than 15 minutes ago returns 409. Two concurrent
51
+ # resends of one id are serialised: one is accepted, the other gets 409.
52
+ #
53
+ # The resend keeps the channel the message was originally requested on; the
54
+ # channel cannot be changed on a resend — send a new message instead.
55
+ # `Idempotency-Key` is honoured, so a retried request replays the first accepted
56
+ # response instead of resending twice.
57
+ #
58
+ # The response has the same shape as `POST /v3/messages`: `recipients` has a
59
+ # single entry whose `message_id` is the id you resent.
60
+ #
61
+ # @overload resend(id, sandbox: nil, idempotency_key: nil, x_profile_id: nil, request_options: {})
62
+ #
63
+ # @param id [String] Path param: Message ID
64
+ #
65
+ # @param sandbox [Boolean] Body param: Sandbox flag - when true, the operation is simulated without side ef
66
+ #
67
+ # @param idempotency_key [String] Header param: Unique key to ensure idempotent request processing. Must be 1-255
68
+ #
69
+ # @param x_profile_id [String] Header param: Profile UUID to scope the request to a child profile. Only organiz
70
+ #
71
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
72
+ #
73
+ # @return [Sentdm::Models::MessageSendResponse]
74
+ #
75
+ # @see Sentdm::Models::MessageResendParams
76
+ def resend(id, params = {})
77
+ parsed, options = Sentdm::MessageResendParams.dump_request(params)
78
+ header_params = {idempotency_key: "idempotency-key", x_profile_id: "x-profile-id"}
79
+ @client.request(
80
+ method: :post,
81
+ path: ["v3/messages/%1$s/resend", id],
82
+ headers: parsed.slice(*header_params.keys).transform_keys(header_params),
83
+ body: parsed.except(*header_params.keys),
84
+ model: Sentdm::MessageSendResponse,
85
+ options: options
86
+ )
87
+ end
88
+
28
89
  # Some parameter documentations has been truncated, see
29
90
  # {Sentdm::Models::MessageRetrieveActivitiesParams} for more details.
30
91
  #
@@ -163,7 +224,7 @@ module Sentdm
163
224
  path: "v3/messages",
164
225
  headers: parsed.slice(*header_params.keys).transform_keys(header_params),
165
226
  body: parsed.except(*header_params.keys),
166
- model: Sentdm::Models::MessageSendResponse,
227
+ model: Sentdm::MessageSendResponse,
167
228
  options: options
168
229
  )
169
230
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Sentdm
4
- VERSION = "0.42.0"
4
+ VERSION = "0.43.0"
5
5
  end
data/lib/sentdm.rb CHANGED
@@ -118,6 +118,7 @@ require_relative "sentdm/models/me_retrieve_params"
118
118
  require_relative "sentdm/models/me_retrieve_response"
119
119
  require_relative "sentdm/models/message_event"
120
120
  require_relative "sentdm/models/message_event_payload"
121
+ require_relative "sentdm/models/message_resend_params"
121
122
  require_relative "sentdm/models/message_retrieve_activities_params"
122
123
  require_relative "sentdm/models/message_retrieve_activities_response"
123
124
  require_relative "sentdm/models/message_retrieve_status_params"
@@ -0,0 +1,59 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ class MessageResendParams < Sentdm::Models::MutationRequest
6
+ extend Sentdm::Internal::Type::RequestParameters::Converter
7
+ include Sentdm::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(Sentdm::MessageResendParams, Sentdm::Internal::AnyHash)
12
+ end
13
+
14
+ sig { returns(String) }
15
+ attr_accessor :id
16
+
17
+ sig { returns(T.nilable(String)) }
18
+ attr_reader :idempotency_key
19
+
20
+ sig { params(idempotency_key: String).void }
21
+ attr_writer :idempotency_key
22
+
23
+ sig { returns(T.nilable(String)) }
24
+ attr_reader :x_profile_id
25
+
26
+ sig { params(x_profile_id: String).void }
27
+ attr_writer :x_profile_id
28
+
29
+ sig do
30
+ params(
31
+ id: String,
32
+ idempotency_key: String,
33
+ x_profile_id: String,
34
+ request_options: Sentdm::RequestOptions::OrHash
35
+ ).returns(T.attached_class)
36
+ end
37
+ def self.new(
38
+ id:,
39
+ idempotency_key: nil,
40
+ x_profile_id: nil,
41
+ request_options: {}
42
+ )
43
+ end
44
+
45
+ sig do
46
+ override.returns(
47
+ {
48
+ id: String,
49
+ idempotency_key: String,
50
+ x_profile_id: String,
51
+ request_options: Sentdm::RequestOptions
52
+ }
53
+ )
54
+ end
55
+ def to_hash
56
+ end
57
+ end
58
+ end
59
+ end
@@ -5,7 +5,7 @@ module Sentdm
5
5
  class MessageSendResponse < Sentdm::Internal::Type::BaseModel
6
6
  OrHash =
7
7
  T.type_alias do
8
- T.any(Sentdm::Models::MessageSendResponse, Sentdm::Internal::AnyHash)
8
+ T.any(Sentdm::MessageSendResponse, Sentdm::Internal::AnyHash)
9
9
  end
10
10
 
11
11
  # The result of a multi-recipient send.
@@ -20,13 +20,11 @@ module Sentdm
20
20
  # The shape of an immediate send: it never has a scheduled_at key. A send that
21
21
  # carried scheduled_at is a ScheduledSendMessageResponse, and the endpoint decides
22
22
  # which of the two to answer with. From always returns this type.
23
- sig { returns(T.nilable(Sentdm::Models::MessageSendResponse::Data)) }
23
+ sig { returns(T.nilable(Sentdm::MessageSendResponse::Data)) }
24
24
  attr_reader :data
25
25
 
26
26
  sig do
27
- params(
28
- data: T.nilable(Sentdm::Models::MessageSendResponse::Data::OrHash)
29
- ).void
27
+ params(data: T.nilable(Sentdm::MessageSendResponse::Data::OrHash)).void
30
28
  end
31
29
  attr_writer :data
32
30
 
@@ -54,7 +52,7 @@ module Sentdm
54
52
  # Standard API response envelope for all v3 endpoints
55
53
  sig do
56
54
  params(
57
- data: T.nilable(Sentdm::Models::MessageSendResponse::Data::OrHash),
55
+ data: T.nilable(Sentdm::MessageSendResponse::Data::OrHash),
58
56
  error: T.nilable(Sentdm::ErrorDetail::OrHash),
59
57
  meta: Sentdm::APIMeta::OrHash,
60
58
  success: T::Boolean
@@ -86,7 +84,7 @@ module Sentdm
86
84
  sig do
87
85
  override.returns(
88
86
  {
89
- data: T.nilable(Sentdm::Models::MessageSendResponse::Data),
87
+ data: T.nilable(Sentdm::MessageSendResponse::Data),
90
88
  error: T.nilable(Sentdm::ErrorDetail),
91
89
  meta: Sentdm::APIMeta,
92
90
  success: T::Boolean
@@ -99,17 +97,12 @@ module Sentdm
99
97
  class Data < Sentdm::Internal::Type::BaseModel
100
98
  OrHash =
101
99
  T.type_alias do
102
- T.any(
103
- Sentdm::Models::MessageSendResponse::Data,
104
- Sentdm::Internal::AnyHash
105
- )
100
+ T.any(Sentdm::MessageSendResponse::Data, Sentdm::Internal::AnyHash)
106
101
  end
107
102
 
108
103
  sig do
109
104
  returns(
110
- T.nilable(
111
- T::Array[Sentdm::Models::MessageSendResponse::Data::Recipient]
112
- )
105
+ T.nilable(T::Array[Sentdm::MessageSendResponse::Data::Recipient])
113
106
  )
114
107
  end
115
108
  attr_reader :recipients
@@ -117,9 +110,7 @@ module Sentdm
117
110
  sig do
118
111
  params(
119
112
  recipients:
120
- T::Array[
121
- Sentdm::Models::MessageSendResponse::Data::Recipient::OrHash
122
- ]
113
+ T::Array[Sentdm::MessageSendResponse::Data::Recipient::OrHash]
123
114
  ).void
124
115
  end
125
116
  attr_writer :recipients
@@ -160,9 +151,7 @@ module Sentdm
160
151
  sig do
161
152
  params(
162
153
  recipients:
163
- T::Array[
164
- Sentdm::Models::MessageSendResponse::Data::Recipient::OrHash
165
- ],
154
+ T::Array[Sentdm::MessageSendResponse::Data::Recipient::OrHash],
166
155
  status: String,
167
156
  template_id: String,
168
157
  template_name: String
@@ -183,7 +172,7 @@ module Sentdm
183
172
  override.returns(
184
173
  {
185
174
  recipients:
186
- T::Array[Sentdm::Models::MessageSendResponse::Data::Recipient],
175
+ T::Array[Sentdm::MessageSendResponse::Data::Recipient],
187
176
  status: String,
188
177
  template_id: String,
189
178
  template_name: String
@@ -197,7 +186,7 @@ module Sentdm
197
186
  OrHash =
198
187
  T.type_alias do
199
188
  T.any(
200
- Sentdm::Models::MessageSendResponse::Data::Recipient,
189
+ Sentdm::MessageSendResponse::Data::Recipient,
201
190
  Sentdm::Internal::AnyHash
202
191
  )
203
192
  end
@@ -33,9 +33,9 @@ module Sentdm
33
33
  sig { returns(String) }
34
34
  attr_accessor :template
35
35
 
36
- # The type of body content — send "text". It is dropped from the stored definition
37
- # when null, so a body posted without it is saved with no type key at all and the
38
- # template editor has nothing to render the block from.
36
+ # The type of body content. Defaults to "text" when omitted, which also fills it
37
+ # in when reading stored bodies saved without it; the template editor refuses to
38
+ # load a body with no type.
39
39
  sig { returns(T.nilable(String)) }
40
40
  attr_accessor :type
41
41
 
@@ -75,9 +75,9 @@ module Sentdm
75
75
  # you on board." — two variables, so at least five words are required, and the
76
76
  # copy after the final variable contains letters.
77
77
  template:,
78
- # The type of body content — send "text". It is dropped from the stored definition
79
- # when null, so a body posted without it is saved with no type key at all and the
80
- # template editor has nothing to render the block from.
78
+ # The type of body content. Defaults to "text" when omitted, which also fills it
79
+ # in when reading stored bodies saved without it; the template editor refuses to
80
+ # load a body with no type.
81
81
  type: nil,
82
82
  # The variables referenced by the body copy, one entry per {{index:variable}}
83
83
  # placeholder.
@@ -83,6 +83,8 @@ module Sentdm
83
83
 
84
84
  MessageEventPayload = Sentdm::Models::MessageEventPayload
85
85
 
86
+ MessageResendParams = Sentdm::Models::MessageResendParams
87
+
86
88
  MessageRetrieveActivitiesParams =
87
89
  Sentdm::Models::MessageRetrieveActivitiesParams
88
90
 
@@ -90,6 +92,8 @@ module Sentdm
90
92
 
91
93
  MessageSendParams = Sentdm::Models::MessageSendParams
92
94
 
95
+ MessageSendResponse = Sentdm::Models::MessageSendResponse
96
+
93
97
  MutationRequest = Sentdm::Models::MutationRequest
94
98
 
95
99
  NumberLookupParams = Sentdm::Models::NumberLookupParams
@@ -25,6 +25,62 @@ module Sentdm
25
25
  # released yet. Cancelling is free, fires `message.cancelled`, and is final — a
26
26
  # cancelled message cannot be resent.
27
27
  class Messages
28
+ # Resends a message you already sent, on the same message id, without rebuilding
29
+ # the request. The typical use is recovering a BLOCKED message — for example one
30
+ # refused for insufficient balance — after the account has been topped up.
31
+ #
32
+ # **A resend bills again.** Each accepted resend is a new delivery attempt and
33
+ # records a new charge against the same message id; a client that resends on every
34
+ # failure is charged on every loop.
35
+ #
36
+ # **Every policy runs again.** The resend goes back through the full send pipeline
37
+ # — consent, balance, KYC and channel quota, template approval, quiet hours and
38
+ # channel health — so it can land on BLOCKED, FILTERED or SCHEDULED again rather
39
+ # than being sent, exactly as a fresh send would. Status webhooks (message.sent,
40
+ # message.blocked, message.filtered, message.failed) fire again for the same
41
+ # message id, so consumers keyed on the id will see repeated transitions.
42
+ #
43
+ # **What can be resent.** A message in a terminal state — DELIVERED, FAILED, READ
44
+ # or BLOCKED — or one stuck at SENT for more than 15 minutes. A FILTERED message
45
+ # can never be resent: the recipient opted out or a routing rule refused the send.
46
+ # A message still in flight (QUEUED, PROCESSED, ROUTED), held for quiet hours
47
+ # (SCHEDULED), or SENT less than 15 minutes ago returns 409. Two concurrent
48
+ # resends of one id are serialised: one is accepted, the other gets 409.
49
+ #
50
+ # The resend keeps the channel the message was originally requested on; the
51
+ # channel cannot be changed on a resend — send a new message instead.
52
+ # `Idempotency-Key` is honoured, so a retried request replays the first accepted
53
+ # response instead of resending twice.
54
+ #
55
+ # The response has the same shape as `POST /v3/messages`: `recipients` has a
56
+ # single entry whose `message_id` is the id you resent.
57
+ sig do
58
+ params(
59
+ id: String,
60
+ sandbox: T::Boolean,
61
+ idempotency_key: String,
62
+ x_profile_id: String,
63
+ request_options: Sentdm::RequestOptions::OrHash
64
+ ).returns(Sentdm::MessageSendResponse)
65
+ end
66
+ def resend(
67
+ # Path param: Message ID
68
+ id,
69
+ # Body param: Sandbox flag - when true, the operation is simulated without side
70
+ # effects Useful for testing integrations without actual execution
71
+ sandbox: nil,
72
+ # Header param: Unique key to ensure idempotent request processing. Must be 1-255
73
+ # alphanumeric characters, hyphens, or underscores. Responses are cached for 24
74
+ # hours per key per customer.
75
+ idempotency_key: nil,
76
+ # Header param: Profile UUID to scope the request to a child profile. Only
77
+ # organization API keys can use this header. The profile must belong to the
78
+ # calling organization.
79
+ x_profile_id: nil,
80
+ request_options: {}
81
+ )
82
+ end
83
+
28
84
  # Retrieves the activity log for a specific message. Activities track the message
29
85
  # lifecycle including acceptance, processing, sending, delivery, and any errors. A
30
86
  # SCHEDULED entry carries scheduled_at, the release instant in UTC as it stood at
@@ -124,7 +180,7 @@ module Sentdm
124
180
  idempotency_key: String,
125
181
  x_profile_id: String,
126
182
  request_options: Sentdm::RequestOptions::OrHash
127
- ).returns(Sentdm::Models::MessageSendResponse)
183
+ ).returns(Sentdm::MessageSendResponse)
128
184
  end
129
185
  def send_(
130
186
  # Body param: Channels to broadcast on, e.g. ["whatsapp", "sms"]. Each channel
@@ -0,0 +1,38 @@
1
+ module Sentdm
2
+ module Models
3
+ type message_resend_params =
4
+ { id: String, idempotency_key: String, x_profile_id: String }
5
+ & Sentdm::Internal::Type::request_parameters
6
+
7
+ class MessageResendParams < Sentdm::Models::MutationRequest
8
+ extend Sentdm::Internal::Type::RequestParameters::Converter
9
+ include Sentdm::Internal::Type::RequestParameters
10
+
11
+ def id: -> String
12
+
13
+ def id=: (String _) -> String
14
+
15
+ def idempotency_key: -> String?
16
+
17
+ def idempotency_key=: (String _) -> String
18
+
19
+ def x_profile_id: -> String?
20
+
21
+ def x_profile_id=: (String _) -> String
22
+
23
+ def initialize: (
24
+ id: String,
25
+ ?idempotency_key: String,
26
+ ?x_profile_id: String,
27
+ ?request_options: Sentdm::request_opts
28
+ ) -> void
29
+
30
+ def to_hash: -> {
31
+ id: String,
32
+ idempotency_key: String,
33
+ x_profile_id: String,
34
+ request_options: Sentdm::RequestOptions
35
+ }
36
+ end
37
+ end
38
+ end
@@ -2,14 +2,14 @@ module Sentdm
2
2
  module Models
3
3
  type message_send_response =
4
4
  {
5
- data: Sentdm::Models::MessageSendResponse::Data?,
5
+ data: Sentdm::MessageSendResponse::Data?,
6
6
  error: Sentdm::ErrorDetail?,
7
7
  meta: Sentdm::APIMeta,
8
8
  success: bool
9
9
  }
10
10
 
11
11
  class MessageSendResponse < Sentdm::Internal::Type::BaseModel
12
- attr_accessor data: Sentdm::Models::MessageSendResponse::Data?
12
+ attr_accessor data: Sentdm::MessageSendResponse::Data?
13
13
 
14
14
  attr_accessor error: Sentdm::ErrorDetail?
15
15
 
@@ -22,14 +22,14 @@ module Sentdm
22
22
  def success=: (bool) -> bool
23
23
 
24
24
  def initialize: (
25
- ?data: Sentdm::Models::MessageSendResponse::Data?,
25
+ ?data: Sentdm::MessageSendResponse::Data?,
26
26
  ?error: Sentdm::ErrorDetail?,
27
27
  ?meta: Sentdm::APIMeta,
28
28
  ?success: bool
29
29
  ) -> void
30
30
 
31
31
  def to_hash: -> {
32
- data: Sentdm::Models::MessageSendResponse::Data?,
32
+ data: Sentdm::MessageSendResponse::Data?,
33
33
  error: Sentdm::ErrorDetail?,
34
34
  meta: Sentdm::APIMeta,
35
35
  success: bool
@@ -37,18 +37,18 @@ module Sentdm
37
37
 
38
38
  type data =
39
39
  {
40
- recipients: ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient],
40
+ recipients: ::Array[Sentdm::MessageSendResponse::Data::Recipient],
41
41
  status: String,
42
42
  template_id: String,
43
43
  template_name: String
44
44
  }
45
45
 
46
46
  class Data < Sentdm::Internal::Type::BaseModel
47
- attr_reader recipients: ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient]?
47
+ attr_reader recipients: ::Array[Sentdm::MessageSendResponse::Data::Recipient]?
48
48
 
49
49
  def recipients=: (
50
- ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient]
51
- ) -> ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient]
50
+ ::Array[Sentdm::MessageSendResponse::Data::Recipient]
51
+ ) -> ::Array[Sentdm::MessageSendResponse::Data::Recipient]
52
52
 
53
53
  attr_reader status: String?
54
54
 
@@ -63,14 +63,14 @@ module Sentdm
63
63
  def template_name=: (String) -> String
64
64
 
65
65
  def initialize: (
66
- ?recipients: ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient],
66
+ ?recipients: ::Array[Sentdm::MessageSendResponse::Data::Recipient],
67
67
  ?status: String,
68
68
  ?template_id: String,
69
69
  ?template_name: String
70
70
  ) -> void
71
71
 
72
72
  def to_hash: -> {
73
- recipients: ::Array[Sentdm::Models::MessageSendResponse::Data::Recipient],
73
+ recipients: ::Array[Sentdm::MessageSendResponse::Data::Recipient],
74
74
  status: String,
75
75
  template_id: String,
76
76
  template_name: String
@@ -77,12 +77,16 @@ module Sentdm
77
77
 
78
78
  class MessageEventPayload = Sentdm::Models::MessageEventPayload
79
79
 
80
+ class MessageResendParams = Sentdm::Models::MessageResendParams
81
+
80
82
  class MessageRetrieveActivitiesParams = Sentdm::Models::MessageRetrieveActivitiesParams
81
83
 
82
84
  class MessageRetrieveStatusParams = Sentdm::Models::MessageRetrieveStatusParams
83
85
 
84
86
  class MessageSendParams = Sentdm::Models::MessageSendParams
85
87
 
88
+ class MessageSendResponse = Sentdm::Models::MessageSendResponse
89
+
86
90
  class MutationRequest = Sentdm::Models::MutationRequest
87
91
 
88
92
  class NumberLookupParams = Sentdm::Models::NumberLookupParams
@@ -1,6 +1,14 @@
1
1
  module Sentdm
2
2
  module Resources
3
3
  class Messages
4
+ def resend: (
5
+ String id,
6
+ ?sandbox: bool,
7
+ ?idempotency_key: String,
8
+ ?x_profile_id: String,
9
+ ?request_options: Sentdm::request_opts
10
+ ) -> Sentdm::MessageSendResponse
11
+
4
12
  def retrieve_activities: (
5
13
  String id,
6
14
  ?x_profile_id: String,
@@ -26,7 +34,7 @@ module Sentdm
26
34
  ?idempotency_key: String,
27
35
  ?x_profile_id: String,
28
36
  ?request_options: Sentdm::request_opts
29
- ) -> Sentdm::Models::MessageSendResponse
37
+ ) -> Sentdm::MessageSendResponse
30
38
 
31
39
  def initialize: (client: Sentdm::Client) -> void
32
40
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sentdm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.42.0
4
+ version: 0.43.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sent
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-10-30 00:00:00.000000000 Z
11
+ date: 2026-11-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cgi
@@ -133,6 +133,7 @@ files:
133
133
  - lib/sentdm/models/me_retrieve_response.rb
134
134
  - lib/sentdm/models/message_event.rb
135
135
  - lib/sentdm/models/message_event_payload.rb
136
+ - lib/sentdm/models/message_resend_params.rb
136
137
  - lib/sentdm/models/message_retrieve_activities_params.rb
137
138
  - lib/sentdm/models/message_retrieve_activities_response.rb
138
139
  - lib/sentdm/models/message_retrieve_status_params.rb
@@ -361,6 +362,7 @@ files:
361
362
  - rbi/sentdm/models/me_retrieve_response.rbi
362
363
  - rbi/sentdm/models/message_event.rbi
363
364
  - rbi/sentdm/models/message_event_payload.rbi
365
+ - rbi/sentdm/models/message_resend_params.rbi
364
366
  - rbi/sentdm/models/message_retrieve_activities_params.rbi
365
367
  - rbi/sentdm/models/message_retrieve_activities_response.rbi
366
368
  - rbi/sentdm/models/message_retrieve_status_params.rbi
@@ -588,6 +590,7 @@ files:
588
590
  - sig/sentdm/models/me_retrieve_response.rbs
589
591
  - sig/sentdm/models/message_event.rbs
590
592
  - sig/sentdm/models/message_event_payload.rbs
593
+ - sig/sentdm/models/message_resend_params.rbs
591
594
  - sig/sentdm/models/message_retrieve_activities_params.rbs
592
595
  - sig/sentdm/models/message_retrieve_activities_response.rbs
593
596
  - sig/sentdm/models/message_retrieve_status_params.rbs