@zyphr-dev/node-sdk 0.1.53 → 0.1.55

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.
package/dist/index.js CHANGED
@@ -2377,7 +2377,8 @@ function ConfirmEmailVerificationResponseDataFromJSONTyped(json, ignoreDiscrimin
2377
2377
  }
2378
2378
  return {
2379
2379
  "success": json["success"] == null ? void 0 : json["success"],
2380
- "email": json["email"] == null ? void 0 : json["email"]
2380
+ "email": json["email"] == null ? void 0 : json["email"],
2381
+ "alreadyVerified": json["already_verified"] == null ? void 0 : json["already_verified"]
2381
2382
  };
2382
2383
  }
2383
2384
  function ConfirmEmailVerificationResponseDataToJSON(json) {
@@ -2389,7 +2390,8 @@ function ConfirmEmailVerificationResponseDataToJSONTyped(value, ignoreDiscrimina
2389
2390
  }
2390
2391
  return {
2391
2392
  "success": value["success"],
2392
- "email": value["email"]
2393
+ "email": value["email"],
2394
+ "already_verified": value["alreadyVerified"]
2393
2395
  };
2394
2396
  }
2395
2397
 
@@ -10229,6 +10231,33 @@ function ReplayWebhookEventsRequestToJSONTyped(value, ignoreDiscriminator = fals
10229
10231
  };
10230
10232
  }
10231
10233
 
10234
+ // src/src/models/ResendEmailVerificationRequest.ts
10235
+ function instanceOfResendEmailVerificationRequest(value) {
10236
+ return true;
10237
+ }
10238
+ function ResendEmailVerificationRequestFromJSON(json) {
10239
+ return ResendEmailVerificationRequestFromJSONTyped(json, false);
10240
+ }
10241
+ function ResendEmailVerificationRequestFromJSONTyped(json, ignoreDiscriminator) {
10242
+ if (json == null) {
10243
+ return json;
10244
+ }
10245
+ return {
10246
+ "redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"]
10247
+ };
10248
+ }
10249
+ function ResendEmailVerificationRequestToJSON(json) {
10250
+ return ResendEmailVerificationRequestToJSONTyped(json, false);
10251
+ }
10252
+ function ResendEmailVerificationRequestToJSONTyped(value, ignoreDiscriminator = false) {
10253
+ if (value == null) {
10254
+ return value;
10255
+ }
10256
+ return {
10257
+ "redirect_url": value["redirectUrl"]
10258
+ };
10259
+ }
10260
+
10232
10261
  // src/src/models/ResetPasswordRequest.ts
10233
10262
  function instanceOfResetPasswordRequest(value) {
10234
10263
  if (!("token" in value) || value["token"] === void 0) return false;
@@ -16201,7 +16230,6 @@ function WebhookDeliveryFromJSONTyped(json, ignoreDiscriminator) {
16201
16230
  "firstAttemptedAt": json["first_attempted_at"] == null ? void 0 : new Date(json["first_attempted_at"]),
16202
16231
  "lastAttemptedAt": json["last_attempted_at"] == null ? void 0 : new Date(json["last_attempted_at"]),
16203
16232
  "completedAt": json["completed_at"] == null ? void 0 : new Date(json["completed_at"]),
16204
- "deliveryRegion": json["delivery_region"] == null ? void 0 : json["delivery_region"],
16205
16233
  "createdAt": json["created_at"] == null ? void 0 : new Date(json["created_at"])
16206
16234
  };
16207
16235
  }
@@ -16227,7 +16255,6 @@ function WebhookDeliveryToJSONTyped(value, ignoreDiscriminator = false) {
16227
16255
  "first_attempted_at": value["firstAttemptedAt"] == null ? void 0 : value["firstAttemptedAt"].toISOString(),
16228
16256
  "last_attempted_at": value["lastAttemptedAt"] == null ? void 0 : value["lastAttemptedAt"].toISOString(),
16229
16257
  "completed_at": value["completedAt"] == null ? void 0 : value["completedAt"].toISOString(),
16230
- "delivery_region": value["deliveryRegion"],
16231
16258
  "created_at": value["createdAt"] == null ? void 0 : value["createdAt"].toISOString()
16232
16259
  };
16233
16260
  }
