samva 0.51.0 → 0.52.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.
Files changed (83) hide show
  1. package/AGENTS.md +5 -2
  2. package/README.md +1 -0
  3. package/dist/client/sdk.gen.d.ts +67 -28
  4. package/dist/client/sdk.gen.js +157 -29
  5. package/dist/client/types.gen.d.ts +520 -281
  6. package/dist/effect/campaigns.d.ts +56 -56
  7. package/dist/effect/descriptors/integrations-catalog.d.ts +1 -1
  8. package/dist/effect/descriptors/integrations-catalog.js +1 -1
  9. package/dist/effect/descriptors/integrations.d.ts +1 -1
  10. package/dist/effect/descriptors/integrations.js +1 -1
  11. package/dist/effect/descriptors/logs.d.ts +21 -0
  12. package/dist/effect/descriptors/logs.js +23 -0
  13. package/dist/effect/descriptors/whats-app.d.ts +1 -1
  14. package/dist/effect/descriptors/whats-app.js +1 -1
  15. package/dist/effect/generated/agents.js +4 -4
  16. package/dist/effect/generated/campaigns.d.ts +18 -6
  17. package/dist/effect/generated/campaigns.js +2 -6
  18. package/dist/effect/generated/email.js +3 -3
  19. package/dist/effect/generated/index.d.ts +3 -1
  20. package/dist/effect/generated/integrations-catalog.d.ts +93 -49
  21. package/dist/effect/generated/integrations-catalog.js +17 -28
  22. package/dist/effect/generated/integrations.d.ts +20 -40
  23. package/dist/effect/generated/integrations.js +9 -13
  24. package/dist/effect/generated/journeys.d.ts +61 -13
  25. package/dist/effect/generated/journeys.js +5 -5
  26. package/dist/effect/generated/logs.d.ts +2311 -0
  27. package/dist/effect/generated/logs.js +312 -0
  28. package/dist/effect/generated/mailboxes.d.ts +30 -24
  29. package/dist/effect/generated/mailboxes.js +20 -20
  30. package/dist/effect/generated/messages.d.ts +1 -882
  31. package/dist/effect/generated/messages.js +4 -243
  32. package/dist/effect/generated/newsletter-domains.d.ts +61 -13
  33. package/dist/effect/generated/newsletter-domains.js +5 -5
  34. package/dist/effect/generated/newsletter-issues.d.ts +166 -34
  35. package/dist/effect/generated/newsletter-issues.js +12 -12
  36. package/dist/effect/generated/newsletters.d.ts +76 -16
  37. package/dist/effect/generated/newsletters.js +6 -6
  38. package/dist/effect/generated/organizations.js +1 -1
  39. package/dist/effect/generated/scheduled-messages.js +1 -1
  40. package/dist/effect/generated/shared.d.ts +1138 -257
  41. package/dist/effect/generated/shared.js +321 -82
  42. package/dist/effect/generated/subscriptions.d.ts +4 -4
  43. package/dist/effect/generated/subscriptions.js +2 -6
  44. package/dist/effect/generated/template-registrations.d.ts +46 -10
  45. package/dist/effect/generated/template-registrations.js +4 -4
  46. package/dist/effect/generated/templates.js +2 -2
  47. package/dist/effect/generated/whats-app-flows.d.ts +151 -31
  48. package/dist/effect/generated/whats-app-flows.js +11 -11
  49. package/dist/effect/generated/whats-app-setup-links.d.ts +61 -13
  50. package/dist/effect/generated/whats-app-setup-links.js +5 -5
  51. package/dist/effect/generated/whats-app.d.ts +187 -65
  52. package/dist/effect/generated/whats-app.js +18 -24
  53. package/dist/effect/generated-metadata.d.ts +15 -3
  54. package/dist/effect/generated-metadata.js +375 -349
  55. package/dist/effect/index.d.ts +1 -0
  56. package/dist/effect/index.js +2 -1
  57. package/dist/effect/integrations-catalog.d.ts +92 -4
  58. package/dist/effect/integrations.d.ts +40 -8
  59. package/dist/effect/internal/client.js +25 -3
  60. package/dist/effect/internal/log-events.d.ts +19 -0
  61. package/dist/effect/internal/log-events.js +53 -0
  62. package/dist/effect/internal/mailbox-events.d.ts +6 -2
  63. package/dist/effect/internal/mailbox-events.js +4 -3
  64. package/dist/effect/journeys.d.ts +148 -148
  65. package/dist/effect/logs.d.ts +149 -0
  66. package/dist/effect/logs.js +18 -0
  67. package/dist/effect/mailboxes.d.ts +156 -150
  68. package/dist/effect/mailboxes.js +1 -1
  69. package/dist/effect/newsletter-domains.d.ts +2 -2
  70. package/dist/effect/whatsapp-setup-links.d.ts +2 -2
  71. package/dist/effect/whatsapp.d.ts +73 -3
  72. package/dist/mailbox-events.d.ts +50 -3
  73. package/dist/mailbox-events.js +38 -19
  74. package/dist/package.js +1 -1
  75. package/dist/promises/client.d.ts +3 -1
  76. package/dist/promises/client.js +3 -1
  77. package/dist/promises/errors.gen.d.ts +2 -0
  78. package/dist/promises/errors.gen.js +137 -34
  79. package/dist/promises/types.gen.d.ts +1 -1
  80. package/dist/request-id.d.ts +3 -0
  81. package/dist/request-id.js +7 -0
  82. package/dist/service-map.d.ts +14 -3
  83. package/package.json +6 -2
