diff --git a/src/gen/chat/ChannelApi.ts b/src/gen/chat/ChannelApi.ts index 7291439..8d793e3 100644 --- a/src/gen/chat/ChannelApi.ts +++ b/src/gen/chat/ChannelApi.ts @@ -42,6 +42,7 @@ export class ChannelApi { delete(request?: { hard_delete?: boolean; + skip_truncate?: boolean; }): Promise> { if (!this.id) { throw new Error( diff --git a/src/gen/chat/ChatApi.ts b/src/gen/chat/ChatApi.ts index a146814..c7b0dee 100644 --- a/src/gen/chat/ChatApi.ts +++ b/src/gen/chat/ChatApi.ts @@ -391,6 +391,8 @@ export class ChatApi { const body = { operation: request?.operation, filter: request?.filter, + hide_history_before: request?.hide_history_before, + synchronous: request?.synchronous, custom_unset: request?.custom_unset, members: request?.members, custom_set: request?.custom_set, @@ -419,6 +421,7 @@ export class ChatApi { const body = { cids: request?.cids, hard_delete: request?.hard_delete, + skip_truncate: request?.skip_truncate, }; const response = await this.apiClient.sendRequest< @@ -551,9 +554,11 @@ export class ChatApi { type: string; id: string; hard_delete?: boolean; + skip_truncate?: boolean; }): Promise> { const queryParams = { hard_delete: request?.hard_delete, + skip_truncate: request?.skip_truncate, }; const pathParams = { type: request?.type, diff --git a/src/gen/common/CommonApi.ts b/src/gen/common/CommonApi.ts index 5103094..1fa27ef 100644 --- a/src/gen/common/CommonApi.ts +++ b/src/gen/common/CommonApi.ts @@ -1257,7 +1257,11 @@ export class CommonApi { async getPollOption(request: { poll_id: string; option_id: string; + user_id?: string; }): Promise> { + const queryParams = { + user_id: request?.user_id, + }; const pathParams = { poll_id: request?.poll_id, option_id: request?.option_id, @@ -1269,7 +1273,7 @@ export class CommonApi { 'GET', '/api/v2/polls/{poll_id}/options/{option_id}', pathParams, - undefined, + queryParams, ); decoders['PollOptionResponse']?.(response.body); @@ -1440,6 +1444,8 @@ export class CommonApi { ios?: boolean; web?: boolean; unity?: boolean; + unity_desktop?: boolean; + unity_console?: boolean; endpoints?: string; }): Promise> { const queryParams = { @@ -1448,6 +1454,8 @@ export class CommonApi { ios: request?.ios, web: request?.web, unity: request?.unity, + unity_desktop: request?.unity_desktop, + unity_console: request?.unity_console, endpoints: request?.endpoints, }; diff --git a/src/gen/feeds/FeedsApi.ts b/src/gen/feeds/FeedsApi.ts index 92fc884..777360b 100644 --- a/src/gen/feeds/FeedsApi.ts +++ b/src/gen/feeds/FeedsApi.ts @@ -54,6 +54,7 @@ import { DeleteFeedViewResponse, DeleteFeedsBatchRequest, DeleteFeedsBatchResponse, + DeleteUserInterestsResponse, ExportFeedUserDataResponse, FollowBatchRequest, FollowBatchResponse, @@ -174,6 +175,8 @@ import { UpsertActivitiesResponse, UpsertCollectionsRequest, UpsertCollectionsResponse, + UpsertUserInterestsRequest, + UpsertUserInterestsResponse, } from '../models'; import { decoders } from '../model-decoders/decoders'; @@ -726,6 +729,7 @@ export class FeedsApi { id: string; comment_sort?: string; comment_limit?: number; + skip_own_followings?: boolean; user_id?: string; language?: string; translate_text?: boolean; @@ -733,6 +737,7 @@ export class FeedsApi { const queryParams = { comment_sort: request?.comment_sort, comment_limit: request?.comment_limit, + skip_own_followings: request?.skip_own_followings, user_id: request?.user_id, language: request?.language, translate_text: request?.translate_text, @@ -1720,6 +1725,7 @@ export class FeedsApi { activity_processors: request?.activity_processors, activity_selectors: request?.activity_selectors, activity_filter: request?.activity_filter, + activity_marks: request?.activity_marks, activity_processing: request?.activity_processing, aggregation: request?.aggregation, custom: request?.custom, @@ -2282,6 +2288,7 @@ export class FeedsApi { activity_processors: request?.activity_processors, activity_selectors: request?.activity_selectors, activity_filter: request?.activity_filter, + activity_marks: request?.activity_marks, activity_processing: request?.activity_processing, aggregation: request?.aggregation, custom: request?.custom, @@ -2319,6 +2326,7 @@ export class FeedsApi { activity_processors: request?.activity_processors, activity_selectors: request?.activity_selectors, activity_filter: request?.activity_filter, + activity_marks: request?.activity_marks, activity_processing: request?.activity_processing, aggregation: request?.aggregation, custom: request?.custom, @@ -2633,6 +2641,8 @@ export class FeedsApi { ios?: boolean; web?: boolean; unity?: boolean; + unity_desktop?: boolean; + unity_console?: boolean; server_side?: boolean; }): Promise> { const queryParams = { @@ -2641,6 +2651,8 @@ export class FeedsApi { ios: request?.ios, web: request?.web, unity: request?.unity, + unity_desktop: request?.unity_desktop, + unity_console: request?.unity_console, server_side: request?.server_side, }; @@ -3184,6 +3196,31 @@ export class FeedsApi { return { ...response.body, metadata: response.metadata }; } + async deleteUserInterests(request: { + user_id: string; + tags: Array; + }): Promise> { + const queryParams = { + tags: request?.tags, + }; + const pathParams = { + user_id: request?.user_id, + }; + + const response = await this.apiClient.sendRequest< + StreamResponse + >( + 'DELETE', + '/api/v2/feeds/users/{user_id}/interests', + pathParams, + queryParams, + ); + + decoders['DeleteUserInterestsResponse']?.(response.body); + + return { ...response.body, metadata: response.metadata }; + } + async getUserInterests(request: { user_id: string; limit?: number; @@ -3208,4 +3245,30 @@ export class FeedsApi { return { ...response.body, metadata: response.metadata }; } + + async upsertUserInterests( + request: UpsertUserInterestsRequest & { user_id: string }, + ): Promise> { + const pathParams = { + user_id: request?.user_id, + }; + const body = { + interests: request?.interests, + }; + + const response = await this.apiClient.sendRequest< + StreamResponse + >( + 'PUT', + '/api/v2/feeds/users/{user_id}/interests', + pathParams, + undefined, + body, + 'application/json', + ); + + decoders['UpsertUserInterestsResponse']?.(response.body); + + return { ...response.body, metadata: response.metadata }; + } } diff --git a/src/gen/models/index.ts b/src/gen/models/index.ts index c8db36d..07707e8 100644 --- a/src/gen/models/index.ts +++ b/src/gen/models/index.ts @@ -49,8 +49,6 @@ export interface AIVideoConfig { enabled?: boolean; - provider?: string; - rules?: Array; } @@ -557,6 +555,18 @@ export interface ActivityMarkEvent { user?: UserResponseCommonFields; } +export interface ActivityMarksConfig { + /** + * Whether to return per-activity read status on content feeds + */ + track_read?: boolean; + + /** + * Whether to return per-activity seen status on content feeds + */ + track_seen?: boolean; +} + export interface ActivityPinResponse { /** * When the pin was created @@ -1953,6 +1963,8 @@ export interface AppResponseFields { auto_translation_enabled: boolean; + before_message_send_hook_system_messages: boolean; + campaign_enabled: boolean; cdn_expiration_seconds: number; @@ -2139,7 +2151,7 @@ export interface AppealItemResponse { ai_text_severity?: string; /** - * CID of the channel the entity belongs to, if applicable + * CID of the channel the entity belongs to (content appeals), or of the channel ban being appealed (stream:user appeals). Empty for a global ban appeal. */ channel_cid?: string; @@ -2233,6 +2245,11 @@ export interface AppealRequest { */ entity_type: string; + /** + * CID of the channel ban being appealed. Only used when entity_type is stream:user; omit to appeal the global ban. + */ + channel_cid?: string; + /** * ID of the review queue item (flagged message) that triggered the ban. Applicable only for user ban appeals. */ @@ -5424,6 +5441,7 @@ export interface ChannelBatchStartedEvent { export interface ChannelBatchUpdateRequest { operation: | 'addMembers' + | 'addMembersHideHistory' | 'removeMembers' | 'inviteMembers' | 'invites' @@ -5441,6 +5459,16 @@ export interface ChannelBatchUpdateRequest { */ filter: Record; + /** + * Required with the `addMembersHideHistory` operation, and rejected with every other operation including `addMembers`. Hides each matched channel's history before this time from the members the operation adds. Members that already belong to a matched channel are never affected. Must be in RFC3339 format (e.g., "2024-01-01T10:00:00Z") and in the past. + */ + hide_history_before?: Date; + + /** + * For updateData only. Requires a root cids $eq or $in filter with at most 100 CIDs and no root $or/$and. Split larger selections into requests of at most 100 CIDs. A success_channels_count response means the database update completed; a task_id response means it was queued and must be polled, including on older API nodes. + */ + synchronous?: boolean; + /** * `updateData` only. Deletes these keys from each channel's existing custom object, leaving every other custom key untouched. Keys are dot-paths; deleting a key that does not exist is a no-op. Cannot be combined with `data.custom` */ @@ -5457,11 +5485,16 @@ export interface ChannelBatchUpdateRequest { } export interface ChannelBatchUpdateResponse { + duration: string; + /** - * Duration of the request in milliseconds + * Positive count of channels selected for a completed synchronous database update, not an affected-row count. Concurrent deletion may reduce the rows written. task_id is absent. */ - duration: string; + success_channels_count?: number; + /** + * Present for asynchronous updates. Poll this task even if synchronous was requested: an older API node may have queued the update. + */ task_id?: string; } @@ -7551,6 +7584,11 @@ export interface ClientEvent { */ sfu_id?: string; + /** + * Source of the coordinator join. Optional on CoordinatorJoin events; omitted when not provided. + */ + source?: string; + /** * Discriminator identifying the event kind. JoinInitiated marks the start of a join attempt; join-lifecycle events use CoordinatorJoin, CoordinatorWS, WSJoin, or PeerConnectionConnect; media-readiness events use FirstAudioFrame or FirstVideoFrame; MediaDevicePermission reports device permission results; other values denote generic client events. */ @@ -8841,6 +8879,8 @@ export interface CreateFeedGroupRequest { activity_filter?: ActivityFilterConfig; + activity_marks?: ActivityMarksConfig; + activity_processing?: ActivityProcessingConfig; aggregation?: AggregationConfig; @@ -9807,9 +9847,14 @@ export interface DeleteChannelsRequest { cids: Array; /** - * Specify if channels and all ressources should be hard deleted + * Server-side only. When true, the channels and all their resources are permanently deleted instead of soft-deleted. */ hard_delete?: boolean; + + /** + * Server-side only. When true, the soft delete preserves message history instead of hiding it, so a later recreation of any of these channel IDs restores the full history. Only supported for distinct channels. Cannot be combined with hard_delete. + */ + skip_truncate?: boolean; } export interface DeleteChannelsResponse { @@ -10106,6 +10151,15 @@ export interface DeleteTranscriptionResponse { duration: string; } +export interface DeleteUserInterestsResponse { + duration: string; + + /** + * Interest tags still set on the user + */ + interests: Array; +} + export interface DeleteUserMessagesRequestPayload { /** * Message deletion mode: soft, pruning, or hard @@ -11249,6 +11303,8 @@ export interface FeedGroupResponse { activity_filter?: ActivityFilterConfig; + activity_marks?: ActivityMarksConfig; + activity_processing?: ActivityProcessingConfig; aggregation?: AggregationConfig; @@ -12536,10 +12592,14 @@ export interface FloodIdenticalConfig { } export interface FloodIdenticalRuleParameters { + min_text_length?: number; + threshold?: number; time_window?: string; + track_across_users?: boolean; + allowlist?: Array; } @@ -13401,6 +13461,16 @@ export interface GetFeedsRateLimitsResponse { */ unity?: Record; + /** + * Rate limits for Unity console platform (endpoint name -> limit info) + */ + unity_console?: Record; + + /** + * Rate limits for Unity desktop platform (endpoint name -> limit info) + */ + unity_desktop?: Record; + /** * Rate limits for Web platform (endpoint name -> limit info) */ @@ -13642,6 +13712,8 @@ export interface GetOrCreateFeedGroupRequest { activity_filter?: ActivityFilterConfig; + activity_marks?: ActivityMarksConfig; + activity_processing?: ActivityProcessingConfig; aggregation?: AggregationConfig; @@ -13882,6 +13954,16 @@ export interface GetRateLimitsResponse { */ unity?: Record; + /** + * Map of endpoint rate limits for the Unity console platform + */ + unity_console?: Record; + + /** + * Map of endpoint rate limits for the Unity desktop platform + */ + unity_desktop?: Record; + /** * Map of endpoint rate limits for the web platform */ @@ -14008,7 +14090,7 @@ export interface GetUserInterestsResponse { duration: string; /** - * Top-N interest tags sorted by descending count, then alphabetically by tag + * Interest tags sorted by descending weight, then manually set tags before computed ones, then descending count, then alphabetically by tag */ interests: Array; } @@ -14702,14 +14784,24 @@ export interface InsertActionLogResponse { export interface InterestTagResponse { /** - * Number of distinct reacted-to activities tagged with this value + * Lifetime number of distinct reacted-to activities tagged with this value, without decay; 0 for manually set tags */ count: number; + /** + * How the tag was set: computed (from the user's reactions) or manual (through the API) + */ + source: string; + /** * The interest tag value */ tag: string; + + /** + * Ranking weight between -1.0 and 1.0. Computed tags carry a recency-decayed weight in (0, 1.0]: the user's strongest tag is 1.0 and every other a proportional share + */ + weight: number; } export interface JoinCallAPIMetrics { @@ -14953,7 +15045,7 @@ export interface LabelsRequest { dry_run?: boolean; /** - * Optional moderation policy key (max 128 chars). For username moderation, set this to a policy whose key starts with 'username:' (e.g. 'username:default') to opt into the low-latency fast-path: blocklists (customer + Stream-managed defaults) short-circuit the LLM, and the LLM fallback uses gpt-4.1-nano with a 24h Valkey verdict cache. Without a 'username:' prefix the request falls through to the standard Bodyguard Analyze v1 username path. + * Optional moderation policy key (max 128 chars). For username moderation, set this to a policy whose key starts with 'username:' (e.g. 'username:default') to opt into the low-latency fast-path: blocklists (customer + Stream-managed defaults) short-circuit the LLM, and the LLM fallback uses gpt-4o-mini (overridable via moderation_settings.llm_username_model) with a 24h Valkey verdict cache. Without a 'username:' prefix the request falls through to the standard Bodyguard Analyze v1 username path. */ policy?: string; @@ -17283,6 +17375,8 @@ export interface ModerationDashboardPreferences { custom_views_enabled?: boolean; + disable_action_logs?: boolean; + disable_audit_logs?: boolean; disable_flagging_reviewed_entity?: boolean; @@ -18386,6 +18480,14 @@ export interface PagerResponse { } export interface PaginationParams { + id_gt?: number; + + id_gte?: number; + + id_lt?: number; + + id_lte?: number; + limit?: number; offset?: number; @@ -19829,6 +19931,14 @@ export interface QueryBannedUsersPayload { */ filter_conditions: Record; + created_at_after?: Date; + + created_at_after_or_equal?: Date; + + created_at_before?: Date; + + created_at_before_or_equal?: Date; + /** * Whether to exclude expired bans or not */ @@ -20660,6 +20770,14 @@ export interface QueryFollowsResponse { } export interface QueryFutureChannelBansPayload { + created_at_after?: Date; + + created_at_after_or_equal?: Date; + + created_at_before?: Date; + + created_at_before_or_equal?: Date; + /** * Whether to exclude expired bans or not */ @@ -20751,6 +20869,14 @@ export interface QueryLabelResultsResponse { export interface QueryMembersPayload { type: string; + created_at_after?: Date; + + created_at_after_or_equal?: Date; + + created_at_before?: Date; + + created_at_before_or_equal?: Date; + id?: string; limit?: number; @@ -20759,6 +20885,14 @@ export interface QueryMembersPayload { user_id?: string; + user_id_gt?: string; + + user_id_gte?: string; + + user_id_lt?: string; + + user_id_lte?: string; + members?: Array; /** @@ -21571,6 +21705,14 @@ export interface QueryUsersPayload { */ filter_conditions: Record; + id_gt?: string; + + id_gte?: string; + + id_lt?: string; + + id_lte?: string; + include_deactivated_users?: boolean; limit?: number; @@ -22822,6 +22964,11 @@ export interface ReviewQueueItemResponse { */ completed_at?: Date; + /** + * Highest per-label confidence (0-1) any provider reported across the item's flags; absent when no flag carried one + */ + confidence_score?: number; + config_key?: string; /** @@ -23084,6 +23231,10 @@ export interface RuleBuilderCondition { user_identical_content_count_params?: UserIdenticalContentCountParameters; + user_identical_image_count_params?: UserIdenticalImageCountParameters; + + user_reaction_count_params?: UserReactionCountRuleParameters; + user_role_params?: UserRoleParameters; user_rule_params?: UserRuleParameters; @@ -23124,6 +23275,8 @@ export interface RuleBuilderRule { } export interface RunStats { + activities_deleted?: number; + channels_deleted?: number; messages_deleted?: number; @@ -27271,6 +27424,8 @@ export interface UpdateFeedGroupRequest { activity_filter?: ActivityFilterConfig; + activity_marks?: ActivityMarksConfig; + activity_processing?: ActivityProcessingConfig; aggregation?: AggregationConfig; @@ -28538,6 +28693,22 @@ export interface UpsertSetupSessionResponse { setup_session?: SetupSession; } +export interface UpsertUserInterestsRequest { + /** + * Interest tags to add or update (1-50) + */ + interests: Array; +} + +export interface UpsertUserInterestsResponse { + duration: string; + + /** + * All interest tags of the user after the write + */ + interests: Array; +} + export interface User { id: string; @@ -28925,6 +29096,28 @@ export interface UserIdenticalContentCountParameters { time_window?: string; } +export interface UserIdenticalImageCountParameters { + match?: string; + + similarity_distance?: number; + + threshold?: number; + + time_window?: string; +} + +export interface UserInterestRequest { + /** + * The interest tag; trimmed and lower-cased like activity interest_tags + */ + tag: string; + + /** + * Ranking weight between -1.0 (dislike) and 1.0 (like). Defaults to 1.0 + */ + weight?: number; +} + export interface UserMessagesDeletedEvent { /** * Date/time of creation @@ -29023,6 +29216,14 @@ export interface UserRatingReportResponse { count: number; } +export interface UserReactionCountRuleParameters { + count?: string; + + threshold?: number; + + time_window?: string; +} + export interface UserReactivatedEvent { /** * Date/time of creation @@ -29838,6 +30039,18 @@ export interface WebhookFailoverConfig { gcs_path?: string; + s3_api_key?: string; + + s3_bucket?: string; + + s3_path?: string; + + s3_region?: string; + + s3_role_arn?: string; + + s3_secret?: string; + type?: string; } diff --git a/src/gen/moderation/ModerationApi.ts b/src/gen/moderation/ModerationApi.ts index c85f461..a43d62c 100644 --- a/src/gen/moderation/ModerationApi.ts +++ b/src/gen/moderation/ModerationApi.ts @@ -292,6 +292,7 @@ export class ModerationApi { appeal_reason: request?.appeal_reason, entity_id: request?.entity_id, entity_type: request?.entity_type, + channel_cid: request?.channel_cid, review_queue_item_id: request?.review_queue_item_id, user_id: request?.user_id, attachments: request?.attachments,