rcs-js 2.0.0-rc.6 → 2.0.0-rc.8

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.
Files changed (164) hide show
  1. package/dist/cjs/Client.d.ts +0 -3
  2. package/dist/cjs/Client.js +6 -11
  3. package/dist/cjs/api/resources/brands/client/requests/UpsertBrandParams.d.ts +1 -1
  4. package/dist/cjs/api/resources/index.d.ts +0 -1
  5. package/dist/cjs/api/resources/index.js +1 -2
  6. package/dist/cjs/api/resources/messages/client/Client.d.ts +3 -3
  7. package/dist/cjs/api/resources/messages/client/Client.js +3 -3
  8. package/dist/cjs/api/resources/messages/resources/index.d.ts +6 -3
  9. package/dist/cjs/api/resources/messages/resources/index.js +7 -4
  10. package/dist/cjs/api/resources/messages/resources/mms/client/Client.d.ts +26 -0
  11. package/dist/cjs/api/resources/messages/resources/mms/client/Client.js +83 -0
  12. package/dist/cjs/api/resources/messages/resources/mms/client/index.d.ts +1 -0
  13. package/dist/cjs/api/resources/messages/resources/mms/client/index.js +15 -0
  14. package/dist/cjs/api/resources/messages/resources/{send → mms}/client/requests/index.d.ts +0 -1
  15. package/dist/cjs/api/resources/messages/resources/mms/index.d.ts +1 -0
  16. package/dist/cjs/api/resources/messages/resources/mms/index.js +1 -0
  17. package/dist/cjs/api/resources/messages/resources/{send/types/SendRcsResponse.d.ts → mms/types/MmsSendResponse.d.ts} +1 -1
  18. package/dist/cjs/api/resources/messages/resources/mms/types/index.d.ts +1 -0
  19. package/dist/cjs/api/resources/{message/resources/sms → messages/resources/mms/types}/index.js +1 -1
  20. package/dist/cjs/api/resources/messages/resources/rcs/client/Client.d.ts +28 -0
  21. package/dist/cjs/api/resources/messages/resources/rcs/client/Client.js +85 -0
  22. package/dist/cjs/api/resources/messages/resources/rcs/index.d.ts +1 -0
  23. package/dist/cjs/api/resources/messages/resources/rcs/index.js +1 -0
  24. package/dist/cjs/api/resources/messages/resources/{send/types/SendSmsResponse.d.ts → rcs/types/RcsSendResponse.d.ts} +1 -1
  25. package/dist/cjs/api/resources/messages/resources/rcs/types/index.d.ts +1 -0
  26. package/dist/cjs/api/resources/{message → messages/resources/rcs/types}/index.js +1 -2
  27. package/dist/cjs/api/resources/{message → messages}/resources/sms/client/Client.d.ts +22 -1
  28. package/dist/cjs/api/resources/messages/resources/{send → sms}/client/Client.js +19 -117
  29. package/dist/cjs/api/resources/messages/resources/{send → sms}/client/requests/Sms.d.ts +2 -2
  30. package/dist/cjs/api/resources/messages/resources/sms/client/requests/index.d.ts +1 -0
  31. package/dist/cjs/api/resources/messages/resources/{send/types/SendMmsResponse.d.ts → sms/types/SmsSendResponse.d.ts} +1 -1
  32. package/dist/cjs/api/resources/messages/resources/sms/types/index.d.ts +1 -0
  33. package/dist/cjs/api/resources/messages/resources/sms/types/index.js +17 -0
  34. package/dist/cjs/api/resources/phoneNumbers/client/requests/SearchPhoneNumberParams.d.ts +2 -2
  35. package/dist/cjs/api/types/Rcs.d.ts +3 -3
  36. package/dist/cjs/api/types/RcsCards.d.ts +2 -2
  37. package/dist/cjs/api/types/RcsCardsContent.d.ts +2 -2
  38. package/dist/cjs/api/types/RcsMediaContent.d.ts +1 -1
  39. package/dist/cjs/api/types/RcsTextContent.d.ts +1 -1
  40. package/dist/cjs/api/types/{RcsButtonContent.d.ts → RichButton.d.ts} +2 -2
  41. package/dist/cjs/api/types/{RcsCard.d.ts → RichCardsMessage.d.ts} +1 -1
  42. package/dist/cjs/api/types/{RcsMedia.d.ts → RichMediaMessage.d.ts} +2 -2
  43. package/dist/cjs/api/types/{RcsText.d.ts → RichTextMessage.d.ts} +1 -1
  44. package/dist/{esm/api/types/NullableContact.d.mts → cjs/api/types/UpsertContact.d.ts} +1 -1
  45. package/dist/cjs/api/types/index.d.ts +5 -5
  46. package/dist/cjs/api/types/index.js +5 -5
  47. package/dist/cjs/index.d.ts +4 -4
  48. package/dist/cjs/index.js +8 -8
  49. package/dist/cjs/version.d.ts +1 -1
  50. package/dist/cjs/version.js +1 -1
  51. package/dist/esm/Client.d.mts +0 -3
  52. package/dist/esm/Client.mjs +2 -7
  53. package/dist/esm/api/resources/brands/client/requests/UpsertBrandParams.d.mts +1 -1
  54. package/dist/esm/api/resources/index.d.mts +0 -1
  55. package/dist/esm/api/resources/index.mjs +0 -1
  56. package/dist/esm/api/resources/messages/client/Client.d.mts +3 -3
  57. package/dist/esm/api/resources/messages/client/Client.mjs +3 -3
  58. package/dist/esm/api/resources/messages/resources/index.d.mts +6 -3
  59. package/dist/esm/api/resources/messages/resources/index.mjs +6 -3
  60. package/dist/esm/api/resources/messages/resources/mms/client/Client.d.mts +26 -0
  61. package/dist/esm/api/resources/messages/resources/mms/client/Client.mjs +83 -0
  62. package/dist/esm/api/resources/messages/resources/mms/client/index.d.mts +1 -0
  63. package/dist/esm/api/resources/messages/resources/mms/client/index.mjs +1 -1
  64. package/dist/esm/api/resources/messages/resources/{send → mms}/client/requests/index.d.mts +0 -1
  65. package/dist/esm/api/resources/messages/resources/mms/index.d.mts +1 -0
  66. package/dist/esm/api/resources/messages/resources/mms/index.mjs +1 -0
  67. package/dist/esm/api/resources/messages/resources/{send/types/SendRcsResponse.d.mts → mms/types/MmsSendResponse.d.mts} +1 -1
  68. package/dist/esm/api/resources/messages/resources/mms/types/index.d.mts +1 -0
  69. package/dist/esm/api/resources/messages/resources/mms/types/index.mjs +1 -0
  70. package/dist/esm/api/resources/messages/resources/rcs/client/Client.d.mts +28 -0
  71. package/dist/esm/api/resources/messages/resources/rcs/client/Client.mjs +85 -0
  72. package/dist/esm/api/resources/messages/resources/rcs/index.d.mts +1 -0
  73. package/dist/esm/api/resources/messages/resources/rcs/index.mjs +1 -0
  74. package/dist/esm/api/resources/messages/resources/{send/types/SendSmsResponse.d.mts → rcs/types/RcsSendResponse.d.mts} +1 -1
  75. package/dist/esm/api/resources/messages/resources/rcs/types/index.d.mts +1 -0
  76. package/dist/esm/api/resources/messages/resources/rcs/types/index.mjs +1 -0
  77. package/dist/esm/api/resources/{message → messages}/resources/sms/client/Client.d.mts +22 -1
  78. package/dist/esm/api/resources/messages/resources/{send → sms}/client/Client.mjs +17 -115
  79. package/dist/esm/api/resources/messages/resources/{send → sms}/client/requests/Sms.d.mts +2 -2
  80. package/dist/esm/api/resources/messages/resources/sms/client/requests/index.d.mts +1 -0
  81. package/dist/esm/api/resources/messages/resources/{send/types/SendMmsResponse.d.mts → sms/types/SmsSendResponse.d.mts} +1 -1
  82. package/dist/esm/api/resources/messages/resources/sms/types/index.d.mts +1 -0
  83. package/dist/esm/api/resources/messages/resources/sms/types/index.mjs +1 -0
  84. package/dist/esm/api/resources/phoneNumbers/client/requests/SearchPhoneNumberParams.d.mts +2 -2
  85. package/dist/esm/api/types/Rcs.d.mts +3 -3
  86. package/dist/esm/api/types/RcsCards.d.mts +2 -2
  87. package/dist/esm/api/types/RcsCardsContent.d.mts +2 -2
  88. package/dist/esm/api/types/RcsMediaContent.d.mts +1 -1
  89. package/dist/esm/api/types/RcsTextContent.d.mts +1 -1
  90. package/dist/esm/api/types/{RcsButtonContent.d.mts → RichButton.d.mts} +2 -2
  91. package/dist/esm/api/types/{RcsCard.d.mts → RichCardsMessage.d.mts} +1 -1
  92. package/dist/esm/api/types/{RcsMedia.d.mts → RichMediaMessage.d.mts} +2 -2
  93. package/dist/esm/api/types/{RcsText.d.mts → RichTextMessage.d.mts} +1 -1
  94. package/dist/{cjs/api/types/NullableContact.d.ts → esm/api/types/UpsertContact.d.mts} +1 -1
  95. package/dist/esm/api/types/index.d.mts +5 -5
  96. package/dist/esm/api/types/index.mjs +5 -5
  97. package/dist/esm/index.d.mts +4 -4
  98. package/dist/esm/index.mjs +4 -4
  99. package/dist/esm/version.d.mts +1 -1
  100. package/dist/esm/version.mjs +1 -1
  101. package/package.json +1 -1
  102. package/reference.md +46 -48
  103. package/dist/cjs/api/resources/message/client/Client.d.ts +0 -22
  104. package/dist/cjs/api/resources/message/client/Client.js +0 -17
  105. package/dist/cjs/api/resources/message/client/index.d.ts +0 -1
  106. package/dist/cjs/api/resources/message/index.d.ts +0 -2
  107. package/dist/cjs/api/resources/message/resources/index.d.ts +0 -1
  108. package/dist/cjs/api/resources/message/resources/index.js +0 -37
  109. package/dist/cjs/api/resources/message/resources/sms/client/Client.js +0 -135
  110. package/dist/cjs/api/resources/message/resources/sms/client/index.d.ts +0 -1
  111. package/dist/cjs/api/resources/message/resources/sms/index.d.ts +0 -1
  112. package/dist/cjs/api/resources/messages/resources/send/client/Client.d.ts +0 -110
  113. package/dist/cjs/api/resources/messages/resources/send/client/requests/index.js +0 -2
  114. package/dist/cjs/api/resources/messages/resources/send/types/index.d.ts +0 -3
  115. package/dist/cjs/api/resources/messages/resources/send/types/index.js +0 -19
  116. package/dist/esm/api/resources/message/client/Client.d.mts +0 -22
  117. package/dist/esm/api/resources/message/client/Client.mjs +0 -13
  118. package/dist/esm/api/resources/message/client/index.d.mts +0 -1
  119. package/dist/esm/api/resources/message/index.d.mts +0 -2
  120. package/dist/esm/api/resources/message/index.mjs +0 -2
  121. package/dist/esm/api/resources/message/resources/index.d.mts +0 -1
  122. package/dist/esm/api/resources/message/resources/index.mjs +0 -1
  123. package/dist/esm/api/resources/message/resources/sms/client/Client.mjs +0 -98
  124. package/dist/esm/api/resources/message/resources/sms/client/index.d.mts +0 -1
  125. package/dist/esm/api/resources/message/resources/sms/index.d.mts +0 -1
  126. package/dist/esm/api/resources/message/resources/sms/index.mjs +0 -1
  127. package/dist/esm/api/resources/messages/resources/send/client/Client.d.mts +0 -110
  128. package/dist/esm/api/resources/messages/resources/send/client/requests/index.mjs +0 -1
  129. package/dist/esm/api/resources/messages/resources/send/types/index.d.mts +0 -3
  130. package/dist/esm/api/resources/messages/resources/send/types/index.mjs +0 -3
  131. /package/dist/cjs/api/resources/messages/resources/{send → mms}/client/requests/Mms.d.ts +0 -0
  132. /package/dist/cjs/api/resources/messages/resources/{send → mms}/client/requests/Mms.js +0 -0
  133. /package/dist/cjs/api/resources/{message/client → messages/resources/mms/client/requests}/index.js +0 -0
  134. /package/dist/cjs/api/resources/messages/resources/{send/client/requests/Sms.js → mms/types/MmsSendResponse.js} +0 -0
  135. /package/dist/cjs/api/resources/messages/resources/{send/types/SendMmsResponse.js → rcs/types/RcsSendResponse.js} +0 -0
  136. /package/dist/cjs/api/resources/messages/resources/{send → sms}/client/index.d.ts +0 -0
  137. /package/dist/cjs/api/resources/messages/resources/{send → sms}/client/index.js +0 -0
  138. /package/dist/cjs/api/resources/messages/resources/{send/types/SendRcsResponse.js → sms/client/requests/Sms.js} +0 -0
  139. /package/dist/cjs/api/resources/{message/resources/sms/client → messages/resources/sms/client/requests}/index.js +0 -0
  140. /package/dist/cjs/api/resources/messages/resources/{send → sms}/index.d.ts +0 -0
  141. /package/dist/cjs/api/resources/messages/resources/{send → sms}/index.js +0 -0
  142. /package/dist/cjs/api/resources/messages/resources/{send/types/SendSmsResponse.js → sms/types/SmsSendResponse.js} +0 -0
  143. /package/dist/cjs/api/types/{NullableContact.js → RichButton.js} +0 -0
  144. /package/dist/cjs/api/types/{RcsButtonContent.js → RichCardsMessage.js} +0 -0
  145. /package/dist/cjs/api/types/{RcsCard.js → RichMediaMessage.js} +0 -0
  146. /package/dist/cjs/api/types/{RcsMedia.js → RichTextMessage.js} +0 -0
  147. /package/dist/cjs/api/types/{RcsText.js → UpsertContact.js} +0 -0
  148. /package/dist/esm/api/resources/messages/resources/{send → mms}/client/requests/Mms.d.mts +0 -0
  149. /package/dist/esm/api/resources/messages/resources/{send → mms}/client/requests/Mms.mjs +0 -0
  150. /package/dist/esm/api/resources/{message/client → messages/resources/mms/client/requests}/index.mjs +0 -0
  151. /package/dist/esm/api/resources/messages/resources/{send/client/requests/Sms.mjs → mms/types/MmsSendResponse.mjs} +0 -0
  152. /package/dist/esm/api/resources/messages/resources/{send/types/SendMmsResponse.mjs → rcs/types/RcsSendResponse.mjs} +0 -0
  153. /package/dist/esm/api/resources/messages/resources/{send → sms}/client/index.d.mts +0 -0
  154. /package/dist/esm/api/resources/messages/resources/{send → sms}/client/index.mjs +0 -0
  155. /package/dist/esm/api/resources/messages/resources/{send/types/SendRcsResponse.mjs → sms/client/requests/Sms.mjs} +0 -0
  156. /package/dist/esm/api/resources/{message/resources/sms/client → messages/resources/sms/client/requests}/index.mjs +0 -0
  157. /package/dist/esm/api/resources/messages/resources/{send → sms}/index.d.mts +0 -0
  158. /package/dist/esm/api/resources/messages/resources/{send → sms}/index.mjs +0 -0
  159. /package/dist/esm/api/resources/messages/resources/{send/types/SendSmsResponse.mjs → sms/types/SmsSendResponse.mjs} +0 -0
  160. /package/dist/esm/api/types/{NullableContact.mjs → RichButton.mjs} +0 -0
  161. /package/dist/esm/api/types/{RcsButtonContent.mjs → RichCardsMessage.mjs} +0 -0
  162. /package/dist/esm/api/types/{RcsCard.mjs → RichMediaMessage.mjs} +0 -0
  163. /package/dist/esm/api/types/{RcsMedia.mjs → RichTextMessage.mjs} +0 -0
  164. /package/dist/esm/api/types/{RcsText.mjs → UpsertContact.mjs} +0 -0