@@ -192,7 +192,7 @@ var Messages = class {
192
192
  /**
193
193
  * Send a message
194
194
  *
195
- * An email send whose namespace has no sending setup returns ValidationError: share the sender domain with namespaces, or use a sender owned by that namespace. Sending setup that has stopped after failure returns ValidationError; restart or reconcile the domain's sending setup. Setup still in progress returns ConflictError. Sends a message on the requested channel and returns its receipt (id, status, and why it waits when it does) with a 201 Created status. Requires `messages:create` or the send permission of the channel it sends on, such as `email:send`. `channel` selects the payload variant. Email and WhatsApp sends are available. Repeating an identical request with the same optional `Idempotency-Key` header returns the original receipt; reusing the key for different content returns a conflict.
195
+ * An email send whose namespace has no sending setup returns ValidationError: share the sender domain with namespaces, or use a sender owned by that namespace. Sending setup that has stopped after failure returns ValidationError; restart or reconcile the domain's sending setup. Setup still in progress returns ConflictError. Sends a message on the requested channel and returns its receipt (id, status, and why it waits when it does) with a 201 Created status. Requires `messages:create` or the send permission of the channel it sends on, such as `email:send`. `channel` selects the payload variant. Email and WhatsApp sends are available. Once a send succeeds, repeating the request with the same `Idempotency-Key` and body returns the original receipt. While it is still in progress, a 409 includes a `Retry-After` header. Reusing the key for different content returns a 409 without a retry hint.
196
196
  */
197
197
  static send(parameters, options) {
198
198
  const params = { body: parameters };
@@ -465,6 +465,124 @@ var Messages = class {
465
465
  }));
466
466
  }
467
467
  };
