@stream-io/node-sdk 0.8.12 → 0.8.14

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.
@@ -85,6 +85,10 @@ export interface APIError {
85
85
  * Additional error-specific information
86
86
  */
87
87
  details: Array<number>;
88
+ /**
89
+ * Milliseconds until the user's slow mode cool down period ends. Only set on code 60 (cool down) errors
90
+ */
91
+ cooldown_remaining_ms?: number;
88
92
  /**
89
93
  * Flag that indicates if the error is unrecoverable, requests that return unrecoverable errors should not be retried, this error only applies to the request that caused it
90
94
  */
@@ -987,6 +991,7 @@ export interface AddActivityRequest {
987
991
  * Whether to skip URL enrichment for the activity
988
992
  */
989
993
  skip_enrich_url?: boolean;
994
+ skip_existing?: boolean;
990
995
  /**
991
996
  * Whether to skip push notifications
992
997
  */
@@ -1048,6 +1053,10 @@ export interface AddActivityResponse {
1048
1053
  * Number of mention notification activities created for mentioned users
1049
1054
  */
1050
1055
  mention_notifications_created?: number;
1056
+ /**
1057
+ * Contains the activity ID when skip_existing is true and the activity already existed, so it was left unchanged.
1058
+ */
1059
+ skipped_existing?: Array<string>;
1051
1060
  }
1052
1061
  export interface AddBookmarkRequest {
1053
1062
  /**
@@ -1477,6 +1486,14 @@ export interface AnalyzeResponse {
1477
1486
  * `complete` (all fields screened), `partial` (mix of verdicts and per-field errors), or `pending` (async).
1478
1487
  */
1479
1488
  status: string;
1489
+ /**
1490
+ * ID of the LLM model that scored the content (e.g. gpt-4o-mini). Omitted when no LLM verdict was used (e.g. Bodyguard-only, or `pending`).
1491
+ */
1492
+ llm_model?: string;
1493
+ /**
1494
+ * reasoning_effort sent with the LLM request. Omitted when the request did not send one.
1495
+ */
1496
+ llm_reasoning_effort?: string;
1480
1497
  /**
1481
1498
  * Per-image moderation verdicts keyed by caller label.
1482
1499
  */
@@ -1512,6 +1529,16 @@ export interface AnalyzeTextField {
1512
1529
  */
1513
1530
  classifications?: Array<Classification>;
1514
1531
  }
1532
+ export interface AppDefaults {
1533
+ /**
1534
+ * Defaults applied by the get-or-create channel endpoint.
1535
+ */
1536
+ get_or_create_channel: GetOrCreateChannelDefaults;
1537
+ /**
1538
+ * Defaults applied by the query channels endpoint.
1539
+ */
1540
+ query_channels: QueryChannelsDefaults;
1541
+ }
1515
1542
  export interface AppResponseFields {
1516
1543
  allow_multi_user_devices: boolean;
1517
1544
  /**
@@ -1569,6 +1596,10 @@ export interface AppResponseFields {
1569
1596
  webhook_events: Array<string>;
1570
1597
  call_types: Record<string, CallType>;
1571
1598
  channel_configs: Record<string, ChannelConfig>;
1599
+ /**
1600
+ * Request limit defaults applied by the server when the corresponding field is omitted.
1601
+ */
1602
+ defaults: AppDefaults;
1572
1603
  file_upload_config: FileUploadConfig;
1573
1604
  grants: Record<string, Array<string>>;
1574
1605
  image_upload_config: FileUploadConfig;
@@ -1810,6 +1841,7 @@ export interface AsyncExportUsersEvent {
1810
1841
  export interface AsyncImportErrorEvent {
1811
1842
  created_at: Date;
1812
1843
  error: string;
1844
+ error_code: string;
1813
1845
  finished_at: Date;
1814
1846
  product: string;
1815
1847
  state: string;
@@ -3514,6 +3546,7 @@ export interface CallSettingsRequest {
3514
3546
  geofencing?: GeofenceSettingsRequest;
3515
3547
  individual_recording?: IndividualRecordingSettingsRequest;
3516
3548
  ingress?: IngressSettingsRequest;
3549
+ lifecycle?: LifecycleSettingsRequest;
3517
3550
  limits?: LimitsSettingsRequest;
3518
3551
  raw_recording?: RawRecordingSettingsRequest;
3519
3552
  recording?: RecordSettingsRequest;
@@ -3538,6 +3571,10 @@ export interface CallSettingsResponse {
3538
3571
  frame_recording: FrameRecordingSettingsResponse;
3539
3572
  geofencing: GeofenceSettingsResponse;
3540
3573
  individual_recording: IndividualRecordingSettingsResponse;
3574
+ /**
3575
+ * LifecycleSettings is the payload for call lifecycle settings
3576
+ */
3577
+ lifecycle: LifecycleSettingsResponse;
3541
3578
  limits: LimitsSettingsResponse;
3542
3579
  raw_recording: RawRecordingSettingsResponse;
3543
3580
  /**
@@ -3918,8 +3955,6 @@ export interface CampaignStatsResponse {
3918
3955
  stats_users_read: number;
3919
3956
  stats_users_sent: number;
3920
3957
  }
3921
- export interface CancelImportV2TaskRequest {
3922
- }
3923
3958
  export interface CancelImportV2TaskResponse {
3924
3959
  /**
3925
3960
  * Duration of the request in milliseconds
@@ -3927,6 +3962,14 @@ export interface CancelImportV2TaskResponse {
3927
3962
  duration: string;
3928
3963
  }
3929
3964
  export interface CastPollVoteRequest {
3965
+ /**
3966
+ * Key of the moderation configuration to use. Server-side only.
3967
+ */
3968
+ config_key?: string;
3969
+ /**
3970
+ * Team associated with the configuration. Server-side only.
3971
+ */
3972
+ config_team?: string;
3930
3973
  user_id?: string;
3931
3974
  /**
3932
3975
  * User request object
@@ -3948,6 +3991,30 @@ export interface ChangeFeedVisibilityResponse {
3948
3991
  duration: string;
3949
3992
  feed: FeedResponse;
3950
3993
  }
3994
+ export interface ChannelBanResponse {
3995
+ created_at: Date;
3996
+ scopes: Array<string>;
3997
+ channel_ban?: ChannelBanScopeResponse;
3998
+ future_channel_ban?: ChannelBanScopeResponse;
3999
+ /**
4000
+ * User response object
4001
+ */
4002
+ user?: UserResponse;
4003
+ }
4004
+ export interface ChannelBanScopeResponse {
4005
+ created_at: Date;
4006
+ shadow: boolean;
4007
+ expires?: Date;
4008
+ reason?: string;
4009
+ /**
4010
+ * User response object
4011
+ */
4012
+ banned_by?: UserResponse;
4013
+ }
4014
+ export interface ChannelBansScopeTotals {
4015
+ channel: number;
4016
+ future_channel: number;
4017
+ }
3951
4018
  export interface ChannelBatchCompletedEvent {
3952
4019
  batch_created_at: Date;
3953
4020
  created_at: Date;
@@ -4471,6 +4538,7 @@ export interface ChannelMemberResponse {
4471
4538
  * Date/time of the last update
4472
4539
  */
4473
4540
  updated_at: Date;
4541
+ user_id: string;
4474
4542
  custom: Record<string, any>;
4475
4543
  archived_at?: Date;
4476
4544
  /**
@@ -4508,7 +4576,6 @@ export interface ChannelMemberResponse {
4508
4576
  */
4509
4577
  role?: string;
4510
4578
  status?: string;
4511
- user_id?: string;
4512
4579
  deleted_messages?: Array<string>;
4513
4580
  /**
4514
4581
  * User response object
@@ -4603,6 +4670,7 @@ export declare const ChannelOwnCapability: {
4603
4670
  readonly QUERY_POLL_VOTES: "query-poll-votes";
4604
4671
  readonly QUOTE_MESSAGE: "quote-message";
4605
4672
  readonly READ_EVENTS: "read-events";
4673
+ readonly SCHEDULE_MESSAGE: "schedule-message";
4606
4674
  readonly SEARCH_MESSAGES: "search-messages";
4607
4675
  readonly SEND_CUSTOM_EVENTS: "send-custom-events";
4608
4676
  readonly SEND_LINKS: "send-links";
@@ -4666,6 +4734,10 @@ export interface ChannelResponse {
4666
4734
  * Custom data for this object
4667
4735
  */
4668
4736
  custom: Record<string, any>;
4737
+ /**
4738
+ * Number of members who are not deactivated or deleted
4739
+ */
4740
+ active_member_count?: number;
4669
4741
  /**
4670
4742
  * Whether auto translation is enabled or not
4671
4743
  */
@@ -4746,16 +4818,54 @@ export interface ChannelResponse {
4746
4818
  }
4747
4819
  export interface ChannelStateResponse {
4748
4820
  duration: string;
4821
+ /**
4822
+ * List of channel members
4823
+ */
4749
4824
  members: Array<ChannelMemberResponse>;
4825
+ /**
4826
+ * List of channel messages
4827
+ */
4750
4828
  messages: Array<MessageResponse>;
4829
+ /**
4830
+ * List of pinned messages in the channel
4831
+ */
4751
4832
  pinned_messages: Array<MessageResponse>;
4752
4833
  threads: Array<ThreadStateResponse>;
4834
+ /**
4835
+ * Milliseconds until the current user's slow mode cool down period ends. Only set on client-side get or create channel and get channel requests while the user is under cool down
4836
+ */
4837
+ cooldown_remaining_ms?: number;
4838
+ /**
4839
+ * Whether this channel is hidden or not
4840
+ */
4753
4841
  hidden?: boolean;
4842
+ /**
4843
+ * Messages before this date are hidden from the user
4844
+ */
4754
4845
  hide_messages_before?: Date;
4846
+ /**
4847
+ * Number of channel watchers
4848
+ */
4755
4849
  watcher_count?: number;
4850
+ /**
4851
+ * Active live locations in the channel
4852
+ */
4756
4853
  active_live_locations?: Array<SharedLocationResponseData>;
4854
+ /**
4855
+ * Pending messages that this user has sent
4856
+ */
4757
4857
  pending_messages?: Array<PendingMessageResponse>;
4858
+ /**
4859
+ * List of read states
4860
+ */
4758
4861
  read?: Array<ReadStateResponse>;
4862
+ /**
4863
+ * The caller's own scheduled, sending and failed messages in this channel. Set only by a client-side GetOrCreateChannel or QueryChannels with include_scheduled_messages; absent when not requested or not known, in which case use the scheduled messages query
4864
+ */
4865
+ scheduled_messages?: Array<ScheduledMessageResponse>;
4866
+ /**
4867
+ * List of user who is watching the channel
4868
+ */
4759
4869
  watchers?: Array<UserResponse>;
4760
4870
  /**
4761
4871
  * Represents channel in chat
@@ -4782,6 +4892,10 @@ export interface ChannelStateResponseFields {
4782
4892
  */
4783
4893
  pinned_messages: Array<MessageResponse>;
4784
4894
  threads: Array<ThreadStateResponse>;
4895
+ /**
4896
+ * Milliseconds until the current user's slow mode cool down period ends. Only set on client-side get or create channel and get channel requests while the user is under cool down
4897
+ */
4898
+ cooldown_remaining_ms?: number;
4785
4899
  /**
4786
4900
  * Whether this channel is hidden or not
4787
4901
  */
@@ -4806,6 +4920,10 @@ export interface ChannelStateResponseFields {
4806
4920
  * List of read states
4807
4921
  */
4808
4922
  read?: Array<ReadStateResponse>;
4923
+ /**
4924
+ * The caller's own scheduled, sending and failed messages in this channel. Set only by a client-side GetOrCreateChannel or QueryChannels with include_scheduled_messages; absent when not requested or not known, in which case use the scheduled messages query
4925
+ */
4926
+ scheduled_messages?: Array<ScheduledMessageResponse>;
4809
4927
  /**
4810
4928
  * List of user who is watching the channel
4811
4929
  */
@@ -5253,9 +5371,9 @@ export interface CheckPushRequest {
5253
5371
  */
5254
5372
  apn_template?: string;
5255
5373
  /**
5256
- * Type of event for push templates (default: message.new). One of: message.new, message.updated, reaction.new, reaction.updated, notification.reminder_due
5374
+ * Type of event for push templates (default: message.new). One of: message.new, message.updated, reaction.new, reaction.updated, notification.reminder_due, feeds.activity.added, feeds.comment.added, feeds.activity.reaction.added, feeds.comment.reaction.added, feeds.follow.created, feeds.notification_feed.updated
5257
5375
  */
5258
- event_type?: 'message.new' | 'message.updated' | 'reaction.new' | 'reaction.updated' | 'notification.reminder_due';
5376
+ event_type?: 'message.new' | 'message.updated' | 'reaction.new' | 'reaction.updated' | 'notification.reminder_due' | 'feeds.activity.added' | 'feeds.comment.added' | 'feeds.activity.reaction.added' | 'feeds.comment.reaction.added' | 'feeds.follow.created' | 'feeds.notification_feed.updated';
5259
5377
  /**
5260
5378
  * Push message data template for Firebase
5261
5379
  */
@@ -5364,25 +5482,21 @@ export interface CheckResponse {
5364
5482
  */
5365
5483
  status: string;
5366
5484
  /**
5367
- * Intent topic label matched by this request's text (test mode only; omitted when no topic matched)
5368
- */
5369
- intent_matched_topic?: string;
5370
- /**
5371
- * Stage 2 conversation score (0-100) computed synchronously against this request's texts (test mode only). Omitted -- not zero -- when intent_matched_topic is set but scoring could not be completed (matched topic disabled/removed, or the scoring call itself failed); only present when a real score was computed
5485
+ * ID of the LLM model that produced the verdict (e.g. gpt-4o-mini). Omitted when no LLM ran synchronously (e.g. Bodyguard-only checks or async moderation)
5372
5486
  */
5373
- intent_score?: number;
5487
+ llm_model?: string;
5374
5488
  /**
5375
- * The matched topic's configured score_threshold, for comparison against intent_score (test mode only). Same omitted-not-zero rule as intent_score
5489
+ * reasoning_effort sent with the LLM request that produced the verdict. Omitted when the request did not send one
5376
5490
  */
5377
- intent_score_threshold?: number;
5378
- /**
5379
- * Whether intent_score clears intent_score_threshold, i.e. whether this would fire moderation.intent_detected in production (test mode only). Same omitted-not-zero rule as intent_score
5380
- */
5381
- intent_would_fire?: boolean;
5491
+ llm_reasoning_effort?: string;
5382
5492
  /**
5383
5493
  * ID of the running moderation task
5384
5494
  */
5385
5495
  task_id?: string;
5496
+ /**
5497
+ * Score (0-100) of each policy intent topic against this request's text, in policy order (test mode only; omitted when the policy has no topics or scoring failed)
5498
+ */
5499
+ intent_scores?: Array<IntentScoreResponse>;
5386
5500
  /**
5387
5501
  * All moderation rules triggered by this check (content, user, and call rules), with their resolved actions
5388
5502
  */
@@ -5512,6 +5626,14 @@ export interface ClientEvent {
5512
5626
  * Reason the client initiated the join. Optional on CoordinatorJoin events; empty when not provided.
5513
5627
  */
5514
5628
  join_reason?: string;
5629
+ /**
5630
+ * Source of the leave that aborted a join: user, app, callkit, remote_event, sdk_error, or unknown. Not validated against this set, so SDKs may report new values. Optional; sent on failure events. Maximum 32 characters.
5631
+ */
5632
+ leave_initiator?: string;
5633
+ /**
5634
+ * Internal reason or triggering event for the leave that aborted a join. Optional; sent on failure events. Maximum 200 characters.
5635
+ */
5636
+ leave_reason?: string;
5515
5637
  /**
5516
5638
  * Microphone permission status: INITIATED, FAILED, GRANTED, or NOT_INITIATED. Required on every MediaDevicePermission event.
5517
5639
  */
@@ -5977,8 +6099,6 @@ export interface CommentUpdatedEvent {
5977
6099
  received_at?: Date;
5978
6100
  user?: UserResponseCommonFields;
5979
6101
  }
5980
- export interface CommitMessageRequest {
5981
- }
5982
6102
  export interface CompositeRecordingResponse {
5983
6103
  status: string;
5984
6104
  }
@@ -6323,7 +6443,7 @@ export interface CreateChannelTypeRequest {
6323
6443
  /**
6324
6444
  * Partition TTL
6325
6445
  */
6326
- partition_ttl?: string;
6446
+ partition_ttl?: string | null;
6327
6447
  /**
6328
6448
  * Polls
6329
6449
  */
@@ -6336,6 +6456,10 @@ export interface CreateChannelTypeRequest {
6336
6456
  * Push notifications
6337
6457
  */
6338
6458
  push_notifications?: boolean;
6459
+ /**
6460
+ * Enables message quotes
6461
+ */
6462
+ quotes?: boolean;
6339
6463
  /**
6340
6464
  * Reactions
6341
6465
  */
@@ -6344,6 +6468,10 @@ export interface CreateChannelTypeRequest {
6344
6468
  * Read events
6345
6469
  */
6346
6470
  read_events?: boolean;
6471
+ /**
6472
+ * Enables message reminders
6473
+ */
6474
+ reminders?: boolean;
6347
6475
  /**
6348
6476
  * Replies
6349
6477
  */
@@ -6382,11 +6510,15 @@ export interface CreateChannelTypeRequest {
6382
6510
  * List of permissions for the channel type
6383
6511
  */
6384
6512
  permissions?: Array<PolicyRequest>;
6513
+ /**
6514
+ * Sets thresholds for AI moderation
6515
+ */
6516
+ automod_thresholds?: Thresholds;
6385
6517
  chat_preferences?: ChatPreferences;
6386
6518
  /**
6387
6519
  * List of grants for the channel type
6388
6520
  */
6389
- grants?: Record<string, Array<string>>;
6521
+ grants?: Record<string, Array<string>> | null;
6390
6522
  }
6391
6523
  export interface CreateChannelTypeResponse {
6392
6524
  automod: 'disabled' | 'simple' | 'AI';
@@ -6773,6 +6905,14 @@ export interface CreatePollOptionRequest {
6773
6905
  * Option text
6774
6906
  */
6775
6907
  text: string;
6908
+ /**
6909
+ * Key of the moderation configuration to use. Server-side only.
6910
+ */
6911
+ config_key?: string;
6912
+ /**
6913
+ * Team associated with the configuration. Server-side only.
6914
+ */
6915
+ config_team?: string;
6776
6916
  user_id?: string;
6777
6917
  /**
6778
6918
  * Custom data for this object
@@ -6793,6 +6933,14 @@ export interface CreatePollRequest {
6793
6933
  */
6794
6934
  allow_answers?: boolean;
6795
6935
  allow_user_suggested_options?: boolean;
6936
+ /**
6937
+ * Key of the moderation configuration to use. Server-side only.
6938
+ */
6939
+ config_key?: string;
6940
+ /**
6941
+ * Team associated with the configuration. Server-side only.
6942
+ */
6943
+ config_team?: string;
6796
6944
  /**
6797
6945
  * A description of the poll
6798
6946
  */
@@ -7487,6 +7635,28 @@ export interface DeleteModerationRuleResponse {
7487
7635
  export interface DeleteModerationTemplateResponse {
7488
7636
  duration: string;
7489
7637
  }
7638
+ export interface DeletePollAnswerRequestPayload {
7639
+ /**
7640
+ * Reason for deletion
7641
+ */
7642
+ reason?: string;
7643
+ }
7644
+ export interface DeletePollOptionRequestPayload {
7645
+ /**
7646
+ * Option to delete. Required on an item for a whole poll (create or edit); defaults to the option an add_option / update_option item was raised for
7647
+ */
7648
+ option_id?: string;
7649
+ /**
7650
+ * Reason for deletion
7651
+ */
7652
+ reason?: string;
7653
+ }
7654
+ export interface DeletePollRequestPayload {
7655
+ /**
7656
+ * Reason for deletion
7657
+ */
7658
+ reason?: string;
7659
+ }
7490
7660
  export interface DeleteQueueRequest {
7491
7661
  user_id?: string;
7492
7662
  /**
@@ -7550,6 +7720,16 @@ export interface DeleteSIPInboundRoutingRuleResponse {
7550
7720
  export interface DeleteSIPTrunkResponse {
7551
7721
  duration: string;
7552
7722
  }
7723
+ export interface DeleteScheduledMessageResponse {
7724
+ /**
7725
+ * Duration of the request in milliseconds
7726
+ */
7727
+ duration: string;
7728
+ /**
7729
+ * A message scheduled to be sent later
7730
+ */
7731
+ scheduled_message: ScheduledMessageResponse;
7732
+ }
7553
7733
  export interface DeleteSegmentTargetsRequest {
7554
7734
  /**
7555
7735
  * Target IDs
@@ -7641,11 +7821,12 @@ export interface DeleteUsersRequest {
7641
7821
  /**
7642
7822
  * Conversation channels delete mode.
7643
7823
  * Conversation channel is any channel which only has two members one of which is the user being deleted.
7644
- * * null or empty string - doesn't delete any conversation channels
7824
+ * * null or empty string - doesn't delete any conversation channels, unless user is 'hard', in which case it defaults to 'hard'
7645
7825
  * * soft - marks all conversation channels as deleted (same effect as Delete Channels with 'hard' option disabled)
7646
7826
  * * hard - deletes channel and all its data completely including messages (same effect as Delete Channels with 'hard' option enabled)
7827
+ * * keep - doesn't delete any conversation channels. Use it with user 'hard', where null or empty string defaults to 'hard'
7647
7828
  */
7648
- conversations?: 'soft' | 'hard';
7829
+ conversations?: 'soft' | 'hard' | 'keep';
7649
7830
  /**
7650
7831
  * Delete user files.
7651
7832
  * * false or empty string - doesn't delete any files
@@ -7666,7 +7847,7 @@ export interface DeleteUsersRequest {
7666
7847
  * User delete mode.
7667
7848
  * * soft - marks user as deleted and retains all user data
7668
7849
  * * pruning - marks user as deleted and nullifies user information
7669
- * * hard - deletes user completely. Requires 'hard' option for messages and conversations as well
7850
+ * * hard - deletes user completely. Requires 'hard' option for messages, and 'hard' or 'keep' option for conversations
7670
7851
  */
7671
7852
  user?: 'soft' | 'pruning' | 'hard';
7672
7853
  }
@@ -7887,8 +8068,6 @@ export interface EncryptionSettingsResponse {
7887
8068
  */
7888
8069
  mode: 'available' | 'disabled' | 'auto-on';
7889
8070
  }
7890
- export interface EndCallRequest {
7891
- }
7892
8071
  export interface EndCallResponse {
7893
8072
  /**
7894
8073
  * Duration of the request in milliseconds
@@ -7899,6 +8078,7 @@ export interface EnrichedActivity {
7899
8078
  foreign_id?: string;
7900
8079
  id?: string;
7901
8080
  score?: number;
8081
+ time?: string;
7902
8082
  verb?: string;
7903
8083
  to?: Array<string>;
7904
8084
  actor?: Data;
@@ -7943,15 +8123,15 @@ export interface EnrichedReaction {
7943
8123
  activity_id: string;
7944
8124
  kind: string;
7945
8125
  user_id: string;
8126
+ created_at?: string;
7946
8127
  id?: string;
7947
8128
  parent?: string;
8129
+ updated_at?: string;
7948
8130
  target_feeds?: Array<string>;
7949
8131
  children_counts?: Record<string, number>;
7950
- created_at?: Time;
7951
8132
  data?: Record<string, any>;
7952
8133
  latest_children?: Record<string, Array<EnrichedReaction>>;
7953
8134
  own_children?: Record<string, Array<EnrichedReaction>>;
7954
- updated_at?: Time;
7955
8135
  user?: Data;
7956
8136
  }
7957
8137
  export interface EnrichmentOptions {
@@ -7963,6 +8143,10 @@ export interface EnrichmentOptions {
7963
8143
  * Controls the top-level flat 'activities' array for aggregated feeds. For new apps, defaults to false (excluded); set to true to include. For older apps, defaults to true (included) for backward compatibility; set to false to exclude.
7964
8144
  */
7965
8145
  include_flat_activities?: boolean;
8146
+ /**
8147
+ * Default: false. Server-side only. When true, the response includes ranking_config: the ranking configuration (from the feed view, or the feed group as fallback) used to rank this read.
8148
+ */
8149
+ include_ranking_config?: boolean;
7966
8150
  /**
7967
8151
  * Default: false. When true, includes score_vars in activity responses containing variable values used at ranking time.
7968
8152
  */
@@ -8211,8 +8395,6 @@ export interface ExportChannelsResponse {
8211
8395
  */
8212
8396
  task_id: string;
8213
8397
  }
8214
- export interface ExportFeedUserDataRequest {
8215
- }
8216
8398
  export interface ExportFeedUserDataResponse {
8217
8399
  duration: string;
8218
8400
  /**
@@ -8891,6 +9073,7 @@ export interface FeedsNotificationComment {
8891
9073
  comment: string;
8892
9074
  id: string;
8893
9075
  user_id: string;
9076
+ parent_id?: string;
8894
9077
  attachments?: Array<Attachment>;
8895
9078
  }
8896
9079
  export interface FeedsNotificationContext {
@@ -9318,6 +9501,10 @@ export interface FollowBatchRequest {
9318
9501
  * List of follow relationships to create
9319
9502
  */
9320
9503
  follows: Array<FollowRequest>;
9504
+ /**
9505
+ * If true, the batch is queued as a background task, paced per app, and the response has empty follows and a task_id. Server-side only. Supported by the get-or-create endpoint (GetOrCreateFollows); FollowBatch rejects it. Async batches can apply out of order with other follow writes. Defaults to false.
9506
+ */
9507
+ async?: boolean;
9321
9508
  /**
9322
9509
  * If true, auto-creates users referenced by source/target FIDs in the batch when they don't already exist. Server-side only. Defaults to false. This top-level field is the only supported batch/upsert create_users control.
9323
9510
  */
@@ -9337,6 +9524,10 @@ export interface FollowBatchResponse {
9337
9524
  * List of current follow relationships
9338
9525
  */
9339
9526
  follows: Array<FollowResponse>;
9527
+ /**
9528
+ * ID of the background task when the request was sent with async: true
9529
+ */
9530
+ task_id?: string;
9340
9531
  }
9341
9532
  export interface FollowCreatedEvent {
9342
9533
  /**
@@ -10091,6 +10282,16 @@ export interface GetOrCreateCallResponse {
10091
10282
  */
10092
10283
  call: CallResponse;
10093
10284
  }
10285
+ export interface GetOrCreateChannelDefaults {
10286
+ /**
10287
+ * Resolved defaults for a nested pagination object.
10288
+ */
10289
+ members: PagerDefaults;
10290
+ /**
10291
+ * Resolved defaults for a nested pagination object.
10292
+ */
10293
+ messages: PagerDefaults;
10294
+ }
10094
10295
  export interface GetOrCreateFeedGroupRequest {
10095
10296
  /**
10096
10297
  * Role new followers of feeds in this group are given. Either a built-in (feed_follower, feed_member_viewer) or any role your app has defined. Empty means feed_follower. Applied when the follow is accepted, so a follow that starts pending picks it up on approval
@@ -10161,6 +10362,7 @@ export interface GetOrCreateFeedRequest {
10161
10362
  * User request object
10162
10363
  */
10163
10364
  user?: UserRequest;
10365
+ viewer_location?: Location;
10164
10366
  }
10165
10367
  export interface GetOrCreateFeedResponse {
10166
10368
  created: boolean;
@@ -10185,6 +10387,7 @@ export interface GetOrCreateFeedResponse {
10185
10387
  following_pagination?: PagerResponse;
10186
10388
  member_pagination?: PagerResponse;
10187
10389
  notification_status?: NotificationStatusResponse;
10390
+ ranking_config?: RankingConfig;
10188
10391
  }
10189
10392
  export interface GetOrCreateFeedViewRequest {
10190
10393
  /**
@@ -10428,14 +10631,27 @@ export interface GroupedChannelsBucket {
10428
10631
  */
10429
10632
  prev?: string;
10430
10633
  /**
10431
- * Unread channels currently classified into this bucket
10634
+ * Total unread channels matching this bucket and its filters, independent of page size
10432
10635
  */
10433
10636
  unread_channels?: number;
10434
10637
  }
10435
10638
  export interface GroupedChannelsGroupRequest {
10639
+ /**
10640
+ * Max channels for this group; omitted or zero uses the request limit
10641
+ */
10436
10642
  limit?: number;
10643
+ /**
10644
+ * Cursor for the next page; only allowed when requesting one group
10645
+ */
10437
10646
  next?: string;
10647
+ /**
10648
+ * Cursor for the previous page; only allowed when requesting one group
10649
+ */
10438
10650
  prev?: string;
10651
+ /**
10652
+ * Optional query_timestamp $gte bound for a stored group, requiring query_timestamp sort; do not repeat its group name. For all, combine group equality/$in and date bounds with $or, or use one standalone group $ne exclusion. An empty object matches a stored group; omitted or null preserves legacy grouping.
10653
+ */
10654
+ filter_conditions?: Record<string, any>;
10439
10655
  }
10440
10656
  export interface GroupedQueryChannelsRequest {
10441
10657
  /**
@@ -10444,7 +10660,11 @@ export interface GroupedQueryChannelsRequest {
10444
10660
  limit?: number;
10445
10661
  user_id?: string;
10446
10662
  /**
10447
- * Groups to return, keyed by group name. Each group can define limit, next, or prev. 'next' and 'prev' cursors are only allowed when the request contains exactly one group; multi-group pagination is rejected.
10663
+ * Optional query_timestamp descending with NULLS LAST when enabled. Omitted sort preserves existing last_updated ordering and cursor formats
10664
+ */
10665
+ sort?: Array<SortParamRequest>;
10666
+ /**
10667
+ * Groups to return, keyed by stored group name. Each entry can define limit, next, prev, and optional filter_conditions: date bounds for stored groups; all supports combined group/date branches or one group $ne exclusion. Cursors are only allowed when requesting exactly one group. Omitted or null filters preserve legacy grouping, including all.
10448
10668
  */
10449
10669
  groups?: Record<string, GroupedChannelsGroupRequest>;
10450
10670
  /**
@@ -10458,7 +10678,7 @@ export interface GroupedQueryChannelsResponse {
10458
10678
  */
10459
10679
  duration: string;
10460
10680
  /**
10461
- * Predefined channel groups keyed by group name
10681
+ * Groups keyed by the requested stored group name
10462
10682
  */
10463
10683
  groups: Record<string, GroupedChannelsBucket>;
10464
10684
  }
@@ -10865,23 +11085,23 @@ export interface InsertActionLogRequest {
10865
11085
  export interface InsertActionLogResponse {
10866
11086
  duration: string;
10867
11087
  }
10868
- export interface IntentBufferedItem {
11088
+ export interface IntentConditionInfo {
10869
11089
  /**
10870
- * The ID of the user who authored the buffered message or comment
11090
+ * Whether the score reached the threshold.
10871
11091
  */
10872
- author_user_id: string;
11092
+ passed: boolean;
10873
11093
  /**
10874
- * When the buffered message or comment was created
11094
+ * Final (damped) score of the topic in this analysis; 0 when the topic is not defined in the policy.
10875
11095
  */
10876
- created_at: Date;
11096
+ score: number;
10877
11097
  /**
10878
- * The ID of the buffered message or comment
11098
+ * Minimum score (1-100) the condition requires.
10879
11099
  */
10880
- id: string;
11100
+ threshold: number;
10881
11101
  /**
10882
- * The text of the buffered message or comment
11102
+ * Policy intent topic label the condition references.
10883
11103
  */
10884
- text: string;
11104
+ topic: string;
10885
11105
  }
10886
11106
  export interface IntentConfigRequest {
10887
11107
  /**
@@ -10895,99 +11115,55 @@ export interface IntentConfigResponse {
10895
11115
  */
10896
11116
  topics: Array<IntentTopicResponse>;
10897
11117
  }
10898
- export interface IntentDetectedEvent {
11118
+ export interface IntentEvaluationInfo {
10899
11119
  /**
10900
- * The channel CID (chat) or feed ID (feeds) the buffered conversation belongs to
11120
+ * The analyzed conversation: the channel CID for chat, the object ID for feeds.
10901
11121
  */
10902
11122
  conversation_id: string;
10903
- created_at: Date;
10904
11123
  /**
10905
- * The ID of the most recently buffered entity
11124
+ * Number of conversation messages sent to the model.
10906
11125
  */
10907
- entity_id: string;
11126
+ message_count: number;
10908
11127
  /**
10909
- * The type of the most recently buffered entity (chat message or feed comment)
11128
+ * One entry per `intent_rule` condition of the rule, flat conditions first, then group conditions.
10910
11129
  */
10911
- entity_type: string;
11130
+ conditions: Array<IntentConditionInfo>;
10912
11131
  /**
10913
- * The configured intent topic label that started the buffer
11132
+ * Score (0-100) the model gave every topic in the analysis call, keyed by topic label, before message-count damping.
10914
11133
  */
10915
- matched_topic: string;
11134
+ raw_scores: Record<string, number>;
10916
11135
  /**
10917
- * The Stage 2 conversation score (0-100) that cleared score_threshold
11136
+ * Final score (0-100) of every topic after message-count damping, keyed by topic label. Conditions compare against these.
10918
11137
  */
11138
+ scores: Record<string, number>;
11139
+ }
11140
+ export interface IntentRuleParameters {
11141
+ topic: string;
11142
+ threshold?: number;
11143
+ }
11144
+ export interface IntentScoreResponse {
10919
11145
  score: number;
10920
- /**
10921
- * The ID of the user whose conversation was scored
10922
- */
10923
- user_id: string;
10924
- /**
10925
- * The buffered items that were scored, in the order they were captured
10926
- */
10927
- items: Array<IntentBufferedItem>;
10928
- custom: Record<string, any>;
10929
- type: string;
10930
- received_at?: Date;
11146
+ topic: string;
10931
11147
  }
10932
11148
  export interface IntentTopicRequest {
10933
11149
  /**
10934
11150
  * Unique topic label (e.g. purchase_intent)
10935
11151
  */
10936
11152
  label: string;
10937
- /**
10938
- * How long the buffer collects items before scoring runs
10939
- */
10940
- analysis_cooldown_seconds?: number;
10941
11153
  /**
10942
11154
  * Optional description used in the classification prompt; the label alone is used when empty
10943
11155
  */
10944
11156
  description?: string;
10945
- /**
10946
- * Whether this topic is evaluated
10947
- */
10948
- enabled?: boolean;
10949
- /**
10950
- * Items buffered per conversation before scoring runs early
10951
- */
10952
- max_captured_items?: number;
10953
- /**
10954
- * Suppresses this topic for a user and conversation after it fires; 0 uses the default
10955
- */
10956
- refire_cooldown_seconds?: number;
10957
- /**
10958
- * Conversation score (0-100) required to fire moderation.intent_detected
10959
- */
10960
- score_threshold?: number;
10961
11157
  }
10962
11158
  export interface IntentTopicResponse {
10963
- /**
10964
- * How long the buffer collects items before scoring runs
10965
- */
10966
- analysis_cooldown_seconds: number;
10967
- /**
10968
- * Whether this topic is evaluated
10969
- */
10970
- enabled: boolean;
10971
11159
  /**
10972
11160
  * Unique topic label (e.g. purchase_intent)
10973
11161
  */
10974
11162
  label: string;
10975
- /**
10976
- * Items buffered per conversation before scoring runs early
10977
- */
10978
- max_captured_items: number;
10979
- /**
10980
- * Conversation score (0-100) required to fire moderation.intent_detected
10981
- */
10982
- score_threshold: number;
10983
11163
  /**
10984
11164
  * Optional description used in the classification prompt; the label alone is used when empty
10985
11165
  */
10986
11166
  description?: string;
10987
- /**
10988
- * Suppresses this topic for a user and conversation after it fires; 0 uses the default
10989
- */
10990
- refire_cooldown_seconds?: number;
10991
11167
  }
10992
11168
  export interface InterestTagResponse {
10993
11169
  /**
@@ -11073,7 +11249,9 @@ export interface KickedUserEvent {
11073
11249
  export interface LLMConfig {
11074
11250
  app_context?: string;
11075
11251
  async?: boolean;
11252
+ custom_keys_context_description?: string;
11076
11253
  enabled?: boolean;
11254
+ context_custom_keys?: Array<string>;
11077
11255
  rules?: Array<LLMRule>;
11078
11256
  severity_descriptions?: Record<string, string>;
11079
11257
  }
@@ -11248,6 +11426,18 @@ export interface LayoutSettingsResponse {
11248
11426
  detect_orientation?: boolean;
11249
11427
  options?: Record<string, any>;
11250
11428
  }
11429
+ export interface LifecycleSettingsRequest {
11430
+ /**
11431
+ * Call lifecycle mode. One of: reusable, single_use. A single_use call cannot be reused once it has ended; the server ends it when its ring settles without an answer (currently: when the caller cancels the ring). Fixed at call creation
11432
+ */
11433
+ mode?: 'reusable' | 'single_use';
11434
+ }
11435
+ export interface LifecycleSettingsResponse {
11436
+ /**
11437
+ * Call lifecycle mode. One of: reusable, single_use. A single_use call cannot be reused once it has ended; the server ends it when its ring settles without an answer (currently: when the caller cancels the ring). Fixed at call creation
11438
+ */
11439
+ mode: 'reusable' | 'single_use';
11440
+ }
11251
11441
  export interface LimitInfoResponse {
11252
11442
  /**
11253
11443
  * The maximum number of API calls allowed per time window
@@ -12226,7 +12416,7 @@ export interface MessageRequest {
12226
12416
  /**
12227
12417
  * Date when pinned message expires
12228
12418
  */
12229
- pin_expires?: Date;
12419
+ pin_expires?: Date | null;
12230
12420
  /**
12231
12421
  * Whether message is pinned or not
12232
12422
  */
@@ -12234,7 +12424,7 @@ export interface MessageRequest {
12234
12424
  /**
12235
12425
  * Date when message got pinned
12236
12426
  */
12237
- pinned_at?: Date;
12427
+ pinned_at?: Date | null;
12238
12428
  /**
12239
12429
  * Identifier of the poll to include in the message
12240
12430
  */
@@ -13182,6 +13372,7 @@ export interface ModerationRulesTriggeredEvent {
13182
13372
  * Ordered list of contents whose verdicts contributed to an aggregation rule's threshold. Populated only for aggregation rules when callers supplied `content_ids`.
13183
13373
  */
13184
13374
  matched_contents?: Array<MatchedContent>;
13375
+ intent?: IntentEvaluationInfo;
13185
13376
  }
13186
13377
  export interface ModerationTextAnalysisCompleteEvent {
13187
13378
  created_at: Date;
@@ -13306,9 +13497,25 @@ export interface NoiseCancellationSettings {
13306
13497
  mode: 'available' | 'disabled' | 'auto-on';
13307
13498
  }
13308
13499
  export interface NotificationComment {
13500
+ /**
13501
+ * The text of the comment
13502
+ */
13309
13503
  comment: string;
13504
+ /**
13505
+ * The ID of the comment
13506
+ */
13310
13507
  id: string;
13508
+ /**
13509
+ * The ID of the user who wrote the comment
13510
+ */
13311
13511
  user_id: string;
13512
+ /**
13513
+ * The ID of the parent comment when this comment is a reply; omitted for top-level comments
13514
+ */
13515
+ parent_id?: string;
13516
+ /**
13517
+ * Attachments on the comment
13518
+ */
13312
13519
  attachments?: Array<Attachment>;
13313
13520
  }
13314
13521
  export interface NotificationConfig {
@@ -13685,6 +13892,7 @@ export interface OwnUserResponse {
13685
13892
  unread_count: number;
13686
13893
  unread_threads: number;
13687
13894
  updated_at: Date;
13895
+ blocked_user_ids: Array<string>;
13688
13896
  channel_mutes: Array<ChannelMute>;
13689
13897
  devices: Array<DeviceResponse>;
13690
13898
  mutes: Array<UserMuteResponse>;
@@ -13697,7 +13905,6 @@ export interface OwnUserResponse {
13697
13905
  last_active?: Date;
13698
13906
  name?: string;
13699
13907
  revoke_tokens_issued_before?: Date;
13700
- blocked_user_ids?: Array<string>;
13701
13908
  latest_hidden_channels?: Array<string>;
13702
13909
  /**
13703
13910
  * The privacy settings of the user.
@@ -13710,6 +13917,12 @@ export interface OwnUserResponse {
13710
13917
  teams_role?: Record<string, string>;
13711
13918
  total_unread_count_by_team?: Record<string, number>;
13712
13919
  }
13920
+ export interface PagerDefaults {
13921
+ /**
13922
+ * Number of records returned when `limit` is omitted.
13923
+ */
13924
+ limit: number;
13925
+ }
13713
13926
  export interface PagerRequest {
13714
13927
  limit?: number;
13715
13928
  next?: string;
@@ -14149,27 +14362,71 @@ export interface PolicyTestTotals {
14149
14362
  scored: number;
14150
14363
  unscored: number;
14151
14364
  }
14152
- export interface PollOptionInput {
14153
- text?: string;
14154
- custom?: Record<string, any>;
14155
- }
14156
- export interface PollOptionRequest {
14157
- id: string;
14158
- text?: string;
14159
- custom?: Record<string, any>;
14160
- }
14161
- export interface PollOptionResponse {
14365
+ export interface PollClosedEvent {
14162
14366
  /**
14163
- * Duration of the request in milliseconds
14367
+ * Date/time of creation
14164
14368
  */
14165
- duration: string;
14166
- poll_option: PollOptionResponseData;
14167
- }
14168
- export interface PollOptionResponseData {
14169
- id: string;
14170
- text: string;
14369
+ created_at: Date;
14171
14370
  custom: Record<string, any>;
14172
- text_i18n?: Record<string, string>;
14371
+ poll: PollResponseData;
14372
+ /**
14373
+ * The type of event: "poll.closed" in this case
14374
+ */
14375
+ type: string;
14376
+ activity_id?: string;
14377
+ /**
14378
+ * The CID of the channel containing the poll
14379
+ */
14380
+ cid?: string;
14381
+ /**
14382
+ * The ID of the message containing the poll
14383
+ */
14384
+ message_id?: string;
14385
+ received_at?: Date;
14386
+ }
14387
+ export interface PollDeletedEvent {
14388
+ /**
14389
+ * Date/time of creation
14390
+ */
14391
+ created_at: Date;
14392
+ custom: Record<string, any>;
14393
+ poll: PollResponseData;
14394
+ /**
14395
+ * The type of event: "poll.deleted" in this case
14396
+ */
14397
+ type: string;
14398
+ activity_id?: string;
14399
+ /**
14400
+ * The CID of the channel containing the poll
14401
+ */
14402
+ cid?: string;
14403
+ /**
14404
+ * The ID of the message containing the poll
14405
+ */
14406
+ message_id?: string;
14407
+ received_at?: Date;
14408
+ }
14409
+ export interface PollOptionInput {
14410
+ text?: string;
14411
+ custom?: Record<string, any>;
14412
+ }
14413
+ export interface PollOptionRequest {
14414
+ id: string;
14415
+ text?: string;
14416
+ custom?: Record<string, any>;
14417
+ }
14418
+ export interface PollOptionResponse {
14419
+ /**
14420
+ * Duration of the request in milliseconds
14421
+ */
14422
+ duration: string;
14423
+ poll_option: PollOptionResponseData;
14424
+ }
14425
+ export interface PollOptionResponseData {
14426
+ id: string;
14427
+ text: string;
14428
+ custom: Record<string, any>;
14429
+ text_i18n?: Record<string, string>;
14173
14430
  }
14174
14431
  export interface PollResponse {
14175
14432
  /**
@@ -14209,6 +14466,97 @@ export interface PollResponseData {
14209
14466
  description_i18n?: Record<string, string>;
14210
14467
  name_i18n?: Record<string, string>;
14211
14468
  }
14469
+ export interface PollUpdatedEvent {
14470
+ /**
14471
+ * Date/time of creation
14472
+ */
14473
+ created_at: Date;
14474
+ custom: Record<string, any>;
14475
+ poll: PollResponseData;
14476
+ /**
14477
+ * The type of event: "poll.updated" in this case
14478
+ */
14479
+ type: string;
14480
+ activity_id?: string;
14481
+ /**
14482
+ * The CID of the channel containing the poll
14483
+ */
14484
+ cid?: string;
14485
+ /**
14486
+ * The ID of the message containing the poll
14487
+ */
14488
+ message_id?: string;
14489
+ received_at?: Date;
14490
+ }
14491
+ export interface PollVoteCastedEvent {
14492
+ /**
14493
+ * Date/time of creation
14494
+ */
14495
+ created_at: Date;
14496
+ custom: Record<string, any>;
14497
+ poll: PollResponseData;
14498
+ poll_vote: PollVoteResponseData;
14499
+ /**
14500
+ * The type of event: "poll.vote_casted" in this case
14501
+ */
14502
+ type: string;
14503
+ activity_id?: string;
14504
+ /**
14505
+ * The CID of the channel containing the poll
14506
+ */
14507
+ cid?: string;
14508
+ /**
14509
+ * The ID of the message containing the poll
14510
+ */
14511
+ message_id?: string;
14512
+ received_at?: Date;
14513
+ }
14514
+ export interface PollVoteChangedEvent {
14515
+ /**
14516
+ * Date/time of creation
14517
+ */
14518
+ created_at: Date;
14519
+ custom: Record<string, any>;
14520
+ poll: PollResponseData;
14521
+ poll_vote: PollVoteResponseData;
14522
+ /**
14523
+ * The type of event: "poll.vote_changed" in this case
14524
+ */
14525
+ type: string;
14526
+ activity_id?: string;
14527
+ /**
14528
+ * The CID of the channel containing the poll
14529
+ */
14530
+ cid?: string;
14531
+ /**
14532
+ * The ID of the message containing the poll
14533
+ */
14534
+ message_id?: string;
14535
+ received_at?: Date;
14536
+ }
14537
+ export interface PollVoteRemovedEvent {
14538
+ /**
14539
+ * Date/time of creation
14540
+ */
14541
+ created_at: Date;
14542
+ custom: Record<string, any>;
14543
+ poll: PollResponseData;
14544
+ poll_vote: PollVoteResponseData;
14545
+ /**
14546
+ * The type of event: "poll.vote_removed" in this case
14547
+ */
14548
+ type: string;
14549
+ activity_id?: string;
14550
+ /**
14551
+ * The CID of the channel containing the poll
14552
+ */
14553
+ cid?: string;
14554
+ /**
14555
+ * The ID of the message containing the poll
14556
+ */
14557
+ message_id?: string;
14558
+ received_at?: Date;
14559
+ }
14212
14560
  export interface PollVoteResponse {
14213
14561
  /**
14214
14562
  * Duration of the request in milliseconds
@@ -14394,12 +14742,20 @@ export interface PushPreferenceInput {
14394
14742
  * Remove the disabled until time. (IE stop snoozing notifications)
14395
14743
  */
14396
14744
  remove_disable?: boolean;
14745
+ /**
14746
+ * Remove the user's quiet-hours schedule, the counterpart of remove_disable. It is applied before schedule, so sending both in one item replaces the stored schedule instead of merging into it. Cannot be combined with channel_cid. To switch from a schedule to a snooze, send remove_schedule together with disabled_until.
14747
+ */
14748
+ remove_schedule?: boolean;
14397
14749
  /**
14398
14750
  * The user id for which to set the push preferences. Required when using server side auths, defaults to current user with client side auth.
14399
14751
  */
14400
14752
  user_id?: string;
14401
14753
  chat_preferences?: ChatPreferencesInput;
14402
14754
  feeds_preferences?: FeedsPreferences;
14755
+ /**
14756
+ * A recurring quiet-hours schedule: while any quiet window is active, push notifications for the user are suppressed. Suppressed notifications are dropped, not delayed.
14757
+ */
14758
+ schedule?: PushScheduleInput;
14403
14759
  }
14404
14760
  export interface PushPreferencesResponse {
14405
14761
  call_level?: string;
@@ -14414,6 +14770,10 @@ export interface PushPreferencesResponse {
14414
14770
  feeds_level?: string;
14415
14771
  chat_preferences?: ChatPreferencesResponse;
14416
14772
  feeds_preferences?: FeedsPreferencesResponse;
14773
+ /**
14774
+ * A recurring quiet-hours schedule: while any quiet window is active, push notifications for the user are suppressed. Suppressed notifications are dropped, not delayed.
14775
+ */
14776
+ schedule?: PushScheduleResponse;
14417
14777
  }
14418
14778
  export interface PushProvider {
14419
14779
  created_at: Date;
@@ -14501,6 +14861,26 @@ export interface PushProviderResponse {
14501
14861
  xiaomi_app_secret?: string;
14502
14862
  xiaomi_package_name?: string;
14503
14863
  }
14864
+ export interface PushScheduleInput {
14865
+ /**
14866
+ * IANA time zone name the quiet windows are evaluated in, for example Europe/Amsterdam or America/New_York. Daylight saving time is followed automatically for region-based names. Offsets such as +02:00 and the name "Local" are rejected; fixed-offset zones such as UTC or Etc/GMT-2 are accepted but never shift for daylight saving time. When updating an existing schedule, a non-empty timezone replaces the stored one and leaves the stored quiet_hours untouched.
14867
+ */
14868
+ timezone?: string;
14869
+ /**
14870
+ * The quiet windows, 1 to 7 rules. Push is suppressed while any rule is active. When present it replaces all stored rules; omit it to keep them, for example to change only the timezone. An empty array counts as omitted, so it cannot be used to clear the rules: use remove_schedule for that.
14871
+ */
14872
+ quiet_hours?: Array<QuietHoursRuleInput>;
14873
+ }
14874
+ export interface PushScheduleResponse {
14875
+ /**
14876
+ * IANA time zone name the quiet windows are evaluated in, for example Europe/Amsterdam.
14877
+ */
14878
+ timezone: string;
14879
+ /**
14880
+ * The quiet windows. Push is suppressed while any rule is active.
14881
+ */
14882
+ quiet_hours: Array<QuietHoursRuleResponse>;
14883
+ }
14504
14884
  export interface PushTemplate {
14505
14885
  created_at: Date;
14506
14886
  enable_push: boolean;
@@ -15007,7 +15387,68 @@ export interface QueryCampaignsResponse {
15007
15387
  next?: string;
15008
15388
  prev?: string;
15009
15389
  }
15390
+ export interface QueryChannelBansRequest {
15391
+ /**
15392
+ * Whether to exclude expired bans or not
15393
+ */
15394
+ exclude_expired_bans?: boolean;
15395
+ /**
15396
+ * When true, the response includes total and total_by_scope: the number of banned users overall and per scope, independent of paging
15397
+ */
15398
+ include_total?: boolean;
15399
+ limit?: number;
15400
+ next?: string;
15401
+ prev?: string;
15402
+ user_id?: string;
15403
+ /**
15404
+ * Filter conditions to apply to the query
15405
+ */
15406
+ filter_conditions?: Record<string, any>;
15407
+ /**
15408
+ * User request object
15409
+ */
15410
+ user?: UserRequest;
15411
+ }
15412
+ export interface QueryChannelBansResponse {
15413
+ /**
15414
+ * Duration of the request in milliseconds
15415
+ */
15416
+ duration: string;
15417
+ /**
15418
+ * Users banned from the channel, one entry per user, newest ban first
15419
+ */
15420
+ bans: Array<ChannelBanResponse>;
15421
+ next?: string;
15422
+ prev?: string;
15423
+ /**
15424
+ * Number of banned users, each counted once, ignoring paging. Counted per scope with a cap of 100000 each, so it can reach 200000. Only present when include_total is set on the request; omitted when counting timed out
15425
+ */
15426
+ total?: number;
15427
+ total_by_scope?: ChannelBansScopeTotals;
15428
+ }
15429
+ export interface QueryChannelsDefaults {
15430
+ /**
15431
+ * Number of channels returned when `limit` is omitted.
15432
+ */
15433
+ limit: number;
15434
+ /**
15435
+ * Largest number of channels returned for one request. A bigger `limit` is silently clamped to this value rather than rejected. An app with no per-app override gets a higher ceiling for the narrow case of a request asking for at most one message and one member per channel.
15436
+ */
15437
+ max_limit: number;
15438
+ /**
15439
+ * Number of members returned per channel when `member_limit` is omitted.
15440
+ */
15441
+ member_limit: number;
15442
+ /**
15443
+ * Number of messages returned per channel when `message_limit` is omitted.
15444
+ */
15445
+ message_limit: number;
15446
+ }
15010
15447
  export interface QueryChannelsRequest {
15448
+ /**
15449
+ * Whether to include active_member_count for each channel
15450
+ */
15451
+ include_active_member_count?: boolean;
15011
15452
  /**
15012
15453
  * Number of channels to limit
15013
15454
  */
@@ -15292,11 +15733,18 @@ export interface QueryFeedsUsageStatsResponse {
15292
15733
  duration: string;
15293
15734
  activities: DailyMetricStatsResponse;
15294
15735
  api_requests: DailyMetricStatsResponse;
15736
+ collections: DailyMetricStatsResponse;
15737
+ comments: DailyMetricStatsResponse;
15295
15738
  follows: DailyMetricStatsResponse;
15296
15739
  openai_requests: DailyMetricStatsResponse;
15740
+ reactions: DailyMetricStatsResponse;
15297
15741
  emau?: EMAUStatsResponse;
15298
15742
  }
15299
15743
  export interface QueryFollowsRequest {
15744
+ /**
15745
+ * When true (server-side only), the response includes group_counts: accepted following counts keyed by the followed feed's group. Requires exactly one source_feed / source_fid string equality. HTTP 400 if target_feed appears, if two source FIDs are given, or if $in / $or / $nor mentions those keys. Independent of paging and of other filters, including status.
15746
+ */
15747
+ include_group_counts?: boolean;
15300
15748
  limit?: number;
15301
15749
  next?: string;
15302
15750
  prev?: string;
@@ -15323,6 +15771,10 @@ export interface QueryFollowsResponse {
15323
15771
  * Cursor for previous page
15324
15772
  */
15325
15773
  prev?: string;
15774
+ /**
15775
+ * Accepted following counts keyed by followed feed group. Present only when include_group_counts is set with a source_feed equality.
15776
+ */
15777
+ group_counts?: Record<string, number>;
15326
15778
  }
15327
15779
  export interface QueryFutureChannelBansPayload {
15328
15780
  created_at_after?: Date;
@@ -15869,6 +16321,43 @@ export interface QueryRevisionHistoryResponse {
15869
16321
  next?: string;
15870
16322
  prev?: string;
15871
16323
  }
16324
+ export interface QueryScheduledMessagesRequest {
16325
+ /**
16326
+ * Page size, 1 to 100. Defaults to 20
16327
+ */
16328
+ limit?: number;
16329
+ /**
16330
+ * Cursor from the previous page
16331
+ */
16332
+ next?: string;
16333
+ user_id?: string;
16334
+ /**
16335
+ * Only scheduled_at ascending is supported. Pending messages come before failed ones
16336
+ */
16337
+ sort?: Array<SortParamRequest>;
16338
+ /**
16339
+ * Filter for querying scheduled messages
16340
+ */
16341
+ filter?: ScheduledMessagesFilter;
16342
+ /**
16343
+ * User request object
16344
+ */
16345
+ user?: UserRequest;
16346
+ }
16347
+ export interface QueryScheduledMessagesResponse {
16348
+ /**
16349
+ * Duration of the request in milliseconds
16350
+ */
16351
+ duration: string;
16352
+ /**
16353
+ * Pending messages first, then failed ones, each by scheduled_at
16354
+ */
16355
+ scheduled_messages: Array<ScheduledMessageResponse>;
16356
+ /**
16357
+ * Cursor for the next page; empty on the last page
16358
+ */
16359
+ next?: string;
16360
+ }
15872
16361
  export interface QuerySegmentTargetsRequest {
15873
16362
  /**
15874
16363
  * Limit
@@ -16063,6 +16552,34 @@ export interface QueueResponse {
16063
16552
  duration: string;
16064
16553
  queue?: ModerationQueueResponse;
16065
16554
  }
16555
+ export interface QuietHoursRuleInput {
16556
+ /**
16557
+ * When the window closes, as HH:MM local wall-clock time between 00:00 and 24:00. The end is exclusive: a window ending at 07:00 is already over at 07:00. An end earlier than start wraps past midnight into the next day (start 22:00, end 07:00). 24:00 means the end of the day, so start 00:00 with end 24:00 covers the whole day.
16558
+ */
16559
+ end: string;
16560
+ /**
16561
+ * When the window opens, as HH:MM local wall-clock time between 00:00 and 23:59. Must differ from end.
16562
+ */
16563
+ start: string;
16564
+ /**
16565
+ * The days of the week the window opens on, any of mon, tue, wed, thu, fri, sat, sun, each at most once. A window belongs to the day it opens: ["fri"] with 22:00 to 07:00 is quiet from Friday 22:00 until Saturday 07:00, and not on Saturday night. Empty or omitted means every day.
16566
+ */
16567
+ days?: Array<string>;
16568
+ }
16569
+ export interface QuietHoursRuleResponse {
16570
+ /**
16571
+ * When the window closes, as HH:MM local wall-clock time between 00:00 and 24:00. The end is exclusive. An end earlier than start wraps past midnight into the next day.
16572
+ */
16573
+ end: string;
16574
+ /**
16575
+ * When the window opens, as HH:MM local wall-clock time between 00:00 and 23:59.
16576
+ */
16577
+ start: string;
16578
+ /**
16579
+ * The days of the week the window opens on, any of mon, tue, wed, thu, fri, sat, sun. A window belongs to the day it opens: ["fri"] with 22:00 to 07:00 is quiet from Friday 22:00 until Saturday 07:00. Omitted means every day.
16580
+ */
16581
+ days?: Array<string>;
16582
+ }
16066
16583
  export interface RTMPBroadcastRequest {
16067
16584
  /**
16068
16585
  * Name identifier for RTMP broadcast, must be unique in call
@@ -16849,8 +17366,6 @@ export interface RestoreCommentResponse {
16849
17366
  activity: ActivityResponse;
16850
17367
  comment: CommentResponse;
16851
17368
  }
16852
- export interface RestoreFeedGroupRequest {
16853
- }
16854
17369
  export interface RestoreFeedGroupResponse {
16855
17370
  duration: string;
16856
17371
  feed_group: FeedGroupResponse;
@@ -16993,6 +17508,7 @@ export interface ReviewQueueItemResponse {
16993
17508
  * Content payload for moderation
16994
17509
  */
16995
17510
  moderation_payload?: ModerationPayloadResponse;
17511
+ poll?: PollResponseData;
16996
17512
  reaction?: Reaction;
16997
17513
  }
16998
17514
  export interface ReviewQueueItemUpdatedEvent {
@@ -17228,6 +17744,10 @@ export interface RuleBuilderCondition {
17228
17744
  flood_similar_params?: FloodSimilarRuleParameters;
17229
17745
  image_content_params?: ImageContentParameters;
17230
17746
  image_rule_params?: ImageRuleParameters;
17747
+ /**
17748
+ * intent_rule params: policy intent topic label and the minimum final score (1-100) that fires the condition
17749
+ */
17750
+ intent_rule_params?: IntentRuleParameters;
17231
17751
  ip_content_count_rule_params?: IPContentCountRuleParameters;
17232
17752
  ip_flag_count_rule_params?: IPFlagCountRuleParameters;
17233
17753
  keyframe_ocr_rule_params?: KeyframeOCRRuleParameters;
@@ -17235,6 +17755,7 @@ export interface RuleBuilderCondition {
17235
17755
  ocr_content_params?: OCRContentParameters;
17236
17756
  text_content_params?: TextContentParameters;
17237
17757
  text_rule_params?: TextRuleParameters;
17758
+ user_channel_ban_count_params?: UserChannelBanCountRuleParameters;
17238
17759
  user_channel_count_params?: UserChannelCountRuleParameters;
17239
17760
  user_created_within_params?: UserCreatedWithinParameters;
17240
17761
  user_custom_property_params?: UserCustomPropertyParameters;
@@ -17635,6 +18156,221 @@ export interface SIPTrunkResponse {
17635
18156
  export interface SRTIngress {
17636
18157
  address: string;
17637
18158
  }
18159
+ export interface ScheduledMessageChannelResponse {
18160
+ /**
18161
+ * Channel CID (<type>:<id>)
18162
+ */
18163
+ cid: string;
18164
+ /**
18165
+ * Channel ID
18166
+ */
18167
+ id: string;
18168
+ /**
18169
+ * Channel type
18170
+ */
18171
+ type: string;
18172
+ /**
18173
+ * Channel image, from its custom data
18174
+ */
18175
+ image?: string;
18176
+ /**
18177
+ * Channel name, from its custom data
18178
+ */
18179
+ name?: string;
18180
+ }
18181
+ export interface ScheduledMessageContentResponse {
18182
+ /**
18183
+ * Text of the message
18184
+ */
18185
+ text: string;
18186
+ custom: Record<string, any>;
18187
+ /**
18188
+ * Contains HTML markup of the message
18189
+ */
18190
+ html?: string;
18191
+ /**
18192
+ * Whether the message mentions the whole channel
18193
+ */
18194
+ mentioned_channel?: boolean;
18195
+ /**
18196
+ * Whether the message mentions the online channel members
18197
+ */
18198
+ mentioned_here?: boolean;
18199
+ /**
18200
+ * MML content of the message
18201
+ */
18202
+ mml?: string;
18203
+ /**
18204
+ * ID of parent message (thread)
18205
+ */
18206
+ parent_id?: string;
18207
+ /**
18208
+ * Date/time the pin expires
18209
+ */
18210
+ pin_expires?: Date;
18211
+ /**
18212
+ * Whether the message will be pinned when sent
18213
+ */
18214
+ pinned?: boolean;
18215
+ /**
18216
+ * Identifier of the poll to include in the message
18217
+ */
18218
+ poll_id?: string;
18219
+ quoted_message_id?: string;
18220
+ /**
18221
+ * Whether thread reply should be shown in the channel as well
18222
+ */
18223
+ show_in_channel?: boolean;
18224
+ /**
18225
+ * Whether message is silent or not
18226
+ */
18227
+ silent?: boolean;
18228
+ /**
18229
+ * Contains type of the message. One of: regular, system
18230
+ */
18231
+ type?: string;
18232
+ /**
18233
+ * Array of message attachments
18234
+ */
18235
+ attachments?: Array<Attachment>;
18236
+ /**
18237
+ * IDs of the user groups mentioned in the message
18238
+ */
18239
+ mentioned_group_ids?: Array<string>;
18240
+ /**
18241
+ * Roles mentioned in the message
18242
+ */
18243
+ mentioned_roles?: Array<string>;
18244
+ /**
18245
+ * IDs of the users mentioned in the message
18246
+ */
18247
+ mentioned_users?: Array<string>;
18248
+ /**
18249
+ * IDs of the users the message will be visible to
18250
+ */
18251
+ restricted_visibility?: Array<string>;
18252
+ /**
18253
+ * The location a scheduled message will share
18254
+ */
18255
+ shared_location?: ScheduledMessageLocation;
18256
+ }
18257
+ export interface ScheduledMessageFailedEvent {
18258
+ /**
18259
+ * Date/time of creation
18260
+ */
18261
+ created_at: Date;
18262
+ custom: Record<string, any>;
18263
+ user: UserResponseCommonFields;
18264
+ /**
18265
+ * The type of event: "scheduled_message.failed" in this case
18266
+ */
18267
+ type: string;
18268
+ /**
18269
+ * The CID of the channel the message is scheduled in
18270
+ */
18271
+ cid?: string;
18272
+ received_at?: Date;
18273
+ /**
18274
+ * A message scheduled to be sent later
18275
+ */
18276
+ scheduled_message?: ScheduledMessageResponse;
18277
+ }
18278
+ export interface ScheduledMessageLocation {
18279
+ /**
18280
+ * The ID of the device that created the location.
18281
+ */
18282
+ created_by_device_id: string;
18283
+ /**
18284
+ * The date when the location sharing ends.
18285
+ * If it's empty, it means the location sharing is static instead of live.
18286
+ */
18287
+ end_at?: Date;
18288
+ /**
18289
+ * The latitude of the location.
18290
+ */
18291
+ latitude?: number;
18292
+ /**
18293
+ * The longitude of the location.
18294
+ */
18295
+ longitude?: number;
18296
+ }
18297
+ export interface ScheduledMessageResponse {
18298
+ /**
18299
+ * The CID of the channel the message will be sent to
18300
+ */
18301
+ cid: string;
18302
+ /**
18303
+ * Date/time of creation
18304
+ */
18305
+ created_at: Date;
18306
+ /**
18307
+ * Unique identifier of the scheduled message
18308
+ */
18309
+ id: string;
18310
+ /**
18311
+ * Date/time the message is scheduled to be sent
18312
+ */
18313
+ scheduled_at: Date;
18314
+ /**
18315
+ * Status of the scheduled message. One of: scheduled, sending, failed, canceled, sent. A message is sending from its first send attempt until it is sent or fails, including while it waits to retry a failed attempt; it cannot be edited, canceled or sent now while sending
18316
+ */
18317
+ status: string;
18318
+ /**
18319
+ * Date/time of the last update
18320
+ */
18321
+ updated_at: Date;
18322
+ /**
18323
+ * The message a scheduled message will send
18324
+ */
18325
+ message: ScheduledMessageContentResponse;
18326
+ /**
18327
+ * User response object
18328
+ */
18329
+ user: UserResponse;
18330
+ /**
18331
+ * Why sending the message failed. Only set when status is failed. One of: banned, no_permission, channel_frozen, channel_deleted, user_deleted, moderation_blocked, hook_rejected, expired, internal_error, invalid_message, pending_not_supported
18332
+ */
18333
+ failure_reason?: string;
18334
+ /**
18335
+ * The channel of a scheduled message
18336
+ */
18337
+ channel?: ScheduledMessageChannelResponse;
18338
+ }
18339
+ export interface ScheduledMessageSentEvent {
18340
+ /**
18341
+ * Date/time of creation
18342
+ */
18343
+ created_at: Date;
18344
+ /**
18345
+ * The ID of the message that was sent
18346
+ */
18347
+ message_id: string;
18348
+ custom: Record<string, any>;
18349
+ user: UserResponseCommonFields;
18350
+ /**
18351
+ * The type of event: "scheduled_message.sent" in this case
18352
+ */
18353
+ type: string;
18354
+ /**
18355
+ * The CID of the channel the message was sent to
18356
+ */
18357
+ cid?: string;
18358
+ received_at?: Date;
18359
+ /**
18360
+ * A message scheduled to be sent later
18361
+ */
18362
+ scheduled_message?: ScheduledMessageResponse;
18363
+ }
18364
+ export interface ScheduledMessagesFilter {
18365
+ /**
18366
+ * Only scheduled messages of this channel
18367
+ */
18368
+ cid?: string;
18369
+ /**
18370
+ * Only these statuses, as reported in each scheduled message's status. One or more of: scheduled, sending, failed
18371
+ */
18372
+ status?: Array<string>;
18373
+ }
17638
18374
  export interface ScoreBands {
17639
18375
  good?: number;
17640
18376
  ok?: number;
@@ -17898,6 +18634,10 @@ export interface SendMessageRequest {
17898
18634
  include_mentioned_members?: boolean;
17899
18635
  keep_channel_hidden?: boolean;
17900
18636
  pending?: boolean;
18637
+ /**
18638
+ * When set, the message is not sent now: it is stored and sent at this time (UTC). The response then carries scheduled_message. Must be at least 1 minute and at most the app's maximum lead time (120 days by default) from now. Slash commands cannot be scheduled
18639
+ */
18640
+ scheduled_at?: Date;
17901
18641
  skip_enrich_url?: boolean;
17902
18642
  skip_push?: boolean;
17903
18643
  pending_message_metadata?: Record<string, string>;
@@ -17923,6 +18663,10 @@ export interface SendMessageResponse {
17923
18663
  * Pending message metadata
17924
18664
  */
17925
18665
  pending_message_metadata?: Record<string, string>;
18666
+ /**
18667
+ * A message scheduled to be sent later
18668
+ */
18669
+ scheduled_message?: ScheduledMessageResponse;
17926
18670
  }
17927
18671
  export interface SendReactionRequest {
17928
18672
  /**
@@ -17949,6 +18693,16 @@ export interface SendReactionResponse {
17949
18693
  message: MessageResponse;
17950
18694
  reaction: ReactionResponse;
17951
18695
  }
18696
+ export interface SendScheduledMessageNowResponse {
18697
+ /**
18698
+ * Duration of the request in milliseconds
18699
+ */
18700
+ duration: string;
18701
+ /**
18702
+ * A message scheduled to be sent later
18703
+ */
18704
+ scheduled_message: ScheduledMessageResponse;
18705
+ }
17952
18706
  export interface SendUserCustomEventRequest {
17953
18707
  event: UserCustomEventRequest;
17954
18708
  }
@@ -18255,8 +19009,6 @@ export interface StartFrameRecordingResponse {
18255
19009
  */
18256
19010
  duration: string;
18257
19011
  }
18258
- export interface StartHLSBroadcastingRequest {
18259
- }
18260
19012
  export interface StartHLSBroadcastingResponse {
18261
19013
  duration: string;
18262
19014
  /**
@@ -18264,8 +19016,6 @@ export interface StartHLSBroadcastingResponse {
18264
19016
  */
18265
19017
  playlist_url: string;
18266
19018
  }
18267
- export interface StartPolicyTestRunRequest {
18268
- }
18269
19019
  export interface StartRTMPBroadcastsRequest {
18270
19020
  /**
18271
19021
  * List of broadcasts to start
@@ -18307,15 +19057,18 @@ export interface StartTranscriptionResponse {
18307
19057
  */
18308
19058
  duration: string;
18309
19059
  }
18310
- export interface StopAllRTMPBroadcastsRequest {
18311
- }
18312
19060
  export interface StopAllRTMPBroadcastsResponse {
18313
19061
  /**
18314
19062
  * Duration of the request in milliseconds
18315
19063
  */
18316
19064
  duration: string;
18317
19065
  }
18318
- export interface StopCampaignRequest {
19066
+ export interface StopCampaignResponse {
19067
+ /**
19068
+ * Duration of the request in milliseconds
19069
+ */
19070
+ duration: string;
19071
+ campaign?: CampaignResponse;
18319
19072
  }
18320
19073
  export interface StopClosedCaptionsRequest {
18321
19074
  stop_transcription?: boolean;
@@ -18326,16 +19079,12 @@ export interface StopClosedCaptionsResponse {
18326
19079
  */
18327
19080
  duration: string;
18328
19081
  }
18329
- export interface StopFrameRecordingRequest {
18330
- }
18331
19082
  export interface StopFrameRecordingResponse {
18332
19083
  /**
18333
19084
  * Duration of the request in milliseconds
18334
19085
  */
18335
19086
  duration: string;
18336
19087
  }
18337
- export interface StopHLSBroadcastingRequest {
18338
- }
18339
19088
  export interface StopHLSBroadcastingResponse {
18340
19089
  /**
18341
19090
  * Duration of the request in milliseconds
@@ -18422,9 +19171,9 @@ export interface StoriesFeedUpdatedEvent {
18422
19171
  }
18423
19172
  export interface SubmitActionRequest {
18424
19173
  /**
18425
- * Type of moderation action to perform. One of: mark_reviewed, delete_message, delete_activity, delete_comment, delete_reaction, ban, custom, unban, restore, delete_user, delete_user_messages, unblock, block, shadow_block, unmask, kick_user, end_call, escalate, de_escalate
19174
+ * Type of moderation action to perform. One of: mark_reviewed, delete_message, delete_activity, delete_comment, delete_reaction, delete_poll, delete_poll_option, delete_poll_answer, ban, custom, unban, restore, delete_user, delete_user_messages, unblock, block, shadow_block, unmask, kick_user, end_call, escalate, de_escalate
18426
19175
  */
18427
- action_type: 'flag' | 'mark_reviewed' | 'delete_message' | 'delete_activity' | 'delete_comment' | 'delete_reaction' | 'ban' | 'custom' | 'unban' | 'restore' | 'delete_user' | 'delete_user_messages' | 'unblock' | 'block' | 'shadow_block' | 'unmask' | 'kick_user' | 'end_call' | 'reject_appeal' | 'escalate' | 'de_escalate' | 'bypass';
19176
+ action_type: 'flag' | 'mark_reviewed' | 'delete_message' | 'delete_activity' | 'delete_comment' | 'delete_reaction' | 'delete_poll' | 'delete_poll_option' | 'delete_poll_answer' | 'ban' | 'custom' | 'unban' | 'restore' | 'delete_user' | 'delete_user_messages' | 'unblock' | 'block' | 'shadow_block' | 'unmask' | 'kick_user' | 'end_call' | 'reject_appeal' | 'escalate' | 'de_escalate' | 'bypass';
18428
19177
  /**
18429
19178
  * UUID of the appeal to act on (required for reject_appeal, optional for other actions)
18430
19179
  */
@@ -18459,6 +19208,18 @@ export interface SubmitActionRequest {
18459
19208
  * Configuration for message deletion action
18460
19209
  */
18461
19210
  delete_message?: DeleteMessageRequestPayload;
19211
+ /**
19212
+ * Configuration for poll deletion action. Poll deletion is always permanent.
19213
+ */
19214
+ delete_poll?: DeletePollRequestPayload;
19215
+ /**
19216
+ * Configuration for deleting the free-text poll answer a review item was raised for. Chat polls only. Deletion is permanent; the poll and other votes are kept.
19217
+ */
19218
+ delete_poll_answer?: DeletePollAnswerRequestPayload;
19219
+ /**
19220
+ * Configuration for deleting the single poll option a review item was raised for. Deletion is permanent; the rest of the poll is kept.
19221
+ */
19222
+ delete_poll_option?: DeletePollOptionRequestPayload;
18462
19223
  /**
18463
19224
  * Configuration for reaction deletion action
18464
19225
  */
@@ -18912,8 +19673,6 @@ export interface ThumbnailsSettingsRequest {
18912
19673
  export interface ThumbnailsSettingsResponse {
18913
19674
  enabled: boolean;
18914
19675
  }
18915
- export interface Time {
18916
- }
18917
19676
  export interface TimeWindow {
18918
19677
  from: string;
18919
19678
  to: string;
@@ -19216,6 +19975,10 @@ export interface UnfollowBatchRequest {
19216
19975
  * List of follow relationships to remove, each with optional keep_history
19217
19976
  */
19218
19977
  follows: Array<UnfollowPair>;
19978
+ /**
19979
+ * If true, the batch is queued as a background task, paced per app, and the response has empty follows and a task_id. Server-side only. Supported by the get-or-create endpoint (GetOrCreateUnfollows); UnfollowBatch rejects it. Async batches can apply out of order with other follow writes. Defaults to false.
19980
+ */
19981
+ async?: boolean;
19219
19982
  /**
19220
19983
  * Whether to delete the corresponding notification activity (default: false)
19221
19984
  */
@@ -19231,6 +19994,10 @@ export interface UnfollowBatchResponse {
19231
19994
  * List of follow relationships that were removed
19232
19995
  */
19233
19996
  follows: Array<FollowResponse>;
19997
+ /**
19998
+ * ID of the background task when the request was sent with async: true
19999
+ */
20000
+ task_id?: string;
19234
20001
  }
19235
20002
  export interface UnfollowPair {
19236
20003
  /**
@@ -19581,7 +20348,10 @@ export interface UpdateAppRequest {
19581
20348
  reminders_interval?: number;
19582
20349
  reminders_max_members?: number;
19583
20350
  reminders_max_per_user?: number;
19584
- revoke_tokens_issued_before?: Date;
20351
+ /**
20352
+ * Revokes tokens issued before this date
20353
+ */
20354
+ revoke_tokens_issued_before?: Date | null;
19585
20355
  sns_key?: string;
19586
20356
  sns_secret?: string;
19587
20357
  sns_topic_arn?: string;
@@ -19603,7 +20373,7 @@ export interface UpdateAppRequest {
19603
20373
  datadog_info?: DataDogInfo;
19604
20374
  file_upload_config?: FileUploadConfig;
19605
20375
  firebase_config?: FirebaseConfig;
19606
- grants?: Record<string, Array<string>>;
20376
+ grants?: Record<string, Array<string>> | null;
19607
20377
  huawei_config?: HuaweiConfig;
19608
20378
  image_upload_config?: FileUploadConfig;
19609
20379
  moderation_dashboard_preferences?: ModerationDashboardPreferences;
@@ -19763,6 +20533,14 @@ export interface UpdateCampaignRequest {
19763
20533
  user_ids?: Array<string>;
19764
20534
  channel_template?: CampaignChannelTemplate;
19765
20535
  }
20536
+ export interface UpdateCampaignResponse {
20537
+ /**
20538
+ * Duration of the request in milliseconds
20539
+ */
20540
+ duration: string;
20541
+ campaign?: CampaignResponse;
20542
+ users?: PagerResponse;
20543
+ }
19766
20544
  export interface UpdateChannelPartialRequest {
19767
20545
  user_id?: string;
19768
20546
  unset?: Array<string>;
@@ -19873,9 +20651,8 @@ export interface UpdateChannelResponse {
19873
20651
  message?: MessageResponse;
19874
20652
  }
19875
20653
  export interface UpdateChannelTypeRequest {
19876
- automod: 'disabled' | 'simple' | 'AI';
19877
- automod_behavior: 'flag' | 'block' | 'shadow_block';
19878
- max_message_length: number;
20654
+ automod?: 'disabled' | 'simple' | 'AI';
20655
+ automod_behavior?: 'flag' | 'block' | 'shadow_block';
19879
20656
  blocklist?: string;
19880
20657
  blocklist_behavior?: 'flag' | 'block' | 'shadow_block';
19881
20658
  connect_events?: boolean;
@@ -19883,10 +20660,11 @@ export interface UpdateChannelTypeRequest {
19883
20660
  custom_events?: boolean;
19884
20661
  delivery_events?: boolean;
19885
20662
  mark_messages_pending?: boolean;
20663
+ max_message_length?: number;
19886
20664
  message_retention?: string;
19887
20665
  mutes?: boolean;
19888
20666
  partition_size?: number;
19889
- partition_ttl?: string;
20667
+ partition_ttl?: string | null;
19890
20668
  polls?: boolean;
19891
20669
  /**
19892
20670
  * Sets the push notification level for a channel type
@@ -19917,7 +20695,7 @@ export interface UpdateChannelTypeRequest {
19917
20695
  */
19918
20696
  automod_thresholds?: Thresholds;
19919
20697
  chat_preferences?: ChatPreferences;
19920
- grants?: Record<string, Array<string>>;
20698
+ grants?: Record<string, Array<string>> | null;
19921
20699
  }
19922
20700
  export interface UpdateChannelTypeResponse {
19923
20701
  automod: 'disabled' | 'simple' | 'AI';
@@ -20453,6 +21231,14 @@ export interface UpdatePollOptionRequest {
20453
21231
  * Option text
20454
21232
  */
20455
21233
  text: string;
21234
+ /**
21235
+ * Key of the moderation configuration to use. Server-side only.
21236
+ */
21237
+ config_key?: string;
21238
+ /**
21239
+ * Team associated with the configuration. Server-side only.
21240
+ */
21241
+ config_team?: string;
20456
21242
  user_id?: string;
20457
21243
  /**
20458
21244
  * Custom data for this object
@@ -20464,6 +21250,14 @@ export interface UpdatePollOptionRequest {
20464
21250
  user?: UserRequest;
20465
21251
  }
20466
21252
  export interface UpdatePollPartialRequest {
21253
+ /**
21254
+ * Key of the moderation configuration to use. Server-side only.
21255
+ */
21256
+ config_key?: string;
21257
+ /**
21258
+ * Team associated with the configuration. Server-side only.
21259
+ */
21260
+ config_team?: string;
20467
21261
  user_id?: string;
20468
21262
  /**
20469
21263
  * Array of field names to unset
@@ -20495,6 +21289,14 @@ export interface UpdatePollRequest {
20495
21289
  * Allow user suggested options
20496
21290
  */
20497
21291
  allow_user_suggested_options?: boolean;
21292
+ /**
21293
+ * Key of the moderation configuration to use. Server-side only.
21294
+ */
21295
+ config_key?: string;
21296
+ /**
21297
+ * Team associated with the configuration. Server-side only.
21298
+ */
21299
+ config_team?: string;
20498
21300
  /**
20499
21301
  * Poll description
20500
21302
  */
@@ -20648,6 +21450,26 @@ export interface UpdateSIPTrunkResponse {
20648
21450
  */
20649
21451
  sip_trunk?: SIPTrunkResponse;
20650
21452
  }
21453
+ export interface UpdateScheduledMessageRequest {
21454
+ /**
21455
+ * New send time (UTC). Must be at least 1 minute and at most the app's maximum lead time from now
21456
+ */
21457
+ scheduled_at?: Date;
21458
+ /**
21459
+ * Message data for creating or updating a message
21460
+ */
21461
+ message?: MessageRequest;
21462
+ }
21463
+ export interface UpdateScheduledMessageResponse {
21464
+ /**
21465
+ * Duration of the request in milliseconds
21466
+ */
21467
+ duration: string;
21468
+ /**
21469
+ * A message scheduled to be sent later
21470
+ */
21471
+ scheduled_message: ScheduledMessageResponse;
21472
+ }
20651
21473
  export interface UpdateSegmentRequest {
20652
21474
  /**
20653
21475
  * The description of the segment (max 256 characters)
@@ -20884,6 +21706,10 @@ export interface UpsertActivitiesRequest {
20884
21706
  * If true, forces moderation to run for server-side requests. By default, server-side requests skip moderation. Client-side requests always run moderation regardless of this field.
20885
21707
  */
20886
21708
  force_moderation?: boolean;
21709
+ /**
21710
+ * Server-side only. If true, activities whose id already exists are left unchanged instead of updated: no write, events or notifications. They are listed in skipped_existing and returned as stored. Soft-deleted activities count as existing and are returned with deleted_at set. Default: false.
21711
+ */
21712
+ skip_existing?: boolean;
20887
21713
  }
20888
21714
  export interface UpsertActivitiesResponse {
20889
21715
  duration: string;
@@ -20895,6 +21721,10 @@ export interface UpsertActivitiesResponse {
20895
21721
  * Total number of mention notification activities created for mentioned users across all activities
20896
21722
  */
20897
21723
  mention_notifications_created?: number;
21724
+ /**
21725
+ * IDs of activities left unchanged because they already existed. Only set when skip_existing is true.
21726
+ */
21727
+ skipped_existing?: Array<string>;
20898
21728
  }
20899
21729
  export interface UpsertCollectionsRequest {
20900
21730
  /**
@@ -21209,6 +22039,11 @@ export interface UserBannedEvent {
21209
22039
  channel_custom?: Record<string, any>;
21210
22040
  created_by?: UserResponseCommonFields;
21211
22041
  }
22042
+ export interface UserChannelBanCountRuleParameters {
22043
+ banned_by?: string;
22044
+ threshold?: number;
22045
+ time_window?: string;
22046
+ }
21212
22047
  export interface UserChannelCountRuleParameters {
21213
22048
  threshold?: number;
21214
22049
  time_window?: string;
@@ -21828,10 +22663,6 @@ export interface VideoContentParameters {
21828
22663
  label_operator?: string;
21829
22664
  harm_labels?: Array<string>;
21830
22665
  }
21831
- export interface VideoEndCallRequestPayload {
21832
- }
21833
- export interface VideoKickUserRequestPayload {
21834
- }
21835
22666
  export interface VideoReactionOverTimeResponse {
21836
22667
  by_minute?: Array<CountByMinuteResponse>;
21837
22668
  }
@@ -22181,8 +23012,6 @@ export type WHEvent = ({
22181
23012
  } & ModerationFlaggedEvent) | ({
22182
23013
  type: 'moderation.image_analysis.complete';
22183
23014
  } & ModerationImageAnalysisCompleteEvent) | ({
22184
- type: 'moderation.intent_detected';
22185
- } & IntentDetectedEvent) | ({
22186
23015
  type: 'moderation.mark_reviewed';
22187
23016
  } & ModerationMarkReviewedEvent) | ({
22188
23017
  type: 'moderation.text_analysis.complete';
@@ -22197,6 +23026,18 @@ export type WHEvent = ({
22197
23026
  } & ReminderNotificationEvent) | ({
22198
23027
  type: 'notification.thread_message_new';
22199
23028
  } & NotificationThreadMessageNewEvent) | ({
23029
+ type: 'poll.closed';
23030
+ } & PollClosedEvent) | ({
23031
+ type: 'poll.deleted';
23032
+ } & PollDeletedEvent) | ({
23033
+ type: 'poll.updated';
23034
+ } & PollUpdatedEvent) | ({
23035
+ type: 'poll.vote_casted';
23036
+ } & PollVoteCastedEvent) | ({
23037
+ type: 'poll.vote_changed';
23038
+ } & PollVoteChangedEvent) | ({
23039
+ type: 'poll.vote_removed';
23040
+ } & PollVoteRemovedEvent) | ({
22200
23041
  type: 'reaction.deleted';
22201
23042
  } & ReactionDeletedEvent) | ({
22202
23043
  type: 'reaction.new';
@@ -22213,6 +23054,10 @@ export type WHEvent = ({
22213
23054
  } & ReviewQueueItemNewEvent) | ({
22214
23055
  type: 'review_queue_item.updated';
22215
23056
  } & ReviewQueueItemUpdatedEvent) | ({
23057
+ type: 'scheduled_message.failed';
23058
+ } & ScheduledMessageFailedEvent) | ({
23059
+ type: 'scheduled_message.sent';
23060
+ } & ScheduledMessageSentEvent) | ({
22216
23061
  type: 'thread.updated';
22217
23062
  } & ThreadUpdatedEvent) | ({
22218
23063
  type: 'user.banned';