@@ -45,13 +45,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
45
45
  });
46
46
  };
47
47
  Object.defineProperty(exports, "__esModule", { value: true });
48
- exports.Send = void 0;
48
+ exports.Sms = void 0;
49
49
  const environments = __importStar(require("../../../../../../environments.js"));
50
50
  const core = __importStar(require("../../../../../../core/index.js"));
51
51
  const Pinnacle = __importStar(require("../../../../../index.js"));
52
52
  const headers_js_1 = require("../../../../../../core/headers.js");
53
53
  const errors = __importStar(require("../../../../../../errors/index.js"));
54
- class Send {
54
+ class Sms {
55
55
  constructor(_options) {
56
56
  this._options = _options;
57
57
  }
@@ -59,7 +59,7 @@ class Send {
59
59
  * Send a SMS message immediately or schedule it for future delivery.
60
60
  *
61
61
  * @param {Pinnacle.messages.Sms} request
62
- * @param {Send.RequestOptions} requestOptions - Request-specific configuration.
62
+ * @param {Sms.RequestOptions} requestOptions - Request-specific configuration.
63
63
  *
64
64
  * @throws {@link Pinnacle.BadRequestError}
65
65
  * @throws {@link Pinnacle.UnauthorizedError}
@@ -68,16 +68,16 @@ class Send {
68
68
  * @throws {@link Pinnacle.InternalServerError}
69
69
  *
70
70
  * @example
71
- * await client.messages.send.sms({
71
+ * await client.messages.sms.send({
72
72
  * from: "+14155164736",
73
- * text: "Hey! \uD83D\uDE02",
73
+ * text: "Hey!",
74
74
  * to: "+14154746461"
75
75
  * })
76
76
  */
77
- sms(request, requestOptions) {
78
- return core.HttpResponsePromise.fromPromise(this.__sms(request, requestOptions));
77
+ send(request, requestOptions) {
78
+ return core.HttpResponsePromise.fromPromise(this.__send(request, requestOptions));
79
79
  }
80
- __sms(request, requestOptions) {
80
+ __send(request, requestOptions) {
81
81
  return __awaiter(this, void 0, void 0, function* () {
82
82
  var _a, _b, _c;
83
83
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
@@ -134,38 +134,29 @@ class Send {
134
134
  });
135
135
  }
136
136
  /**
137
- * Send a MMS immediately or schedule it for future delivery.
137
+ * Validate SMS message content without sending it.
138
138
  *
139
- * @param {Pinnacle.messages.Mms} request
140
- * @param {Send.RequestOptions} requestOptions - Request-specific configuration.
139
+ * @param {Pinnacle.SmsContent} request
140
+ * @param {Sms.RequestOptions} requestOptions - Request-specific configuration.
141
141
  *
142
142
  * @throws {@link Pinnacle.BadRequestError}
143
143
  * @throws {@link Pinnacle.UnauthorizedError}
144
- * @throws {@link Pinnacle.PaymentRequiredError}
145
- * @throws {@link Pinnacle.NotFoundError}
146
144
  * @throws {@link Pinnacle.InternalServerError}
147
145
  *
148
146
  * @example
149
- * await client.messages.send.mms({
150
- * from: "+14155164736",
151
- * mediaUrls: ["https://fastly.picsum.photos/id/941/300/300.jpg?hmac=mDxM9PWSqRDjecwSCEpzU4bj35gqnG7yA25OL29uNv0"],
152
- * options: {
153
- * multiple_messages: true,
154
- * validate: true
155
- * },
156
- * text: "Check out this image!",
157
- * to: "+14154746461"
147
+ * await client.messages.sms.validate({
148
+ * text: "Hello from Pinnacle"
158
149
  * })
159
150
  */
160
- mms(request, requestOptions) {
161
- return core.HttpResponsePromise.fromPromise(this.__mms(request, requestOptions));
151
+ validate(request, requestOptions) {
152
+ return core.HttpResponsePromise.fromPromise(this.__validate(request, requestOptions));
162
153
  }
163
- __mms(request, requestOptions) {
154
+ __validate(request, requestOptions) {
164
155
  return __awaiter(this, void 0, void 0, function* () {
165
156
  var _a, _b, _c;
166
157
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
167
158
  const _response = yield core.fetcher({
168
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PinnacleEnvironment.Default, "messages/send/mms"),
159
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PinnacleEnvironment.Default, "messages/validate/sms"),
169
160
  method: "POST",
170
161
  headers: _headers,
171
162
  contentType: "application/json",
@@ -185,95 +176,6 @@ class Send {
185
176
  throw new Pinnacle.BadRequestError(_response.error.body, _response.rawResponse);
186
177
  case 401:
187
178
  throw new Pinnacle.UnauthorizedError(_response.error.body, _response.rawResponse);
188
- case 402:
189
- throw new Pinnacle.PaymentRequiredError(_response.error.body, _response.rawResponse);
190
- case 404:
191
- throw new Pinnacle.NotFoundError(_response.error.body, _response.rawResponse);
192
- case 500:
193
- throw new Pinnacle.InternalServerError(_response.error.body, _response.rawResponse);
194
- default:
195
- throw new errors.PinnacleError({
196
- statusCode: _response.error.statusCode,
197
- body: _response.error.body,
198
- rawResponse: _response.rawResponse,
199
- });
200
- }
201
- }
202
- switch (_response.error.reason) {
203
- case "non-json":
204
- throw new errors.PinnacleError({
205
- statusCode: _response.error.statusCode,
206
- body: _response.error.rawBody,
207
- rawResponse: _response.rawResponse,
208
- });
209
- case "timeout":
210
- throw new errors.PinnacleTimeoutError("Timeout exceeded when calling POST /messages/send/mms.");
211
- case "unknown":
212
- throw new errors.PinnacleError({
213
- message: _response.error.errorMessage,
214
- rawResponse: _response.rawResponse,
215
- });
216
- }
217
- });
218
- }
219
- /**
220
- * Send a RCS message immediately or schedule it for future delivery. <br>
221
- *
222
- * Requires an active RCS agent and recipient devices that support RCS Business Messaging.
223
- *
224
- * @param {Pinnacle.Rcs} request
225
- * @param {Send.RequestOptions} requestOptions - Request-specific configuration.
226
- *
227
- * @throws {@link Pinnacle.BadRequestError}
228
- * @throws {@link Pinnacle.UnauthorizedError}
229
- * @throws {@link Pinnacle.PaymentRequiredError}
230
- * @throws {@link Pinnacle.NotFoundError}
231
- * @throws {@link Pinnacle.InternalServerError}
232
- *
233
- * @example
234
- * await client.messages.send.rcs({
235
- * quickReplies: [{
236
- * type: "openUrl",
237
- * payload: "payload",
238
- * title: "title"
239
- * }],
240
- * text: "text",
241
- * from: "from",
242
- * to: "to"
243
- * })
244
- */
245
- rcs(request, requestOptions) {
246
- return core.HttpResponsePromise.fromPromise(this.__rcs(request, requestOptions));
247
- }
248
- __rcs(request, requestOptions) {
249
- return __awaiter(this, void 0, void 0, function* () {
250
- var _a, _b, _c;
251
- let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
252
- const _response = yield core.fetcher({
253
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PinnacleEnvironment.Default, "messages/send/rcs"),
254
- method: "POST",
255
- headers: _headers,
256
- contentType: "application/json",
257
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
258
- requestType: "json",
259
- body: request,
260
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
261
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
262
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
263
- });
264
- if (_response.ok) {
265
- return { data: _response.body, rawResponse: _response.rawResponse };
266
- }
267
- if (_response.error.reason === "status-code") {
268
- switch (_response.error.statusCode) {
269
- case 400:
270
- throw new Pinnacle.BadRequestError(_response.error.body, _response.rawResponse);
271
- case 401:
272
- throw new Pinnacle.UnauthorizedError(_response.error.body, _response.rawResponse);
273
- case 402:
274
- throw new Pinnacle.PaymentRequiredError(_response.error.body, _response.rawResponse);
275
- case 404:
276
- throw new Pinnacle.NotFoundError(_response.error.body, _response.rawResponse);
277
179
  case 500:
278
180
  throw new Pinnacle.InternalServerError(_response.error.body, _response.rawResponse);
279
181
  default:
@@ -292,7 +194,7 @@ class Send {
292
194
  rawResponse: _response.rawResponse,
293
195
  });
294
196
  case "timeout":
295
- throw new errors.PinnacleTimeoutError("Timeout exceeded when calling POST /messages/send/rcs.");
197
+ throw new errors.PinnacleTimeoutError("Timeout exceeded when calling POST /messages/validate/sms.");
296
198
  case "unknown":
297
199
  throw new errors.PinnacleError({
298
200
  message: _response.error.errorMessage,
@@ -308,4 +210,4 @@ class Send {
308
210
  });
309
211
  }
310
212
  }
311
- exports.Send = Send;
213
+ exports.Sms = Sms;
@@ -6,14 +6,14 @@ import * as Pinnacle from "../../../../../../index.js";
6
6
  * @example
7
7
  * {
8
8
  * from: "+14155164736",
9
- * text: "Hey! \uD83D\uDE02",
9
+ * text: "Hey!",
10
10
  * to: "+14154746461"
11
11
  * }
12
12
  *
13
13
  * @example
14
14
  * {
15
15
  * from: "+14155164736",
16
- * text: "Hey! \uD83D\uDE02",
16
+ * text: "Hey!",
17
17
  * to: "+14154746461"
18
18
  * }
19
19
  */
@@ -0,0 +1 @@
1
+ export { type Sms } from "./Sms.js";
@@ -2,4 +2,4 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Pinnacle from "../../../../../index.js";
5
- export type SendMmsResponse = Pinnacle.SentMmsDetails | Pinnacle.ScheduledMessaage;
5
+ export type SmsSendResponse = Pinnacle.SentSmsDetails | Pinnacle.ScheduledMessaage;
@@ -0,0 +1 @@
1
+ export * from "./SmsSendResponse.js";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./SmsSendResponse.js"), exports);
@@ -29,7 +29,7 @@ export interface SearchPhoneNumberParams {
29
29
  */
30
30
  location?: SearchPhoneNumberParams.Location;
31
31
  /** Filter your search by digit pattern. */
32
- number?: SearchPhoneNumberParams.PhoneNumberDigitFilters;
32
+ number?: SearchPhoneNumberParams.Number;
33
33
  /** Extra search settings to control how many results you get. */
34
34
  options?: SearchPhoneNumberParams.Options;
35
35
  /** Types of phone numbers to return in your search. */
@@ -58,7 +58,7 @@ export declare namespace SearchPhoneNumberParams {
58
58
  /**
59
59
  * Filter your search by digit pattern.
60
60
  */
61
- interface PhoneNumberDigitFilters {
61
+ interface Number {
62
62
  /** Your search will return only numbers that contain this digit sequence anywhere within them. */
63
63
  contains?: string;
64
64
  /** Your search will return only numbers that end with these digits. */
@@ -5,10 +5,10 @@ import * as Pinnacle from "../index.js";
5
5
  export type Rcs =
6
6
  /**
7
7
  * Send a text RCS message with optional quick reply buttons. */
8
- Pinnacle.RcsText
8
+ Pinnacle.RichTextMessage
9
9
  /**
10
10
  * Send a media RCS message with optional quick reply buttons. */
11
- | Pinnacle.RcsMedia
11
+ | Pinnacle.RichMediaMessage
12
12
  /**
13
13
  * Send a cards RCS message with optional quick reply buttons. */
14
- | Pinnacle.RcsCard;
14
+ | Pinnacle.RichCardsMessage;
@@ -11,7 +11,7 @@ export interface RcsCards {
11
11
  /** Collection of cards attached to the message. */
12
12
  cards: RcsCards.Cards.Item[];
13
13
  /** List of interactive quick reply buttons in the message. */
14
- quickReplies: Pinnacle.RcsButtonContent[];
14
+ quickReplies: Pinnacle.RichButton[];
15
15
  }
16
16
  export declare namespace RcsCards {
17
17
  type Cards = Cards.Item[];
@@ -21,7 +21,7 @@ export declare namespace RcsCards {
21
21
  */
22
22
  interface Item {
23
23
  /** Action buttons attached to the card. */
24
- buttons: Pinnacle.RcsButtonContent[];
24
+ buttons: Pinnacle.RichButton[];
25
25
  /** Media file URLs to send. */
26
26
  media?: string;
27
27
  /** Secondary text displayed below the title for additional context. */
@@ -11,7 +11,7 @@ export interface RcsCardsContent {
11
11
  /** Collection of cards attached to the message. */
12
12
  cards: RcsCardsContent.Cards.Item[];
13
13
  /** List of interactive quick reply buttons in the message. */
14
- quickReplies: Pinnacle.RcsButtonContent[];
14
+ quickReplies: Pinnacle.RichButton[];
15
15
  }
16
16
  export declare namespace RcsCardsContent {
17
17
  type Cards = Cards.Item[];
@@ -21,7 +21,7 @@ export declare namespace RcsCardsContent {
21
21
  */
22
22
  interface Item {
23
23
  /** Action buttons attached to the card. */
24
- buttons: Pinnacle.RcsButtonContent[];
24
+ buttons: Pinnacle.RichButton[];
25
25
  media?: Pinnacle.RcsMediaDetailsContent;
26
26
  /** Secondary text displayed below the title for additional context. */
27
27
  subtitle?: string;
@@ -10,5 +10,5 @@ import * as Pinnacle from "../index.js";
10
10
  export interface RcsMediaContent {
11
11
  media: Pinnacle.RcsMediaDetailsContent;
12
12
  /** List of interactive quick reply buttons in the message. */
13
- quickReplies: Pinnacle.RcsButtonContent[];
13
+ quickReplies: Pinnacle.RichButton[];
14
14
  }
@@ -7,7 +7,7 @@ import * as Pinnacle from "../index.js";
7
7
  */
8
8
  export interface RcsTextContent {
9
9
  /** List of interactive quick reply buttons in the message. */
10
- quickReplies: Pinnacle.RcsButtonContent[];
10
+ quickReplies: Pinnacle.RichButton[];
11
11
  /** Text content of the RCS message. */
12
12
  text: string;
13
13
  }
@@ -2,8 +2,8 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Pinnacle from "../index.js";
5
- export type RcsButtonContent = Pinnacle.RcsButtonContent.OpenUrl | Pinnacle.RcsButtonContent.Call | Pinnacle.RcsButtonContent.Trigger | Pinnacle.RcsButtonContent.RequestUserLocation | Pinnacle.RcsButtonContent.ScheduleEvent | Pinnacle.RcsButtonContent.SendLocation;
6
- export declare namespace RcsButtonContent {
5
+ export type RichButton = Pinnacle.RichButton.OpenUrl | Pinnacle.RichButton.Call | Pinnacle.RichButton.Trigger | Pinnacle.RichButton.RequestUserLocation | Pinnacle.RichButton.ScheduleEvent | Pinnacle.RichButton.SendLocation;
6
+ export declare namespace RichButton {
7
7
  interface OpenUrl extends Pinnacle.RcsButtonOpenUrl {
8
8
  type: "openUrl";
9
9
  }
@@ -2,5 +2,5 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Pinnacle from "../index.js";
5
- export interface RcsCard extends Pinnacle.RcsBase, Pinnacle.RcsCards {
5
+ export interface RichCardsMessage extends Pinnacle.RcsBase, Pinnacle.RcsCards {
6
6
  }
@@ -2,7 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Pinnacle from "../index.js";
5
- export interface RcsMedia extends Pinnacle.RcsBase {
5
+ export interface RichMediaMessage extends Pinnacle.RcsBase {
6
6
  /**
7
7
  * Media file URLs to send. <br>
8
8
  *
@@ -10,5 +10,5 @@ export interface RcsMedia extends Pinnacle.RcsBase {
10
10
  */
11
11
  media: string;
12
12
  /** List of interactive quick reply buttons in the message. */
13
- quickReplies: Pinnacle.RcsButtonContent[];
13
+ quickReplies: Pinnacle.RichButton[];
14
14
  }
@@ -2,5 +2,5 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Pinnacle from "../index.js";
5
- export interface RcsText extends Pinnacle.RcsBase, Pinnacle.RcsTextContent {
5
+ export interface RichTextMessage extends Pinnacle.RcsBase, Pinnacle.RcsTextContent {
6
6
  }
@@ -4,7 +4,7 @@
4
4
  /**
5
5
  * Contact information for the brand.
6
6
  */
7
- export interface NullableContact {
7
+ export interface UpsertContact {
8
8
  /** Email address of the contact person. */
9
9
  email?: string | null;
10
10
  /** Full name of the contact person. */
@@ -5,7 +5,7 @@ export * from "./CompanyTypeEnum.js";
5
5
  export * from "./OptionalBrandInfo.js";
6
6
  export * from "./ZodError.js";
7
7
  export * from "./Error_.js";
8
- export * from "./NullableContact.js";
8
+ export * from "./UpsertContact.js";
9
9
  export * from "./BrandStatusEnum.js";
10
10
  export * from "./ExtendedBrand.js";
11
11
  export * from "./VettingFeedback.js";
@@ -53,7 +53,7 @@ export * from "./RcsButtonTrigger.js";
53
53
  export * from "./RcsButtonRequestUserLocation.js";
54
54
  export * from "./RcsButtonScheduleEvent.js";
55
55
  export * from "./RcsButtonSendLocation.js";
56
- export * from "./RcsButtonContent.js";
56
+ export * from "./RichButton.js";
57
57
  export * from "./RcsTextContent.js";
58
58
  export * from "./RcsMediaDetailsContent.js";
59
59
  export * from "./RcsMediaContent.js";
@@ -74,10 +74,10 @@ export * from "./SentSmsDetails.js";
74
74
  export * from "./ScheduledMessaage.js";
75
75
  export * from "./SentMmsDetails.js";
76
76
  export * from "./RcsBase.js";
77
- export * from "./RcsText.js";
78
- export * from "./RcsMedia.js";
77
+ export * from "./RichTextMessage.js";
78
+ export * from "./RichMediaMessage.js";
79
79
  export * from "./RcsCards.js";
80
- export * from "./RcsCard.js";
80
+ export * from "./RichCardsMessage.js";
81
81
  export * from "./Rcs.js";
82
82
  export * from "./SentRcsDetails.js";
83
83
  export * from "./SmsValidationResult.js";
@@ -21,7 +21,7 @@ __exportStar(require("./CompanyTypeEnum.js"), exports);
21
21
  __exportStar(require("./OptionalBrandInfo.js"), exports);
22
22
  __exportStar(require("./ZodError.js"), exports);
23
23
  __exportStar(require("./Error_.js"), exports);
24
- __exportStar(require("./NullableContact.js"), exports);
24
+ __exportStar(require("./UpsertContact.js"), exports);
25
25
  __exportStar(require("./BrandStatusEnum.js"), exports);
26
26
  __exportStar(require("./ExtendedBrand.js"), exports);
27
27
  __exportStar(require("./VettingFeedback.js"), exports);
@@ -69,7 +69,7 @@ __exportStar(require("./RcsButtonTrigger.js"), exports);
69
69
  __exportStar(require("./RcsButtonRequestUserLocation.js"), exports);
70
70
  __exportStar(require("./RcsButtonScheduleEvent.js"), exports);
71
71
  __exportStar(require("./RcsButtonSendLocation.js"), exports);
72
- __exportStar(require("./RcsButtonContent.js"), exports);
72
+ __exportStar(require("./RichButton.js"), exports);
73
73
  __exportStar(require("./RcsTextContent.js"), exports);
74
74
  __exportStar(require("./RcsMediaDetailsContent.js"), exports);
75
75
  __exportStar(require("./RcsMediaContent.js"), exports);
@@ -90,10 +90,10 @@ __exportStar(require("./SentSmsDetails.js"), exports);
90
90
  __exportStar(require("./ScheduledMessaage.js"), exports);
91
91
  __exportStar(require("./SentMmsDetails.js"), exports);
92
92
  __exportStar(require("./RcsBase.js"), exports);
93
- __exportStar(require("./RcsText.js"), exports);
94
- __exportStar(require("./RcsMedia.js"), exports);
93
+ __exportStar(require("./RichTextMessage.js"), exports);
94
+ __exportStar(require("./RichMediaMessage.js"), exports);
95
95
  __exportStar(require("./RcsCards.js"), exports);
96
- __exportStar(require("./RcsCard.js"), exports);
96
+ __exportStar(require("./RichCardsMessage.js"), exports);
97
97
  __exportStar(require("./Rcs.js"), exports);
98
98
  __exportStar(require("./SentRcsDetails.js"), exports);
99
99
  __exportStar(require("./SmsValidationResult.js"), exports);
@@ -1,4 +1,4 @@
1
- export * as Pinnacle from "./api";
2
- export { PinnacleClient } from "./Client";
3
- export { PinnacleEnvironment } from "./environments";
4
- export { PinnacleError, PinnacleTimeoutError } from "./errors";
1
+ export * as Pinnacle from "./api/index.js";
2
+ export { PinnacleClient } from "./Client.js";
3
+ export { PinnacleEnvironment } from "./environments.js";
4
+ export { PinnacleError, PinnacleTimeoutError } from "./errors/index.js";
package/dist/cjs/index.js CHANGED
@@ -34,11 +34,11 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.PinnacleTimeoutError = exports.PinnacleError = exports.PinnacleEnvironment = exports.PinnacleClient = exports.Pinnacle = void 0;
37
- exports.Pinnacle = __importStar(require("./api"));
38
- var Client_1 = require("./Client");
39
- Object.defineProperty(exports, "PinnacleClient", { enumerable: true, get: function () { return Client_1.PinnacleClient; } });
40
- var environments_1 = require("./environments");
41
- Object.defineProperty(exports, "PinnacleEnvironment", { enumerable: true, get: function () { return environments_1.PinnacleEnvironment; } });
42
- var errors_1 = require("./errors");
43
- Object.defineProperty(exports, "PinnacleError", { enumerable: true, get: function () { return errors_1.PinnacleError; } });
44
- Object.defineProperty(exports, "PinnacleTimeoutError", { enumerable: true, get: function () { return errors_1.PinnacleTimeoutError; } });
37
+ exports.Pinnacle = __importStar(require("./api/index.js"));
38
+ var Client_js_1 = require("./Client.js");
39
+ Object.defineProperty(exports, "PinnacleClient", { enumerable: true, get: function () { return Client_js_1.PinnacleClient; } });
40
+ var environments_js_1 = require("./environments.js");
41
+ Object.defineProperty(exports, "PinnacleEnvironment", { enumerable: true, get: function () { return environments_js_1.PinnacleEnvironment; } });
42
+ var index_js_1 = require("./errors/index.js");
43
+ Object.defineProperty(exports, "PinnacleError", { enumerable: true, get: function () { return index_js_1.PinnacleError; } });
44
+ Object.defineProperty(exports, "PinnacleTimeoutError", { enumerable: true, get: function () { return index_js_1.PinnacleTimeoutError; } });
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "2.0.0-rc.6";
1
+ export declare const SDK_VERSION = "2.0.0-rc.8";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "2.0.0-rc.6";
4
+ exports.SDK_VERSION = "2.0.0-rc.8";
@@ -10,7 +10,6 @@ import { Messages } from "./api/resources/messages/client/Client.mjs";
10
10
  import { PhoneNumbers } from "./api/resources/phoneNumbers/client/Client.mjs";
11
11
  import { Webhooks } from "./api/resources/webhooks/client/Client.mjs";
12
12
  import { Campaigns } from "./api/resources/campaigns/client/Client.mjs";
13
- import { Message } from "./api/resources/message/client/Client.mjs";
14
13
  import { Status } from "./api/resources/status/client/Client.mjs";
15
14
  import { Tools } from "./api/resources/tools/client/Client.mjs";
16
15
  export declare namespace PinnacleClient {
@@ -44,7 +43,6 @@ export declare class PinnacleClient {
44
43
  protected _phoneNumbers: PhoneNumbers | undefined;
45
44
  protected _webhooks: Webhooks | undefined;
46
45
  protected _campaigns: Campaigns | undefined;
47
- protected _message: Message | undefined;
48
46
  protected _status: Status | undefined;
49
47
  protected _tools: Tools | undefined;
50
48
  constructor(_options: PinnacleClient.Options);
@@ -55,7 +53,6 @@ export declare class PinnacleClient {
55
53
  get phoneNumbers(): PhoneNumbers;
56
54
  get webhooks(): Webhooks;
57
55
  get campaigns(): Campaigns;
58
- get message(): Message;
59
56
  get status(): Status;
60
57
  get tools(): Tools;
61
58
  }
@@ -10,7 +10,6 @@ import { Messages } from "./api/resources/messages/client/Client.mjs";
10
10
  import { PhoneNumbers } from "./api/resources/phoneNumbers/client/Client.mjs";
11
11
  import { Webhooks } from "./api/resources/webhooks/client/Client.mjs";
12
12
  import { Campaigns } from "./api/resources/campaigns/client/Client.mjs";
13
- import { Message } from "./api/resources/message/client/Client.mjs";
14
13
  import { Status } from "./api/resources/status/client/Client.mjs";
15
14
  import { Tools } from "./api/resources/tools/client/Client.mjs";
16
15
  export class PinnacleClient {
@@ -18,8 +17,8 @@ export class PinnacleClient {
18
17
  this._options = Object.assign(Object.assign({}, _options), { headers: mergeHeaders({
19
18
  "X-Fern-Language": "JavaScript",
20
19
  "X-Fern-SDK-Name": "rcs-js",
21
- "X-Fern-SDK-Version": "2.0.0-rc.6",
22
- "User-Agent": "rcs-js/2.0.0-rc.6",
20
+ "X-Fern-SDK-Version": "2.0.0-rc.8",
21
+ "User-Agent": "rcs-js/2.0.0-rc.8",
23
22
  "X-Fern-Runtime": core.RUNTIME.type,
24
23
  "X-Fern-Runtime-Version": core.RUNTIME.version,
25
24
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -52,10 +51,6 @@ export class PinnacleClient {
52
51
  var _a;
53
52
  return ((_a = this._campaigns) !== null && _a !== void 0 ? _a : (this._campaigns = new Campaigns(this._options)));
54
53
  }
55
- get message() {
56
- var _a;
57
- return ((_a = this._message) !== null && _a !== void 0 ? _a : (this._message = new Message(this._options)));
58
- }
59
54
  get status() {
60
55
  var _a;
61
56
  return ((_a = this._status) !== null && _a !== void 0 ? _a : (this._status = new Status(this._options)));
@@ -27,7 +27,7 @@ export interface UpsertBrandParams {
27
27
  /** Primary brand address where the company is located. */
28
28
  address?: string | null;
29
29
  /** Contact information for the brand. */
30
- contact?: Pinnacle.NullableContact | null;
30
+ contact?: Pinnacle.UpsertContact | null;
31
31
  /** "Doing Business As" name - the public name the brand operates under. */
32
32
  dba?: string | null;
33
33
  /** Brief description of what the brand does. */
@@ -6,7 +6,6 @@ export * as brands from "./brands/index.mjs";
6
6
  export * as contacts from "./contacts/index.mjs";
7
7
  export * as conversations from "./conversations/index.mjs";
8
8
  export * as webhooks from "./webhooks/index.mjs";
9
- export * as message from "./message/index.mjs";
10
9
  export * as status from "./status/index.mjs";
11
10
  export * as tools from "./tools/index.mjs";
12
11
  export * from "./brands/client/requests/index.mjs";
@@ -6,7 +6,6 @@ export * as brands from "./brands/index.mjs";
6
6
  export * as contacts from "./contacts/index.mjs";
7
7
  export * as conversations from "./conversations/index.mjs";
8
8
  export * as webhooks from "./webhooks/index.mjs";
9
- export * as message from "./message/index.mjs";
10
9
  export * as status from "./status/index.mjs";
11
10
  export * as tools from "./tools/index.mjs";
12
11
  export * from "./brands/client/requests/index.mjs";
@@ -4,7 +4,7 @@
4
4
  import * as environments from "../../../../environments.mjs";
5
5
  import * as core from "../../../../core/index.mjs";
6
6
  import * as Pinnacle from "../../../index.mjs";
7
- import { Send } from "../resources/send/client/Client.mjs";
7
+ import { Sms } from "../resources/sms/client/Client.mjs";
8
8
  import { Mms } from "../resources/mms/client/Client.mjs";
9
9
  import { Rcs } from "../resources/rcs/client/Client.mjs";
10
10
  export declare namespace Messages {
@@ -31,11 +31,11 @@ export declare namespace Messages {
31
31
  }
32
32
  export declare class Messages {
33
33
  protected readonly _options: Messages.Options;
34
- protected _send: Send | undefined;
34
+ protected _sms: Sms | undefined;
35
35
  protected _mms: Mms | undefined;
36
36
  protected _rcs: Rcs | undefined;
37
37
  constructor(_options: Messages.Options);
38
- get send(): Send;
38
+ get sms(): Sms;
39
39
  get mms(): Mms;
40
40
  get rcs(): Rcs;
41
41
  /**
@@ -15,16 +15,16 @@ import * as core from "../../../../core/index.mjs";
15
15
  import * as Pinnacle from "../../../index.mjs";
16
16
  import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.mjs";
17
17
  import * as errors from "../../../../errors/index.mjs";
18
- import { Send } from "../resources/send/client/Client.mjs";
18
+ import { Sms } from "../resources/sms/client/Client.mjs";
19
19
  import { Mms } from "../resources/mms/client/Client.mjs";
20
20
  import { Rcs } from "../resources/rcs/client/Client.mjs";
21
21
  export class Messages {
22
22
  constructor(_options) {
23
23
  this._options = _options;
24
24
  }
25
- get send() {
25
+ get sms() {
26
26
  var _a;
27
- return ((_a = this._send) !== null && _a !== void 0 ? _a : (this._send = new Send(this._options)));
27
+ return ((_a = this._sms) !== null && _a !== void 0 ? _a : (this._sms = new Sms(this._options)));
28
28
  }
29
29
  get mms() {
30
30
  var _a;