468
+ var Logs = class {
469
+ /**
470
+ * List message log events
471
+ *
472
+ * Lists the organization's message events in its plan's log window. The default sort is by event timestamp. Use orderBy=recorded and order=asc to poll events in ingestion order, including events with older timestamps. Pass the last event's cursor as after. Keep the same sort and direction when paging.
473
+ */
474
+ static list(parameters, options) {
475
+ const params = buildClientParams([parameters], [{ args: [
476
+ {
477
+ in: "query",
478
+ key: "limit"
479
+ },
480
+ {
481
+ in: "query",
482
+ key: "cursor"
483
+ },
484
+ {
485
+ in: "query",
486
+ key: "after"
487
+ },
488
+ {
489
+ in: "query",
490
+ key: "orderBy"
491
+ },
492
+ {
493
+ in: "query",
494
+ key: "order"
495
+ },
496
+ {
497
+ in: "query",
498
+ key: "since"
499
+ },
500
+ {
501
+ in: "query",
502
+ key: "until"
503
+ },
504
+ {
505
+ in: "query",
506
+ key: "status"
507
+ },
508
+ {
509
+ in: "query",
510
+ key: "event"
511
+ },
512
+ {
513
+ in: "query",
514
+ key: "channel"
515
+ },
516
+ {
517
+ in: "query",
518
+ key: "direction"
519
+ },
520
+ {
521
+ in: "query",
522
+ key: "origin"
523
+ },
524
+ {
525
+ in: "query",
526
+ key: "credential"
527
+ },
528
+ {
529
+ in: "query",
530
+ key: "from"
531
+ },
532
+ {
533
+ in: "query",
534
+ key: "messageId"
535
+ },
536
+ {
537
+ in: "query",
538
+ key: "mailboxId"
539
+ },
540
+ {
541
+ in: "query",
542
+ key: "requestId"
543
+ }
544
+ ] }]);
545
+ return requestWithPolicy(options?.client ?? client, "logsList", options, (headers, signal) => (options?.client ?? client).get({
546
+ security: [{
547
+ name: "x-api-key",
548
+ type: "apiKey"
549
+ }],
550
+ url: "/v1/logs",
551
+ ...options,
552
+ ...params,
553
+ headers: {
554
+ ...headers,
555
+ ...params.headers
556
+ },
557
+ signal
558
+ }));
559
+ }
560
+ /**
561
+ * Get message log detail
562
+ *
563
+ * Returns the message and its event timeline, or a rejected submission, by message, rejection, or request ID.
564
+ */
565
+ static get(parameters, options) {
566
+ const params = buildClientParams([parameters], [{ args: [{
567
+ in: "path",
568
+ key: "id"
569
+ }] }]);
570
+ return requestWithPolicy(options?.client ?? client, "logsGet", options, (headers, signal) => (options?.client ?? client).get({
571
+ security: [{
572
+ name: "x-api-key",
573
+ type: "apiKey"
574
+ }],
575
+ url: "/v1/logs/{id}",
576
+ ...options,
577
+ ...params,
578
+ headers: {
579
+ ...headers,
580
+ ...params.headers
581
+ },
582
+ signal
583
+ }));
584
+ }
585
+ };
468
586
  var Operations = class {
469
587
  /**
470
588
  * List asynchronous operations
@@ -694,7 +812,7 @@ var ScheduledMessages = class {
694
812
  /**
695
813
  * Resume a review-paused scheduled message
696
814
  *
697
- * Explicitly resumes a scheduled message after onboarding review clearance. An overdue message requires either send_now or a new future scheduledFor value.
815
+ * Explicitly resumes a scheduled message once Samva's email review approves the organization. An overdue message requires either send_now or a new future scheduledFor value.
698
816
  */
699
817
  static resume(parameters, options) {
700
818
  const params = buildClientParams([parameters], [{ args: [{
@@ -1226,9 +1344,9 @@ var Campaigns = class {
1226
1344
  };
1227
1345
  var Email = class {
1228
1346
  /**
1229
- * Get email onboarding review status
1347
+ * Get email review status
1230
1348
  *
1231
- * Returns the customer-safe organization review decision, workflow stage, next action, and current sending-identity clearances. An organization that has not been reviewed yet is returned in the blocked initial state.
1349
+ * Returns whether the organization's email can send and where Samva's review of it stands: the decision, stage, stable block reason, next action, and current sending-identity clearances. Samva reviews some new organizations before their first email; while it does, `canSend` is false and `nextAction` is `wait_for_review`. Mailbox sends wait as `queued` with wait reason `onboarding-review` and go out once the review approves the organization; other sends are refused with `OnboardingReviewRequiredError`.
1232
1350
  */
1233
1351
  static getOnboardingReview(options) {
1234
1352
  return requestWithPolicy(options?.client ?? client, "emailGetOnboardingReview", options, (headers, signal) => (options?.client ?? client).get({
@@ -1243,7 +1361,7 @@ var Email = class {
1243
1361
  }));
1244
1362
  }
1245
1363
  /**
1246
- * Reapply for email onboarding review
1364
+ * Reapply for email review
1247
1365
  *
1248
1366
  * Allows an organization owner or admin to submit a rejected organization for review again. The expected generation prevents acting on stale status.
1249
1367
  */
@@ -1270,7 +1388,7 @@ var Email = class {
1270
1388
  }));
1271
1389
  }
1272
1390
  /**
1273
- * Respond to an email onboarding information request
1391
+ * Respond to an email review information request
1274
1392
  *
1275
1393
  * Allows organization owners and admins to submit a text response and up to three evidence uploads for the current information request.
1276
1394
  */
@@ -5591,7 +5709,7 @@ var Agents = class {
5591
5709
  /**
5592
5710
  * Create an agent
5593
5711
  *
5594
- * Creates an agent with a draft and returns it with status 201. The agent answers nothing until its draft is published. The default policy requires a person to approve replies and final actions. The namespace is set at creation and cannot change.
5712
+ * Creates an agent with a draft and returns it with status 201. The agent answers nothing until its draft is published. The default policy requires a person to approve replies and final actions. API keys need organization-wide reach to create with a custom policy. The namespace is set at creation and cannot change.
5595
5713
  */
5596
5714
  static create(parameters, options) {
5597
5715
  const params = buildClientParams([parameters], [{ args: [
@@ -5736,7 +5854,7 @@ var Agents = class {
5736
5854
  /**
5737
5855
  * Replace an agent draft
5738
5856
  *
5739
- * Replaces the whole draft and returns the agent with a new revision. The request names the revision it read; a stale revision returns 409. Published versions, and the conversations answered on them, do not change. An endpoint answers for one agent at a time: a draft that names an endpoint another agent answers on returns 409. A draft that pins a catalog model returns 402 unless your plan is Growth or Scale, and 422 when the model is not available or does not support the reasoning level.
5857
+ * Replaces the whole draft and returns the agent with a new revision. The request names the revision it read; a stale revision returns 409. API keys need organization-wide reach to change the draft policy. Published versions, and the conversations answered on them, do not change. An endpoint answers for one agent at a time: a draft that names an endpoint another agent answers on returns 409. A draft that pins a catalog model returns 402 unless your plan is Growth or Scale, and 422 when the model is not available or does not support the reasoning level.
5740
5858
  */
5741
5859
  static replaceDraft(parameters, options) {
5742
5860
  const params = buildClientParams([parameters], [{ args: [
@@ -5773,7 +5891,7 @@ var Agents = class {
5773
5891
  /**
5774
5892
  * Publish an agent
5775
5893
  *
5776
- * Publishes the draft as the next immutable version. Each conversation moves to it from its next agent reply; a reply already running finishes on the version it started on. The request names the revision it read; a stale revision returns 409. Publishing a draft identical to the newest version changes nothing and answers published false. An endpoint answers for one agent at a time: publishing a draft whose endpoint another agent answers on returns 409. The published policy governs review of each proposed action.
5894
+ * Publishes the draft as the next immutable version. API keys need organization-wide reach to publish a policy change. Each conversation moves to it from its next agent reply; a reply already running finishes on the version it started on. The request names the revision it read; a stale revision returns 409. Publishing a draft identical to the newest version changes nothing and answers published false. An endpoint answers for one agent at a time: publishing a draft whose endpoint another agent answers on returns 409. The published policy governs review of each proposed action.
5777
5895
  */
5778
5896
  static publish(parameters, options) {
5779
5897
  const params = buildClientParams([parameters], [{ args: [{
@@ -5838,7 +5956,7 @@ var Agents = class {
5838
5956
  /**
5839
5957
  * Publish an agent module
5840
5958
  *
5841
- * Publishes a self-contained JavaScript module and its manifest as the next immutable version. Source is stored by its SHA-256 digest without execution. The revision protects the draft read by the publisher; a stale revision returns 409. Publishing the same manifest, source, and definition again returns published false. The manifest controls the model, endpoints, integration grants, and action policy. Draft instructions and knowledge remain editable builder data; the hosted runtime reads instructions and tools from the published module.
5959
+ * Publishes a self-contained JavaScript module and its manifest as the next immutable version. API keys need organization-wide reach to publish a policy change. Source is stored by its SHA-256 digest without execution. The revision protects the draft read by the publisher; a stale revision returns 409. Publishing the same manifest, source, and definition again returns published false. The manifest controls the model, endpoints, integration grants, and action policy. Draft instructions and knowledge remain editable builder data; the hosted runtime reads instructions and tools from the published module.
5842
5960
  */
5843
5961
  static publishVersion(parameters, options) {
5844
5962
  const params = buildClientParams([parameters], [{ args: [
@@ -6490,7 +6608,7 @@ var IntegrationCatalog = class {
6490
6608
  /**
6491
6609
  * Read Shopify post-delivery check-in readiness
6492
6610
  *
6493
- * Checks selected resources and current feature availability. A namespace caller sees its reachable resources. Shopify account and plan fields are null, and full recipe readiness requires organization-wide access. Omit the email sender or WhatsApp account to see the sender or number selected for the publication and caller scope. Requires email:read and domains:read for email, or whatsappAccounts:read for WhatsApp.
6611
+ * Checks selected resources and plan access. A namespace caller sees its reachable resources. Shopify account and plan fields are null, and full recipe readiness requires organization-wide access. Omit the email sender or WhatsApp account to see the sender or number selected for the publication and caller scope. Requires email:read and domains:read for email, or whatsappAccounts:read for WhatsApp.
6494
6612
  */
6495
6613
  static recipeReadiness(parameters, options) {
6496
6614
  const params = buildClientParams([parameters], [{ args: [
@@ -6571,7 +6689,7 @@ var IntegrationCatalog = class {
6571
6689
  /**
6572
6690
  * Search the integrations catalog
6573
6691
  *
6574
- * Searches the providers this organization can connect, by key, text or category. Each entry carries its connection requirements and whether it can connect. Follow nextOffset until it is null.
6692
+ * Searches the providers this organization can connect, by key, text or category. Each entry carries its connection requirements and whether it can connect. Pass nextCursor back as cursor until it is null.
6575
6693
  */
6576
6694
  static search(parameters, options) {
6577
6695
  const params = buildClientParams([parameters], [{ args: [
@@ -6589,11 +6707,11 @@ var IntegrationCatalog = class {
6589
6707
  },
6590
6708
  {
6591
6709
  in: "query",
6592
- key: "offset"
6710
+ key: "limit"
6593
6711
  },
6594
6712
  {
6595
6713
  in: "query",
6596
- key: "limit"
6714
+ key: "cursor"
6597
6715
  }
6598
6716
  ] }]);
6599
6717
  return requestWithPolicy(options?.client ?? client, "integrationCatalogSearch", options, (headers, signal) => (options?.client ?? client).get({
@@ -6633,7 +6751,7 @@ var Integrations = class {
6633
6751
  /**
6634
6752
  * List integrations
6635
6753
  *
6636
- * Returns a bounded page of installed integrations, newest first, with compact tool summaries. Follow nextCursor and each integration's toolPage.nextOffset for the complete inventory.
6754
+ * Returns a bounded page of installed integrations, newest first, with compact tool summaries. Follow nextCursor and each integration's toolPage.nextCursor for the complete inventory.
6637
6755
  */
6638
6756
  static list(parameters, options) {
6639
6757
  const params = buildClientParams([parameters], [{ args: [{
@@ -6698,7 +6816,7 @@ var Integrations = class {
6698
6816
  /**
6699
6817
  * List integration tools
6700
6818
  *
6701
- * Returns a page of the tools an integration gives agents. Send the first page's revision with each later offset; if the integration's tools change during the read, the request returns 409 and the read restarts at offset zero.
6819
+ * Returns a page of the tools an integration gives agents. Pass nextCursor back as cursor. If the integration's tools change during pagination, the request returns 409. Restart without a cursor.
6702
6820
  */
6703
6821
  static listTools(parameters, options) {
6704
6822
  const params = buildClientParams([parameters], [{ args: [
@@ -6708,11 +6826,11 @@ var Integrations = class {
6708
6826
  },
6709
6827
  {
6710
6828
  in: "query",
6711
- key: "offset"
6829
+ key: "limit"
6712
6830
  },
6713
6831
  {
6714
6832
  in: "query",
6715
- key: "revision"
6833
+ key: "cursor"
6716
6834
  }
6717
6835
  ] }]);
6718
6836
  return requestWithPolicy(options?.client ?? client, "integrationsListTools", options, (headers, signal) => (options?.client ?? client).get({
@@ -6733,7 +6851,7 @@ var Integrations = class {
6733
6851
  /**
6734
6852
  * Read an integration tool descriptor
6735
6853
  *
6736
- * Returns one tool's full descriptor. A revision that no longer matches the integration's tools returns 409.
6854
+ * Returns one tool's descriptor in chunks. Pass nextOffset back as offset with the same revision. A revision that no longer matches the integration's tools returns 409.
6737
6855
  */
6738
6856
  static readTool(parameters, options) {
6739
6857
  const params = buildClientParams([parameters], [{ args: [
@@ -6822,7 +6940,7 @@ var Integrations = class {
6822
6940
  /**
6823
6941
  * Update an integration
6824
6942
  *
6825
- * Changes an integration's settings, enabled tools, which tools run without approval, and whether replies using its data need approval. Only an organization owner may change answerWithoutApproval or a tool's runsWithoutApproval: false makes a read tool ask first, true lets a tool that changes something run, each for the tool's current effect. Fields not named keep their values. What an agent may do with the integration is the agent's grant.
6943
+ * Changes an integration's settings, enabled tools, which tools run without approval, and whether replies using its data need approval. Changing answerWithoutApproval requires an organization owner and, for an API key, organization-wide reach. An organization owner or an API key with organization-wide reach can change a tool's runsWithoutApproval for its current effect. False makes a read tool ask first. True lets a tool that changes something run. Fields not named keep their values. What an agent may do with the integration is the agent's grant.
6826
6944
  */
6827
6945
  static update(parameters, options) {
6828
6946
  const params = buildClientParams([parameters], [{ args: [
@@ -11126,9 +11244,9 @@ var Organizations = class {
11126
11244
  }));
11127
11245
  }
11128
11246
  /**
11129
- * Get organization trust tier and sending limits
11247
+ * Get the organization's sending limits
11130
11248
  *
11131
- * Returns the current trust tier, plan and probation sending limits, and measured probation graduation progress. Limits are additional to billing allowance, domain readiness, and enforcement. Graduation is evaluated on delivery events.
11249
+ * Returns which sending limits apply to the organization and its progress toward the plan's limits. `tier` is `screened` while the organization waits for Samva's review before its first email, `probation` while a new organization sends on starting limits (`sendingLimits.probation`), and `established` once it sends on its plan's limits. `graduation` measures the delivery record a new organization needs before it moves to its plan's limits, and is checked as deliveries arrive. Billing allowance, domain readiness, and sending pauses apply as well.
11132
11250
  */
11133
11251
  static getTrustTier(options) {
11134
11252
  return requestWithPolicy(options?.client ?? client, "organizationsGetTrustTier", options, (headers, signal) => (options?.client ?? client).get({
@@ -12487,7 +12605,7 @@ var Mailboxes = class {
12487
12605
  /**
12488
12606
  * List mailbox decisions awaiting you
12489
12607
  *
12490
- * Returns held actions this caller can approve and quarantined messages this caller may release across their visible mailboxes. Counts cover all actionable items, independent of the current cursor page. Metadata only; isolated messages, self approvals, and decisions the credential cannot perform are excluded.
12608
+ * Returns held actions this caller can approve across their visible mailboxes. Counts cover all actionable items across pages. The queue excludes the caller’s own proposals. Read Spam through the thread list and use the held-mail endpoint for malware metadata.
12491
12609
  */
12492
12610
  static getNeedsYou(parameters, options) {
12493
12611
  const params = buildClientParams([parameters], [{ args: [{
@@ -12558,7 +12676,7 @@ var Mailboxes = class {
12558
12676
  /**
12559
12677
  * List threads across your mailboxes
12560
12678
  *
12561
- * Lists only threads in mailboxes the caller can read. With `q`, semantic and keyword search returns the best-matching threads in relevance order, capped across cursor pages. Without `q`, threads use newest activity first. Repeat mailboxId to narrow the scope; kind selects personal or shared mailboxes. conversation selects the threads of one conversation (the conversationId a thread reports), one per readable mailbox it reached. state=active excludes what the caller finished; state=done selects the caller's Done, closed shared threads, and personal-mailbox threads in the archived folder, without duplicates. Other filters and cursor pagination match the per-mailbox list.
12679
+ * Lists only threads in mailboxes the caller can read. With `q`, semantic and keyword search returns the best-matching threads in relevance order, capped across cursor pages. Without `q`, threads use newest activity first. Use `snoozed=true&order=wake` for earliest wake first, with ascending thread ID for ties. Repeat mailboxId to narrow the scope; kind selects personal or shared mailboxes. conversation selects the threads of one conversation (the conversationId a thread reports), one per readable mailbox it reached. state=active excludes what the caller finished; state=done selects the caller's Done, closed shared threads, and personal-mailbox threads in the archived folder, without duplicates. Other filters and cursor pagination match the per-mailbox list.
12562
12680
  */
12563
12681
  static listOrganizationThreads(parameters, options) {
12564
12682
  const params = buildClientParams([parameters], [{ args: [
@@ -12618,6 +12736,10 @@ var Mailboxes = class {
12618
12736
  in: "query",
12619
12737
  key: "snoozed"
12620
12738
  },
12739
+ {
12740
+ in: "query",
12741
+ key: "order"
12742
+ },
12621
12743
  {
12622
12744
  in: "query",
12623
12745
  key: "mailboxId"
@@ -12649,7 +12771,7 @@ var Mailboxes = class {
12649
12771
  /**
12650
12772
  * List threads in a mailbox
12651
12773
  *
12652
- * Returns thread summaries. With `q`, semantic and keyword search returns up to 100 best-matching threads in relevance order across cursor pages. It searches subjects, participants, message text including quoted history, and attachment filenames, not attachment contents. New mail can take a few seconds to become searchable. Other filters narrow the searchable set. Without `q`, threads use most recent activity first; `after` and `before` filter by last activity for polling. Pass `nextCursor` back as `cursor` for the next page; it is null on the last page. In a list without `q`, a thread that gains activity while you page moves ahead of the cursor, so a walk lists each thread at most once. Omit `folder` to list every folder. A thread's folder is set when it is created and does not move on later replies: a thread a send started stays in `sent`, so find replies with `unread: true` and no `folder`.
12774
+ * Returns thread summaries. With `q`, semantic and keyword search returns up to 100 best-matching threads in relevance order across cursor pages. It searches subjects, participants, message text including quoted history, and attachment filenames, not attachment contents. New mail can take a few seconds to become searchable. Other filters narrow the searchable set. Without `q`, threads use most recent activity first. Use `snoozed=true&order=wake` for earliest wake first, with ascending thread ID for ties. The `after` and `before` filters always use last activity. Pass `nextCursor` back as `cursor` for the next page; it is null on the last page. In an activity-ordered list, a thread that gains activity while you page moves ahead of the cursor, so a walk lists each thread at most once. Omit `folder` to list every folder. A thread's folder is set when it is created and does not move on later replies: a thread a send started stays in `sent`, so find replies with `unread: true` and no `folder`.
12653
12775
  */
12654
12776
  static listThreads(parameters, options) {
12655
12777
  const params = buildClientParams([parameters], [{ args: [
@@ -12712,6 +12834,10 @@ var Mailboxes = class {
12712
12834
  {
12713
12835
  in: "query",
12714
12836
  key: "snoozed"
12837
+ },
12838
+ {
12839
+ in: "query",
12840
+ key: "order"
12715
12841
  }
12716
12842
  ] }]);
12717
12843
  return requestWithPolicy(options?.client ?? client, "mailboxesListThreads", options, (headers, signal) => (options?.client ?? client).get({
@@ -15077,17 +15203,17 @@ var Whatsapp = class {
15077
15203
  /**
15078
15204
  * List WhatsApp business accounts
15079
15205
  *
15080
- * Returns a paginated list of the organization's connected WhatsApp business accounts.
15206
+ * Lists connected WhatsApp business accounts, newest first. Pass nextCursor back as cursor to continue.
15081
15207
  */
15082
15208
  static listBusinessAccounts(parameters, options) {
15083
15209
  const params = buildClientParams([parameters], [{ args: [
15084
15210
  {
15085
15211
  in: "query",
15086
- key: "page"
15212
+ key: "limit"
15087
15213
  },
15088
15214
  {
15089
15215
  in: "query",
15090
- key: "limit"
15216
+ key: "cursor"
15091
15217
  },
15092
15218
  {
15093
15219
  in: "query",
@@ -15818,6 +15944,8 @@ Object.assign(Messages.getEmail, { operation: "messagesGetEmail" });
15818
15944
  Object.assign(Messages.validateEmail, { operation: "messagesValidateEmail" });
15819
15945
  Object.assign(Messages.getStatus, { operation: "messagesGetStatus" });
15820
15946
  Object.assign(Messages.getEvents, { operation: "messagesGetEvents" });
15947
+ Object.assign(Logs.list, { operation: "logsList" });
15948
+ Object.assign(Logs.get, { operation: "logsGet" });
15821
15949
  Object.assign(Operations.list, { operation: "operationsList" });
15822
15950
  Object.assign(Operations.get, { operation: "operationsGet" });
15823
15951
  Object.assign(Operations.retry, { operation: "operationsRetry" });
@@ -16267,6 +16395,6 @@ Object.assign(WhatsappSetupLinks.revoke, { operation: "whatsappSetupLinksRevoke"
16267
16395
  Object.assign(TemplateRegistrations.list, { operation: "templateRegistrationsList" });
16268
16396
  Object.assign(TemplateRegistrations.submit, { operation: "templateRegistrationsSubmit" });
16269
16397
  Object.assign(TemplateRegistrations.get, { operation: "templateRegistrationsGet" });
16270
- export { Accounts, Agents, Analytics, ApiKeys, ApprovalRequests, Attachments, Brands, Campaigns, ContactEvents, ContactGroups, Contacts, Conversations, CustomFields, Domains, Email, Events, Feedback, IntegrationCatalog, Integrations, Issues, Journeys, Mailboxes, Media, Messages, Namespaces, Newsletters, Operations, Organizations, Policies, ScheduledMessages, Subscriptions, TemplateRegistrations, TemplateShareLinks, Templates, TopicForms, Topics, Webhooks, Whatsapp, WhatsappFlows, WhatsappSetupLinks, Whoami };
16398
+ export { Accounts, Agents, Analytics, ApiKeys, ApprovalRequests, Attachments, Brands, Campaigns, ContactEvents, ContactGroups, Contacts, Conversations, CustomFields, Domains, Email, Events, Feedback, IntegrationCatalog, Integrations, Issues, Journeys, Logs, Mailboxes, Media, Messages, Namespaces, Newsletters, Operations, Organizations, Policies, ScheduledMessages, Subscriptions, TemplateRegistrations, TemplateShareLinks, Templates, TopicForms, Topics, Webhooks, Whatsapp, WhatsappFlows, WhatsappSetupLinks, Whoami };
16271
16399
 
16272
16400
  //# sourceMappingURL=sdk.gen.js.map