@@ -16265,7 +16292,6 @@ function WebhookDeliveryDetailFromJSONTyped(json, ignoreDiscriminator) {
16265
16292
  "firstAttemptedAt": json["first_attempted_at"] == null ? void 0 : new Date(json["first_attempted_at"]),
16266
16293
  "lastAttemptedAt": json["last_attempted_at"] == null ? void 0 : new Date(json["last_attempted_at"]),
16267
16294
  "completedAt": json["completed_at"] == null ? void 0 : new Date(json["completed_at"]),
16268
- "deliveryRegion": json["delivery_region"] == null ? void 0 : json["delivery_region"],
16269
16295
  "createdAt": json["created_at"] == null ? void 0 : new Date(json["created_at"]),
16270
16296
  "payload": json["payload"] == null ? void 0 : json["payload"],
16271
16297
  "lastResponseBody": json["last_response_body"] == null ? void 0 : json["last_response_body"],
@@ -16295,7 +16321,6 @@ function WebhookDeliveryDetailToJSONTyped(value, ignoreDiscriminator = false) {
16295
16321
  "first_attempted_at": value["firstAttemptedAt"] == null ? void 0 : value["firstAttemptedAt"].toISOString(),
16296
16322
  "last_attempted_at": value["lastAttemptedAt"] == null ? void 0 : value["lastAttemptedAt"].toISOString(),
16297
16323
  "completed_at": value["completedAt"] == null ? void 0 : value["completedAt"].toISOString(),
16298
- "delivery_region": value["deliveryRegion"],
16299
16324
  "created_at": value["createdAt"] == null ? void 0 : value["createdAt"].toISOString(),
16300
16325
  "payload": value["payload"],
16301
16326
  "last_response_body": value["lastResponseBody"],
@@ -16631,95 +16656,6 @@ function WebhookMetricsResponseToJSONTyped(value, ignoreDiscriminator = false) {
16631
16656
  };
16632
16657
  }
16633
16658
 
16634
- // src/src/models/WebhookRegion.ts
16635
- function instanceOfWebhookRegion(value) {
16636
- return true;
16637
- }
16638
- function WebhookRegionFromJSON(json) {
16639
- return WebhookRegionFromJSONTyped(json, false);
16640
- }
16641
- function WebhookRegionFromJSONTyped(json, ignoreDiscriminator) {
16642
- if (json == null) {
16643
- return json;
16644
- }
16645
- return {
16646
- "code": json["code"] == null ? void 0 : json["code"],
16647
- "name": json["name"] == null ? void 0 : json["name"],
16648
- "staticIps": json["static_ips"] == null ? void 0 : json["static_ips"]
16649
- };
16650
- }
16651
- function WebhookRegionToJSON(json) {
16652
- return WebhookRegionToJSONTyped(json, false);
16653
- }
16654
- function WebhookRegionToJSONTyped(value, ignoreDiscriminator = false) {
16655
- if (value == null) {
16656
- return value;
16657
- }
16658
- return {
16659
- "code": value["code"],
16660
- "name": value["name"],
16661
- "static_ips": value["staticIps"]
16662
- };
16663
- }
16664
-
16665
- // src/src/models/WebhookRegionsResponseData.ts
16666
- function instanceOfWebhookRegionsResponseData(value) {
16667
- return true;
16668
- }
16669
- function WebhookRegionsResponseDataFromJSON(json) {
16670
- return WebhookRegionsResponseDataFromJSONTyped(json, false);
16671
- }
16672
- function WebhookRegionsResponseDataFromJSONTyped(json, ignoreDiscriminator) {
16673
- if (json == null) {
16674
- return json;
16675
- }
16676
- return {
16677
- "regions": json["regions"] == null ? void 0 : json["regions"].map(WebhookRegionFromJSON),
16678
- "defaultRegion": json["default_region"] == null ? void 0 : json["default_region"]
16679
- };
16680
- }
16681
- function WebhookRegionsResponseDataToJSON(json) {
16682
- return WebhookRegionsResponseDataToJSONTyped(json, false);
16683
- }
16684
- function WebhookRegionsResponseDataToJSONTyped(value, ignoreDiscriminator = false) {
16685
- if (value == null) {
16686
- return value;
16687
- }
16688
- return {
16689
- "regions": value["regions"] == null ? void 0 : value["regions"].map(WebhookRegionToJSON),
16690
- "default_region": value["defaultRegion"]
16691
- };
16692
- }
16693
-
16694
- // src/src/models/WebhookRegionsResponse.ts
16695
- function instanceOfWebhookRegionsResponse(value) {
16696
- return true;
16697
- }
16698
- function WebhookRegionsResponseFromJSON(json) {
16699
- return WebhookRegionsResponseFromJSONTyped(json, false);
16700
- }
16701
- function WebhookRegionsResponseFromJSONTyped(json, ignoreDiscriminator) {
16702
- if (json == null) {
16703
- return json;
16704
- }
16705
- return {
16706
- "data": json["data"] == null ? void 0 : WebhookRegionsResponseDataFromJSON(json["data"]),
16707
- "meta": json["meta"] == null ? void 0 : RequestMetaFromJSON(json["meta"])
16708
- };
16709
- }
16710
- function WebhookRegionsResponseToJSON(json) {
16711
- return WebhookRegionsResponseToJSONTyped(json, false);
16712
- }
16713
- function WebhookRegionsResponseToJSONTyped(value, ignoreDiscriminator = false) {
16714
- if (value == null) {
16715
- return value;
16716
- }
16717
- return {
16718
- "data": WebhookRegionsResponseDataToJSON(value["data"]),
16719
- "meta": RequestMetaToJSON(value["meta"])
16720
- };
16721
- }
16722
-
16723
16659
  // src/src/models/WebhookReplayResponse.ts
16724
16660
  function instanceOfWebhookReplayResponse(value) {
16725
16661
  return true;
@@ -17084,6 +17020,40 @@ function WithdrawSubscriberConsentRequestToJSONTyped(value, ignoreDiscriminator
17084
17020
 
17085
17021
  // src/src/apis/AuthApplicationApi.ts
17086
17022
  var AuthApplicationApi = class extends BaseAPI {
17023
+ /**
17024
+ * Returns a machine-readable JSON bundle of everything stored about one end user, for answering a GDPR Art. 15 (access) or Art. 20 (portability) request. Zyphr is a **processor**: we do not answer data subjects directly. This endpoint gives you, the controller, the data needed to respond to your own end user. **Credentials are deliberately excluded** and are listed in `export_metadata.excluded`: password hashes, session refresh-token hashes, MFA secrets, OAuth access/refresh tokens and WebAuthn public keys. These are authentication artifacts rather than personal data about the subject, and including them would turn this endpoint into a credential-exfiltration path. Message history is capped at the 1,000 most recent messages; `export_metadata.message_history_truncated` reports whether the cap was hit.
17025
+ * Export all data held about an end user
17026
+ */
17027
+ async exportEndUserDataRaw(requestParameters, initOverrides) {
17028
+ if (requestParameters["id"] == null) {
17029
+ throw new RequiredError(
17030
+ "id",
17031
+ 'Required parameter "id" was null or undefined when calling exportEndUserData().'
17032
+ );
17033
+ }
17034
+ if (requestParameters["userId"] == null) {
17035
+ throw new RequiredError(
17036
+ "userId",
17037
+ 'Required parameter "userId" was null or undefined when calling exportEndUserData().'
17038
+ );
17039
+ }
17040
+ const queryParameters = {};
17041
+ const headerParameters = {};
17042
+ const response = await this.request({
17043
+ path: `/v1/applications/{id}/users/{userId}/export`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters["id"]))).replace(`{${"userId"}}`, encodeURIComponent(String(requestParameters["userId"]))),
17044
+ method: "GET",
17045
+ headers: headerParameters,
17046
+ query: queryParameters
17047
+ }, initOverrides);
17048
+ return new VoidApiResponse(response);
17049
+ }
17050
+ /**
17051
+ * Returns a machine-readable JSON bundle of everything stored about one end user, for answering a GDPR Art. 15 (access) or Art. 20 (portability) request. Zyphr is a **processor**: we do not answer data subjects directly. This endpoint gives you, the controller, the data needed to respond to your own end user. **Credentials are deliberately excluded** and are listed in `export_metadata.excluded`: password hashes, session refresh-token hashes, MFA secrets, OAuth access/refresh tokens and WebAuthn public keys. These are authentication artifacts rather than personal data about the subject, and including them would turn this endpoint into a credential-exfiltration path. Message history is capped at the 1,000 most recent messages; `export_metadata.message_history_truncated` reports whether the cap was hit.
17052
+ * Export all data held about an end user
17053
+ */
17054
+ async exportEndUserData(id, userId, initOverrides) {
17055
+ await this.exportEndUserDataRaw({ id, userId }, initOverrides);
17056
+ }
17087
17057
  /**
17088
17058
  * Return non-sensitive metadata about the application whose credentials authenticated this request. Lets an integrator read their own application_id (the sole tenant discriminator embedded in every end-user token) directly from the API, rather than only from the dashboard UI or by decoding a token. Returns only id, name, the calling environment\'s mode, and the JWT signing algorithm — never secrets, signing keys, or account-internal fields.
17089
17059
  * Get the authenticating application
@@ -17705,7 +17675,7 @@ var AuthEmailTemplatesApi = class extends BaseAPI {
17705
17675
  // src/src/apis/AuthEmailVerificationApi.ts
17706
17676
  var AuthEmailVerificationApi = class extends BaseAPI {
17707
17677
  /**
17708
- * Verify the user\'s email using the token from the verification email.
17678
+ * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
17709
17679
  * Confirm email verification
17710
17680
  */
17711
17681
  async confirmEmailVerificationRaw(requestParameters, initOverrides) {
@@ -17734,7 +17704,7 @@ var AuthEmailVerificationApi = class extends BaseAPI {
17734
17704
  return new JSONApiResponse(response, (jsonValue) => ConfirmEmailVerificationResponseFromJSON(jsonValue));
17735
17705
  }
17736
17706
  /**
17737
- * Verify the user\'s email using the token from the verification email.
17707
+ * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
17738
17708
  * Confirm email verification
17739
17709
  */
17740
17710
  async confirmEmailVerification(confirmEmailVerificationRequest, initOverrides) {
@@ -17767,7 +17737,7 @@ var AuthEmailVerificationApi = class extends BaseAPI {
17767
17737
  method: "POST",
17768
17738
  headers: headerParameters,
17769
17739
  query: queryParameters,
17770
- body: SendEmailVerificationRequestToJSON(requestParameters["sendEmailVerificationRequest"])
17740
+ body: ResendEmailVerificationRequestToJSON(requestParameters["resendEmailVerificationRequest"])
17771
17741
  }, initOverrides);
17772
17742
  return new JSONApiResponse(response, (jsonValue) => SuccessResultFromJSON(jsonValue));
17773
17743
  }
@@ -17775,12 +17745,12 @@ var AuthEmailVerificationApi = class extends BaseAPI {
17775
17745
  * Resend the verification email to the authenticated user. Rate limited to once per 60 seconds.
17776
17746
  * Resend email verification
17777
17747
  */
17778
- async resendEmailVerification(sendEmailVerificationRequest, initOverrides) {
17779
- const response = await this.resendEmailVerificationRaw({ sendEmailVerificationRequest }, initOverrides);
17748
+ async resendEmailVerification(resendEmailVerificationRequest, initOverrides) {
17749
+ const response = await this.resendEmailVerificationRaw({ resendEmailVerificationRequest }, initOverrides);
17780
17750
  return await response.value();
17781
17751
  }
17782
17752
  /**
17783
- * Send an email verification link to the authenticated user.
17753
+ * Send an email verification link to the authenticated user. Requires all three credentials simultaneously: the application key (`X-Application-Key`), the application secret (`X-Application-Secret`), and the end user\'s `Authorization: Bearer` token. If the recipient is blocked by the application\'s `auth_email_mode=allowlist` gate, the request is still **accepted with 200** (mirroring `POST /auth/forgot-password`): no email is sent, and the suppression is recorded as a `messages` row (`status=suppressed`, `status_reason=recipient_not_allowlisted`) and an `email.suppressed` webhook. It is NOT a 500.
17784
17754
  * Send email verification
17785
17755
  */
17786
17756
  async sendEmailVerificationRaw(requestParameters, initOverrides) {
@@ -17810,7 +17780,7 @@ var AuthEmailVerificationApi = class extends BaseAPI {
17810
17780
  return new JSONApiResponse(response, (jsonValue) => SuccessResultFromJSON(jsonValue));
17811
17781
  }
17812
17782
  /**
17813
- * Send an email verification link to the authenticated user.
17783
+ * Send an email verification link to the authenticated user. Requires all three credentials simultaneously: the application key (`X-Application-Key`), the application secret (`X-Application-Secret`), and the end user\'s `Authorization: Bearer` token. If the recipient is blocked by the application\'s `auth_email_mode=allowlist` gate, the request is still **accepted with 200** (mirroring `POST /auth/forgot-password`): no email is sent, and the suppression is recorded as a `messages` row (`status=suppressed`, `status_reason=recipient_not_allowlisted`) and an `email.suppressed` webhook. It is NOT a 500.
17814
17784
  * Send email verification
17815
17785
  */
17816
17786
  async sendEmailVerification(sendEmailVerificationRequest, initOverrides) {
@@ -21053,7 +21023,7 @@ var EmailsApi = class extends BaseAPI {
21053
21023
  return await response.value();
21054
21024
  }
21055
21025
  /**
21056
- * Queue an email for delivery. The email is processed asynchronously and you\'ll receive a message ID to track its status. You can provide content directly via `html`/`text` fields, or use a template by specifying `template_id` and `template_data`.
21026
+ * Queue an email for delivery. The email is processed asynchronously and you\'ll receive a message ID to track its status. You can provide content directly via `html`/`text` fields, or use a template by specifying `template_id` and `template_data`. **CAN-SPAM compliance — actions required from you:** - **Set `classification`** to `transactional` or `marketing`. Unclassified is treated as marketing, the stricter reading. Transactional mail (password resets, receipts) is exempt from the opt-out and postal-address requirements. - **Set your postal address** in project settings. Commercial email must carry a valid physical postal address — the most commonly missed CAN-SPAM element. Marketing sends without one are flagged. - **Include an unsubscribe mechanism** on commercial email. Zyphr enforces suppression automatically once someone opts out, but the link itself is yours to include. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements).
21057
21027
  * Send an email
21058
21028
  */
21059
21029
  async sendEmailRaw(requestParameters, initOverrides) {
@@ -21079,7 +21049,7 @@ var EmailsApi = class extends BaseAPI {
21079
21049
  return new JSONApiResponse(response, (jsonValue) => SendEmailResponseFromJSON(jsonValue));
21080
21050
  }
21081
21051
  /**
21082
- * Queue an email for delivery. The email is processed asynchronously and you\'ll receive a message ID to track its status. You can provide content directly via `html`/`text` fields, or use a template by specifying `template_id` and `template_data`.
21052
+ * Queue an email for delivery. The email is processed asynchronously and you\'ll receive a message ID to track its status. You can provide content directly via `html`/`text` fields, or use a template by specifying `template_id` and `template_data`. **CAN-SPAM compliance — actions required from you:** - **Set `classification`** to `transactional` or `marketing`. Unclassified is treated as marketing, the stricter reading. Transactional mail (password resets, receipts) is exempt from the opt-out and postal-address requirements. - **Set your postal address** in project settings. Commercial email must carry a valid physical postal address — the most commonly missed CAN-SPAM element. Marketing sends without one are flagged. - **Include an unsubscribe mechanism** on commercial email. Zyphr enforces suppression automatically once someone opts out, but the link itself is yours to include. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements).
21083
21053
  * Send an email
21084
21054
  */
21085
21055
  async sendEmail(sendEmailRequest, initOverrides) {
@@ -22464,6 +22434,31 @@ var SMSApi = class extends BaseAPI {
22464
22434
  const response = await this.getSmsConfigRaw(initOverrides);
22465
22435
  return await response.value();
22466
22436
  }
22437
+ /**
22438
+ * Returns the URL to configure in your SMS provider so STOP/opt-out replies reach Zyphr. The token is generated on first request and is stable thereafter. **This is required for TCPA compliance.** Until your provider is pointed at this URL, opt-out replies stop at the provider and never reach us — from Zyphr\'s side the recipient never opted out, and sends continue. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements).
22439
+ * Get the inbound SMS webhook URL
22440
+ */
22441
+ async getSmsInboundWebhookRaw(initOverrides) {
22442
+ const queryParameters = {};
22443
+ const headerParameters = {};
22444
+ if (this.configuration && this.configuration.apiKey) {
22445
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key");
22446
+ }
22447
+ const response = await this.request({
22448
+ path: `/sms/inbound-webhook`,
22449
+ method: "GET",
22450
+ headers: headerParameters,
22451
+ query: queryParameters
22452
+ }, initOverrides);
22453
+ return new VoidApiResponse(response);
22454
+ }
22455
+ /**
22456
+ * Returns the URL to configure in your SMS provider so STOP/opt-out replies reach Zyphr. The token is generated on first request and is stable thereafter. **This is required for TCPA compliance.** Until your provider is pointed at this URL, opt-out replies stop at the provider and never reach us — from Zyphr\'s side the recipient never opted out, and sends continue. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements).
22457
+ * Get the inbound SMS webhook URL
22458
+ */
22459
+ async getSmsInboundWebhook(initOverrides) {
22460
+ await this.getSmsInboundWebhookRaw(initOverrides);
22461
+ }
22467
22462
  /**
22468
22463
  * List SMS messages for the account with optional filtering and pagination.
22469
22464
  * List SMS messages
@@ -22537,7 +22532,7 @@ var SMSApi = class extends BaseAPI {
22537
22532
  return await response.value();
22538
22533
  }
22539
22534
  /**
22540
- * Send a single SMS text message. Supports subscriber preference checks and scheduling.
22535
+ * Send a single SMS text message. Supports subscriber preference checks and scheduling. **TCPA compliance — actions required from you:** - **Configure the inbound webhook.** Zyphr only processes STOP/opt-out replies if your SMS provider is pointed at our inbound endpoint. Until you do this, opt-outs never reach us and we will keep delivering. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements). - **Pass `recipient_timezone`** (IANA, e.g. `America/New_York`) so quiet hours (8am-9pm recipient-local) can be enforced. Without it we send and record that quiet hours could not be evaluated. We deliberately do not infer a timezone from the area code — people keep numbers when they move. - **Record consent** for marketing sends. Marketing requires prior express *written* consent; `express` consent covers transactional only. With no record on file we deliver and flag it, which is a gap in your evidence, not permission. - **Set `classification`.** Unclassified messages are treated as marketing, the stricter reading.
22541
22536
  * Send an SMS message
22542
22537
  */
22543
22538
  async sendSmsRaw(requestParameters, initOverrides) {
@@ -22563,7 +22558,7 @@ var SMSApi = class extends BaseAPI {
22563
22558
  return new JSONApiResponse(response, (jsonValue) => SendSmsResponseFromJSON(jsonValue));
22564
22559
  }
22565
22560
  /**
22566
- * Send a single SMS text message. Supports subscriber preference checks and scheduling.
22561
+ * Send a single SMS text message. Supports subscriber preference checks and scheduling. **TCPA compliance — actions required from you:** - **Configure the inbound webhook.** Zyphr only processes STOP/opt-out replies if your SMS provider is pointed at our inbound endpoint. Until you do this, opt-outs never reach us and we will keep delivering. See [Compliance Requirements](https://zyphr.dev/guides/compliance-requirements). - **Pass `recipient_timezone`** (IANA, e.g. `America/New_York`) so quiet hours (8am-9pm recipient-local) can be enforced. Without it we send and record that quiet hours could not be evaluated. We deliberately do not infer a timezone from the area code — people keep numbers when they move. - **Record consent** for marketing sends. Marketing requires prior express *written* consent; `express` consent covers transactional only. With no record on file we deliver and flag it, which is a gap in your evidence, not permission. - **Set `classification`.** Unclassified messages are treated as marketing, the stricter reading.
22567
22562
  * Send an SMS message
22568
22563
  */
22569
22564
  async sendSms(sendSmsRequest, initOverrides) {
@@ -25587,32 +25582,6 @@ var WebhooksApi = class extends BaseAPI {
25587
25582
  const response = await this.getWebhookMetricsRaw({ id }, initOverrides);
25588
25583
  return await response.value();
25589
25584
  }
25590
- /**
25591
- * Get available webhook delivery regions. Requires multi_region plan feature (Enterprise only).
25592
- * Get available webhook regions
25593
- */
25594
- async getWebhookRegionsRaw(initOverrides) {
25595
- const queryParameters = {};
25596
- const headerParameters = {};
25597
- if (this.configuration && this.configuration.apiKey) {
25598
- headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key");
25599
- }
25600
- const response = await this.request({
25601
- path: `/v1/webhooks/regions`,
25602
- method: "GET",
25603
- headers: headerParameters,
25604
- query: queryParameters
25605
- }, initOverrides);
25606
- return new JSONApiResponse(response, (jsonValue) => WebhookRegionsResponseFromJSON(jsonValue));
25607
- }
25608
- /**
25609
- * Get available webhook delivery regions. Requires multi_region plan feature (Enterprise only).
25610
- * Get available webhook regions
25611
- */
25612
- async getWebhookRegions(initOverrides) {
25613
- const response = await this.getWebhookRegionsRaw(initOverrides);
25614
- return await response.value();
25615
- }
25616
25585
  /**
25617
25586
  * Get webhook delivery usage statistics for the current billing period.
25618
25587
  * Get webhook usage metrics
@@ -26595,6 +26564,15 @@ var Zyphr = class {
26595
26564
  /** Publishable-key-safe utilities: password policy + pre-submit strength check. */
26596
26565
  utility;
26597
26566
  domains;
26567
+ /**
26568
+ * Multi-step workflow definitions and triggering (sc-7926).
26569
+ *
26570
+ * All 12 operations are API-key authenticated with dedicated
26571
+ * `workflows:read` / `workflows:write` / `workflows:execute` scopes, so this
26572
+ * is deliberate public surface. It was generated but never wired onto the
26573
+ * facade, which made the documented `zyphr.workflows.*` calls throw.
26574
+ */
26575
+ workflows;
26598
26576
  /** Inbound (received) email — read access. Requires the `email:read` scope. */
26599
26577
  inbound;
26600
26578
  waas;
@@ -26623,6 +26601,7 @@ var Zyphr = class {
26623
26601
  this.devices = new DevicesApi(config);
26624
26602
  this.utility = new UtilityApi(config);
26625
26603
  this.domains = new DomainsApi(config);
26604
+ this.workflows = new WorkflowsApi(config);
26626
26605
  this.inbound = new InboundEmailApi(config);
26627
26606
  this.waas = {
26628
26607
  applications: new WaaSApplicationsApi(config),
@@ -28002,6 +27981,10 @@ export {
28002
27981
  RequestMetaToJSON,
28003
27982
  RequestMetaToJSONTyped,
28004
27983
  RequiredError,
27984
+ ResendEmailVerificationRequestFromJSON,
27985
+ ResendEmailVerificationRequestFromJSONTyped,
27986
+ ResendEmailVerificationRequestToJSON,
27987
+ ResendEmailVerificationRequestToJSONTyped,
28005
27988
  ResetPasswordRequestFromJSON,
28006
27989
  ResetPasswordRequestFromJSONTyped,
28007
27990
  ResetPasswordRequestToJSON,
@@ -28862,18 +28845,6 @@ export {
28862
28845
  WebhookMetricsResponseFromJSONTyped,
28863
28846
  WebhookMetricsResponseToJSON,
28864
28847
  WebhookMetricsResponseToJSONTyped,
28865
- WebhookRegionFromJSON,
28866
- WebhookRegionFromJSONTyped,
28867
- WebhookRegionToJSON,
28868
- WebhookRegionToJSONTyped,
28869
- WebhookRegionsResponseDataFromJSON,
28870
- WebhookRegionsResponseDataFromJSONTyped,
28871
- WebhookRegionsResponseDataToJSON,
28872
- WebhookRegionsResponseDataToJSONTyped,
28873
- WebhookRegionsResponseFromJSON,
28874
- WebhookRegionsResponseFromJSONTyped,
28875
- WebhookRegionsResponseToJSON,
28876
- WebhookRegionsResponseToJSONTyped,
28877
28848
  WebhookReplayResponseFromJSON,
28878
28849
  WebhookReplayResponseFromJSONTyped,
28879
28850
  WebhookReplayResponseToJSON,
@@ -29254,6 +29225,7 @@ export {
29254
29225
  instanceOfReorderWorkflowStepsRequest,
29255
29226
  instanceOfReplayWebhookEventsRequest,
29256
29227
  instanceOfRequestMeta,
29228
+ instanceOfResendEmailVerificationRequest,
29257
29229
  instanceOfResetPasswordRequest,
29258
29230
  instanceOfResetPasswordResponse,
29259
29231
  instanceOfResubscribeRequest,
@@ -29458,9 +29430,6 @@ export {
29458
29430
  instanceOfWebhookJobResponse,
29459
29431
  instanceOfWebhookListResponse,
29460
29432
  instanceOfWebhookMetricsResponse,
29461
- instanceOfWebhookRegion,
29462
- instanceOfWebhookRegionsResponse,
29463
- instanceOfWebhookRegionsResponseData,
29464
29433
  instanceOfWebhookReplayResponse,
29465
29434
  instanceOfWebhookResponse,
29466
29435
  instanceOfWebhookSecretRotateResponse,