@stream-io/feeds-client 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/@react-bindings/index.ts +1 -0
- package/CHANGELOG.md +13 -0
- package/dist/@react-bindings/hooks/useOwnCapabilities.d.ts +33 -0
- package/dist/@react-bindings/index.d.ts +1 -0
- package/dist/index-react-bindings.browser.cjs +74 -0
- package/dist/index-react-bindings.browser.cjs.map +1 -1
- package/dist/index-react-bindings.browser.js +74 -1
- package/dist/index-react-bindings.browser.js.map +1 -1
- package/dist/index-react-bindings.node.cjs +74 -0
- package/dist/index-react-bindings.node.cjs.map +1 -1
- package/dist/index-react-bindings.node.js +74 -1
- package/dist/index-react-bindings.node.js.map +1 -1
- package/dist/index.browser.cjs +3 -0
- package/dist/index.browser.cjs.map +1 -1
- package/dist/index.browser.js +3 -0
- package/dist/index.browser.js.map +1 -1
- package/dist/index.node.cjs +3 -0
- package/dist/index.node.cjs.map +1 -1
- package/dist/index.node.js +3 -0
- package/dist/index.node.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/Feed.ts +3 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-react-bindings.node.cjs","sources":["../../@react-bindings/hooks/useStateStore.ts","../../@react-bindings/hooks/useComments.ts"],"sourcesContent":["import { useCallback, useMemo, useSyncExternalStore } from 'react';\nimport type { StateStore } from '../../src/common/StateStore';\n\nconst noop = () => {};\n\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T>, selector: (v: T) => O): O;\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T> | undefined, selector: (v: T) => O): O | undefined;\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T> | undefined, selector: (v: T) => O) {\n const wrappedSubscription = useCallback(\n (onStoreChange: () => void) => {\n const unsubscribe = store?.subscribeWithSelector(selector, onStoreChange);\n return unsubscribe ?? noop;\n },\n [store, selector],\n );\n\n const wrappedSnapshot = useMemo(() => {\n let cachedTuple: [T, O];\n\n return () => {\n const currentValue = store?.getLatestValue();\n\n if (!currentValue) return undefined;\n\n // store value hasn't changed, no need to compare individual values\n if (cachedTuple && cachedTuple[0] === currentValue) {\n return cachedTuple[1];\n }\n\n const newlySelected = selector(currentValue);\n\n // store value changed but selected values wouldn't have to, double-check selected\n if (cachedTuple) {\n let selectededAreEqualToCached = true;\n\n for (const key in cachedTuple[1]) {\n if (cachedTuple[1][key] === newlySelected[key]) continue;\n selectededAreEqualToCached = false;\n break;\n }\n\n if (selectededAreEqualToCached) return cachedTuple[1];\n }\n\n cachedTuple = [currentValue, newlySelected];\n return cachedTuple[1];\n };\n }, [store, selector]);\n\n const state = useSyncExternalStore(wrappedSubscription, wrappedSnapshot);\n\n return state;\n}\n","import { useCallback } from 'react';\nimport type {\n ActivityResponse,\n CommentResponse,\n} from '../../src/gen/models';\nimport type {\n Feed,\n FeedState\n} from '../../src/Feed';\nimport { useStateStore } from './useStateStore';\n\nexport const useComments = (\n feed: Feed,\n /**\n * The parent (activity or comment) for which to fetch comments.\n */\n parent: ActivityResponse | CommentResponse,\n) => {\n const selector = useCallback(\n (state: FeedState) => ({\n comments: state.comments_by_entity_id?.[parent.id]?.comments ?? [],\n comment_pagination: state.comments_by_entity_id?.[parent.id]?.pagination,\n }),\n [parent.id],\n );\n\n return useStateStore(feed.state, selector);\n};\n"],"names":["useCallback","useMemo","useSyncExternalStore"],"mappings":";;;;AAGA,MAAM,IAAI,GAAG,MAAK,GAAG,CAAC;AAUN,SAAA,aAAa,CAG3B,KAAgC,EAAE,QAAqB,EAAA;AACvD,IAAA,MAAM,mBAAmB,GAAGA,iBAAW,CACrC,CAAC,aAAyB,KAAI;QAC5B,MAAM,WAAW,G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ClDO,MAAM,WAAW,GAAG,CACzB,IAAU;AACV;;AAEG;AACH,MAA0C,KACxC;IACF,MAAM,QAAQ,GAAGF,iBAAW,CAC1B,CAAC,KAAgB,MAAM;AACrB,QAAA,QAAQ,EAAE,KAAK,CAAC,qBAAqB,GAAG,MAAM,CAAC,EAAE,CAAC,EAAE,QAAQ,IAAI,EAAE;QAClE,kBAAkB,EAAE,KAAK,CAAC,qBAAqB,GAAG,MAAM,CAAC,EAAE,CAAC,EAAE,UAAU;AACzE,KAAA,CAAC,EACF,CAAC,MAAM,CAAC,EAAE,CAAC,CACZ,CAAC;IAEF,OAAO,aAAa,CAAC,IAAI,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;AAC7C;;;;;"}
|
|
1
|
+
{"version":3,"file":"index-react-bindings.node.cjs","sources":["../../@react-bindings/hooks/useStateStore.ts","../../@react-bindings/hooks/useComments.ts","../../src/gen/models/index.ts","../../@react-bindings/hooks/useOwnCapabilities.ts"],"sourcesContent":["import { useCallback, useMemo, useSyncExternalStore } from 'react';\nimport type { StateStore } from '../../src/common/StateStore';\n\nconst noop = () => {};\n\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T>, selector: (v: T) => O): O;\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T> | undefined, selector: (v: T) => O): O | undefined;\nexport function useStateStore<\n T extends Record<string, unknown>,\n O extends Readonly<Record<string, unknown> | readonly unknown[]>,\n>(store: StateStore<T> | undefined, selector: (v: T) => O) {\n const wrappedSubscription = useCallback(\n (onStoreChange: () => void) => {\n const unsubscribe = store?.subscribeWithSelector(selector, onStoreChange);\n return unsubscribe ?? noop;\n },\n [store, selector],\n );\n\n const wrappedSnapshot = useMemo(() => {\n let cachedTuple: [T, O];\n\n return () => {\n const currentValue = store?.getLatestValue();\n\n if (!currentValue) return undefined;\n\n // store value hasn't changed, no need to compare individual values\n if (cachedTuple && cachedTuple[0] === currentValue) {\n return cachedTuple[1];\n }\n\n const newlySelected = selector(currentValue);\n\n // store value changed but selected values wouldn't have to, double-check selected\n if (cachedTuple) {\n let selectededAreEqualToCached = true;\n\n for (const key in cachedTuple[1]) {\n if (cachedTuple[1][key] === newlySelected[key]) continue;\n selectededAreEqualToCached = false;\n break;\n }\n\n if (selectededAreEqualToCached) return cachedTuple[1];\n }\n\n cachedTuple = [currentValue, newlySelected];\n return cachedTuple[1];\n };\n }, [store, selector]);\n\n const state = useSyncExternalStore(wrappedSubscription, wrappedSnapshot);\n\n return state;\n}\n","import { useCallback } from 'react';\nimport type {\n ActivityResponse,\n CommentResponse,\n} from '../../src/gen/models';\nimport type {\n Feed,\n FeedState\n} from '../../src/Feed';\nimport { useStateStore } from './useStateStore';\n\nexport const useComments = (\n feed: Feed,\n /**\n * The parent (activity or comment) for which to fetch comments.\n */\n parent: ActivityResponse | CommentResponse,\n) => {\n const selector = useCallback(\n (state: FeedState) => ({\n comments: state.comments_by_entity_id?.[parent.id]?.comments ?? [],\n comment_pagination: state.comments_by_entity_id?.[parent.id]?.pagination,\n }),\n [parent.id],\n );\n\n return useStateStore(feed.state, selector);\n};\n","export interface AIImageConfig {\n enabled: boolean;\n\n ocr_rules: OCRRule[];\n\n rules: AWSRekognitionRule[];\n\n async?: boolean;\n}\n\nexport interface AITextConfig {\n enabled: boolean;\n\n profile: string;\n\n rules: BodyguardRule[];\n\n severity_rules: BodyguardSeverityRule[];\n\n async?: boolean;\n}\n\nexport interface AIVideoConfig {\n enabled: boolean;\n\n rules: AWSRekognitionRule[];\n\n async?: boolean;\n}\n\nexport interface APIError {\n code: number;\n\n duration: string;\n\n message: string;\n\n more_info: string;\n\n status_code: number;\n\n details: number[];\n\n unrecoverable?: boolean;\n\n exception_fields?: Record<string, string>;\n}\n\nexport interface APNS {\n body: string;\n\n title: string;\n\n content_available?: number;\n\n mutable_content?: number;\n\n sound?: string;\n\n data?: Record<string, any>;\n}\n\nexport interface AWSRekognitionRule {\n action:\n | 'flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n label: string;\n\n min_confidence: number;\n}\n\nexport interface AcceptFeedMemberInviteRequest {}\n\nexport interface AcceptFeedMemberInviteResponse {\n duration: string;\n\n member: FeedMemberResponse;\n}\n\nexport interface AcceptFollowRequest {\n source_fid: string;\n\n target_fid: string;\n\n follower_role?: string;\n}\n\nexport interface AcceptFollowResponse {\n duration: string;\n\n follow: FollowResponse;\n}\n\nexport interface Action {\n name: string;\n\n text: string;\n\n type: string;\n\n style?: string;\n\n value?: string;\n}\n\nexport interface ActionLog {\n created_at: Date;\n\n id: string;\n\n reason: string;\n\n reporter_type: string;\n\n review_queue_item_id: string;\n\n target_user_id: string;\n\n type: string;\n\n custom: Record<string, any>;\n\n review_queue_item?: ReviewQueueItem;\n\n target_user?: User;\n\n user?: User;\n}\n\nexport interface ActionLogResponse {\n created_at: Date;\n\n id: string;\n\n reason: string;\n\n target_user_id: string;\n\n type: string;\n\n user_id: string;\n\n custom: Record<string, any>;\n\n review_queue_item?: ReviewQueueItemResponse;\n\n target_user?: UserResponse;\n\n user?: UserResponse;\n}\n\nexport interface ActionSequence {\n action: string;\n\n blur: boolean;\n\n cooldown_period: number;\n\n threshold: number;\n\n time_window: number;\n\n warning: boolean;\n\n warning_text: string;\n}\n\nexport interface ActivityAddedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityLocation {\n lat: number;\n\n lng: number;\n}\n\nexport interface ActivityMarkEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n type: string;\n\n mark_all_read?: boolean;\n\n mark_all_seen?: boolean;\n\n received_at?: Date;\n\n mark_read?: string[];\n\n mark_watched?: string[];\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityPinResponse {\n created_at: Date;\n\n feed: string;\n\n updated_at: Date;\n\n activity: ActivityResponse;\n\n user: UserResponse;\n}\n\nexport interface ActivityPinnedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n pinned_activity: PinActivityResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityReactionAddedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityReactionDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityReactionUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityRemovedFromFeedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityRequest {\n type: string;\n\n fids: string[];\n\n expires_at?: string;\n\n id?: string;\n\n parent_id?: string;\n\n poll_id?: string;\n\n text?: string;\n\n visibility?: 'public' | 'private' | 'tag';\n\n visibility_tag?: string;\n\n attachments?: Attachment[];\n\n filter_tags?: string[];\n\n interest_tags?: string[];\n\n mentioned_user_ids?: string[];\n\n custom?: Record<string, any>;\n\n location?: ActivityLocation;\n\n search_data?: Record<string, any>;\n}\n\nexport interface ActivityResponse {\n bookmark_count: number;\n\n comment_count: number;\n\n created_at: Date;\n\n id: string;\n\n popularity: number;\n\n score: number;\n\n share_count: number;\n\n type: string;\n\n updated_at: Date;\n\n visibility: 'public' | 'private' | 'tag';\n\n attachments: Attachment[];\n\n comments: CommentResponse[];\n\n feeds: string[];\n\n filter_tags: string[];\n\n interest_tags: string[];\n\n latest_reactions: FeedsReactionResponse[];\n\n mentioned_users: UserResponse[];\n\n own_bookmarks: BookmarkResponse[];\n\n own_reactions: FeedsReactionResponse[];\n\n custom: Record<string, any>;\n\n reaction_groups: Record<string, ReactionGroupResponse>;\n\n search_data: Record<string, any>;\n\n user: UserResponse;\n\n deleted_at?: Date;\n\n edited_at?: Date;\n\n expires_at?: Date;\n\n text?: string;\n\n visibility_tag?: string;\n\n current_feed?: FeedResponse;\n\n location?: ActivityLocation;\n\n moderation?: ModerationV2Response;\n\n parent?: ActivityResponse;\n\n poll?: PollResponseData;\n}\n\nexport interface ActivityUnpinnedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n pinned_activity: PinActivityResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface ActivityUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n activity: ActivityResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface AddActivityRequest {\n type: string;\n\n fids: string[];\n\n expires_at?: string;\n\n id?: string;\n\n parent_id?: string;\n\n poll_id?: string;\n\n text?: string;\n\n visibility?: 'public' | 'private' | 'tag';\n\n visibility_tag?: string;\n\n attachments?: Attachment[];\n\n filter_tags?: string[];\n\n interest_tags?: string[];\n\n mentioned_user_ids?: string[];\n\n custom?: Record<string, any>;\n\n location?: ActivityLocation;\n\n search_data?: Record<string, any>;\n}\n\nexport interface AddActivityResponse {\n duration: string;\n\n activity: ActivityResponse;\n}\n\nexport interface AddBookmarkRequest {\n folder_id?: string;\n\n custom?: Record<string, any>;\n\n new_folder?: AddFolderRequest;\n}\n\nexport interface AddBookmarkResponse {\n duration: string;\n\n bookmark: BookmarkResponse;\n}\n\nexport interface AddCommentReactionRequest {\n type: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface AddCommentReactionResponse {\n duration: string;\n\n comment: CommentResponse;\n\n reaction: FeedsReactionResponse;\n}\n\nexport interface AddCommentRequest {\n comment: string;\n\n object_id: string;\n\n object_type: string;\n\n parent_id?: string;\n\n attachments?: Attachment[];\n\n mentioned_user_ids?: string[];\n\n custom?: Record<string, any>;\n}\n\nexport interface AddCommentResponse {\n duration: string;\n\n comment: CommentResponse;\n}\n\nexport interface AddCommentsBatchRequest {\n comments: AddCommentRequest[];\n}\n\nexport interface AddCommentsBatchResponse {\n duration: string;\n\n comments: CommentResponse[];\n}\n\nexport interface AddFolderRequest {\n name: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface AddReactionRequest {\n type: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface AddReactionResponse {\n duration: string;\n\n activity: ActivityResponse;\n\n reaction: FeedsReactionResponse;\n}\n\nexport interface AggregatedActivityResponse {\n activity_count: number;\n\n created_at: Date;\n\n group: string;\n\n score: number;\n\n updated_at: Date;\n\n user_count: number;\n\n activities: ActivityResponse[];\n}\n\nexport interface AppEventResponse {\n auto_translation_enabled: boolean;\n\n name: string;\n\n async_url_enrich_enabled?: boolean;\n\n file_upload_config?: FileUploadConfig;\n\n image_upload_config?: FileUploadConfig;\n}\n\nexport interface AppResponseFields {\n async_url_enrich_enabled: boolean;\n\n auto_translation_enabled: boolean;\n\n name: string;\n\n file_upload_config: FileUploadConfig;\n\n image_upload_config: FileUploadConfig;\n}\n\nexport interface AppUpdatedEvent {\n created_at: Date;\n\n app: AppEventResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface Attachment {\n custom: Record<string, any>;\n\n asset_url?: string;\n\n author_icon?: string;\n\n author_link?: string;\n\n author_name?: string;\n\n color?: string;\n\n fallback?: string;\n\n footer?: string;\n\n footer_icon?: string;\n\n image_url?: string;\n\n og_scrape_url?: string;\n\n original_height?: number;\n\n original_width?: number;\n\n pretext?: string;\n\n text?: string;\n\n thumb_url?: string;\n\n title?: string;\n\n title_link?: string;\n\n type?: string;\n\n actions?: Action[];\n\n fields?: Field[];\n\n giphy?: Images;\n}\n\nexport interface AudioSettings {\n access_request_enabled: boolean;\n\n default_device: 'speaker' | 'earpiece';\n\n mic_default_on: boolean;\n\n opus_dtx_enabled: boolean;\n\n redundant_coding_enabled: boolean;\n\n speaker_default_on: boolean;\n\n noise_cancellation?: NoiseCancellationSettings;\n}\n\nexport interface AudioSettingsResponse {\n access_request_enabled: boolean;\n\n default_device: 'speaker' | 'earpiece';\n\n mic_default_on: boolean;\n\n opus_dtx_enabled: boolean;\n\n redundant_coding_enabled: boolean;\n\n speaker_default_on: boolean;\n\n noise_cancellation?: NoiseCancellationSettings;\n}\n\nexport interface AutomodPlatformCircumventionConfig {\n enabled: boolean;\n\n rules: AutomodRule[];\n\n async?: boolean;\n}\n\nexport interface AutomodRule {\n action:\n | 'flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n label: string;\n\n threshold: number;\n}\n\nexport interface AutomodSemanticFiltersConfig {\n enabled: boolean;\n\n rules: AutomodSemanticFiltersRule[];\n\n async?: boolean;\n}\n\nexport interface AutomodSemanticFiltersRule {\n action: 'flag' | 'shadow' | 'remove';\n\n name: string;\n\n threshold: number;\n}\n\nexport interface AutomodToxicityConfig {\n enabled: boolean;\n\n rules: AutomodRule[];\n\n async?: boolean;\n}\n\nexport interface BackstageSettings {\n enabled: boolean;\n\n join_ahead_time_seconds?: number;\n}\n\nexport interface BackstageSettingsResponse {\n enabled: boolean;\n\n join_ahead_time_seconds?: number;\n}\n\nexport interface Ban {\n created_at: Date;\n\n shadow: boolean;\n\n expires?: Date;\n\n reason?: string;\n\n channel?: Channel;\n\n created_by?: User;\n\n target?: User;\n}\n\nexport interface BanActionRequest {\n channel_ban_only?: boolean;\n\n delete_messages?: 'soft' | 'pruning' | 'hard';\n\n ip_ban?: boolean;\n\n reason?: string;\n\n shadow?: boolean;\n\n timeout?: number;\n}\n\nexport interface BanRequest {\n target_user_id: string;\n\n banned_by_id?: string;\n\n channel_cid?: string;\n\n delete_messages?: 'soft' | 'pruning' | 'hard';\n\n ip_ban?: boolean;\n\n reason?: string;\n\n shadow?: boolean;\n\n timeout?: number;\n\n banned_by?: UserRequest;\n}\n\nexport interface BanResponse {\n duration: string;\n}\n\nexport interface BlockListConfig {\n enabled: boolean;\n\n rules: BlockListRule[];\n\n async?: boolean;\n}\n\nexport interface BlockListOptions {\n behavior: 'flag' | 'block' | 'shadow_block';\n\n blocklist: string;\n}\n\nexport interface BlockListResponse {\n name: string;\n\n type: string;\n\n words: string[];\n\n created_at?: Date;\n\n id?: string;\n\n team?: string;\n\n updated_at?: Date;\n}\n\nexport interface BlockListRule {\n action:\n | 'flag'\n | 'mask_flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n name: string;\n\n team: string;\n}\n\nexport interface BlockUsersRequest {\n blocked_user_id: string;\n}\n\nexport interface BlockUsersResponse {\n blocked_by_user_id: string;\n\n blocked_user_id: string;\n\n created_at: Date;\n\n duration: string;\n}\n\nexport interface BlockedUserResponse {\n blocked_user_id: string;\n\n created_at: Date;\n\n user_id: string;\n\n blocked_user: UserResponse;\n\n user: UserResponse;\n}\n\nexport interface BodyguardRule {\n action:\n | 'flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n label: string;\n\n severity_rules: BodyguardSeverityRule[];\n}\n\nexport interface BodyguardSeverityRule {\n action:\n | 'flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n severity: 'low' | 'medium' | 'high' | 'critical';\n}\n\nexport interface BookmarkAddedEvent {\n created_at: Date;\n\n bookmark: BookmarkResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface BookmarkDeletedEvent {\n created_at: Date;\n\n bookmark: BookmarkResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface BookmarkFolderResponse {\n created_at: Date;\n\n id: string;\n\n name: string;\n\n updated_at: Date;\n\n custom?: Record<string, any>;\n}\n\nexport interface BookmarkResponse {\n created_at: Date;\n\n updated_at: Date;\n\n activity: ActivityResponse;\n\n user: UserResponse;\n\n custom?: Record<string, any>;\n\n folder?: BookmarkFolderResponse;\n}\n\nexport interface BookmarkUpdatedEvent {\n created_at: Date;\n\n bookmark: BookmarkResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface BroadcastSettings {\n enabled: boolean;\n\n hls?: HLSSettings;\n\n rtmp?: RTMPSettings;\n}\n\nexport interface BroadcastSettingsResponse {\n enabled: boolean;\n\n hls: HLSSettingsResponse;\n\n rtmp: RTMPSettingsResponse;\n}\n\nexport interface Call {\n app_pk: number;\n\n backstage: boolean;\n\n channel_cid: string;\n\n cid: string;\n\n created_at: Date;\n\n created_by_user_id: string;\n\n current_session_id: string;\n\n id: string;\n\n last_session_id: string;\n\n team: string;\n\n thumbnail_url: string;\n\n type: string;\n\n updated_at: Date;\n\n blocked_user_i_ds: string[];\n\n blocked_users: User[];\n\n egresses: CallEgress[];\n\n members: CallMember[];\n\n custom: Record<string, any>;\n\n deleted_at?: Date;\n\n egress_updated_at?: Date;\n\n ended_at?: Date;\n\n join_ahead_time_seconds?: number;\n\n last_heartbeat_at?: Date;\n\n member_count?: number;\n\n starts_at?: Date;\n\n call_type?: CallType;\n\n created_by?: User;\n\n member_lookup?: MemberLookup;\n\n session?: CallSession;\n\n settings?: CallSettings;\n\n settings_overrides?: CallSettings;\n}\n\nexport interface CallEgress {\n app_pk: number;\n\n call_id: string;\n\n call_type: string;\n\n egress_id: string;\n\n egress_type: string;\n\n instance_ip: string;\n\n started_at: Date;\n\n state: string;\n\n updated_at: Date;\n\n stopped_at?: Date;\n\n config?: EgressTaskConfig;\n}\n\nexport interface CallIngressResponse {\n rtmp: RTMPIngress;\n}\n\nexport interface CallMember {\n created_at: Date;\n\n role: string;\n\n updated_at: Date;\n\n user_id: string;\n\n custom: Record<string, any>;\n\n deleted_at?: Date;\n\n user?: User;\n}\n\nexport interface CallParticipant {\n banned: boolean;\n\n id: string;\n\n joined_at: Date;\n\n online: boolean;\n\n role: string;\n\n user_session_id: string;\n\n custom: Record<string, any>;\n\n teams_role: Record<string, string>;\n\n ban_expires?: Date;\n\n created_at?: Date;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n invisible?: boolean;\n\n language?: string;\n\n last_active?: Date;\n\n last_engaged_at?: Date;\n\n revoke_tokens_issued_before?: Date;\n\n updated_at?: Date;\n\n teams?: string[];\n\n privacy_settings?: PrivacySettings;\n}\n\nexport interface CallParticipantResponse {\n joined_at: Date;\n\n role: string;\n\n user_session_id: string;\n\n user: UserResponse;\n}\n\nexport interface CallResponse {\n backstage: boolean;\n\n captioning: boolean;\n\n cid: string;\n\n created_at: Date;\n\n current_session_id: string;\n\n id: string;\n\n recording: boolean;\n\n transcribing: boolean;\n\n type: string;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n created_by: UserResponse;\n\n custom: Record<string, any>;\n\n egress: EgressResponse;\n\n ingress: CallIngressResponse;\n\n settings: CallSettingsResponse;\n\n channel_cid?: string;\n\n ended_at?: Date;\n\n join_ahead_time_seconds?: number;\n\n starts_at?: Date;\n\n team?: string;\n\n session?: CallSessionResponse;\n\n thumbnails?: ThumbnailResponse;\n}\n\nexport interface CallSession {\n anonymous_participant_count: number;\n\n app_pk: number;\n\n call_id: string;\n\n call_type: string;\n\n created_at: Date;\n\n session_id: string;\n\n active_sf_us: SFUIDLastSeen[];\n\n participants: CallParticipant[];\n\n sfui_ds: string[];\n\n accepted_by: Record<string, Date>;\n\n missed_by: Record<string, Date>;\n\n participants_count_by_role: Record<string, number>;\n\n rejected_by: Record<string, Date>;\n\n user_permission_overrides: Record<string, Record<string, boolean>>;\n\n deleted_at?: Date;\n\n ended_at?: Date;\n\n live_ended_at?: Date;\n\n live_started_at?: Date;\n\n ring_at?: Date;\n\n started_at?: Date;\n\n timer_ends_at?: Date;\n}\n\nexport interface CallSessionResponse {\n anonymous_participant_count: number;\n\n id: string;\n\n participants: CallParticipantResponse[];\n\n accepted_by: Record<string, Date>;\n\n missed_by: Record<string, Date>;\n\n participants_count_by_role: Record<string, number>;\n\n rejected_by: Record<string, Date>;\n\n ended_at?: Date;\n\n live_ended_at?: Date;\n\n live_started_at?: Date;\n\n started_at?: Date;\n\n timer_ends_at?: Date;\n}\n\nexport interface CallSettings {\n audio?: AudioSettings;\n\n backstage?: BackstageSettings;\n\n broadcasting?: BroadcastSettings;\n\n frame_recording?: FrameRecordSettings;\n\n geofencing?: GeofenceSettings;\n\n limits?: LimitsSettings;\n\n recording?: RecordSettings;\n\n ring?: RingSettings;\n\n screensharing?: ScreensharingSettings;\n\n session?: SessionSettings;\n\n thumbnails?: ThumbnailsSettings;\n\n transcription?: TranscriptionSettings;\n\n video?: VideoSettings;\n}\n\nexport interface CallSettingsResponse {\n audio: AudioSettingsResponse;\n\n backstage: BackstageSettingsResponse;\n\n broadcasting: BroadcastSettingsResponse;\n\n frame_recording: FrameRecordingSettingsResponse;\n\n geofencing: GeofenceSettingsResponse;\n\n limits: LimitsSettingsResponse;\n\n recording: RecordSettingsResponse;\n\n ring: RingSettingsResponse;\n\n screensharing: ScreensharingSettingsResponse;\n\n session: SessionSettingsResponse;\n\n thumbnails: ThumbnailsSettingsResponse;\n\n transcription: TranscriptionSettingsResponse;\n\n video: VideoSettingsResponse;\n}\n\nexport interface CallType {\n app_pk: number;\n\n created_at: Date;\n\n external_storage: string;\n\n name: string;\n\n pk: number;\n\n updated_at: Date;\n\n notification_settings?: NotificationSettings;\n\n settings?: CallSettings;\n}\n\nexport interface CastPollVoteRequest {\n vote?: VoteData;\n}\n\nexport interface Channel {\n auto_translation_language: string;\n\n cid: string;\n\n created_at: Date;\n\n disabled: boolean;\n\n frozen: boolean;\n\n id: string;\n\n type: string;\n\n updated_at: Date;\n\n custom: Record<string, any>;\n\n auto_translation_enabled?: boolean;\n\n cooldown?: number;\n\n deleted_at?: Date;\n\n last_campaigns?: string;\n\n last_message_at?: Date;\n\n member_count?: number;\n\n team?: string;\n\n active_live_locations?: SharedLocation[];\n\n invites?: ChannelMember[];\n\n members?: ChannelMember[];\n\n config?: ChannelConfig;\n\n config_overrides?: ConfigOverrides;\n\n created_by?: User;\n\n truncated_by?: User;\n}\n\nexport interface ChannelConfig {\n automod: 'disabled' | 'simple' | 'AI';\n\n automod_behavior: 'flag' | 'block' | 'shadow_block';\n\n connect_events: boolean;\n\n created_at: Date;\n\n custom_events: boolean;\n\n mark_messages_pending: boolean;\n\n max_message_length: number;\n\n mutes: boolean;\n\n name: string;\n\n polls: boolean;\n\n push_notifications: boolean;\n\n quotes: boolean;\n\n reactions: boolean;\n\n read_events: boolean;\n\n reminders: boolean;\n\n replies: boolean;\n\n search: boolean;\n\n shared_locations: boolean;\n\n skip_last_msg_update_for_system_msgs: boolean;\n\n typing_events: boolean;\n\n updated_at: Date;\n\n uploads: boolean;\n\n url_enrichment: boolean;\n\n user_message_reminders: boolean;\n\n commands: string[];\n\n blocklist?: string;\n\n blocklist_behavior?: 'flag' | 'block' | 'shadow_block';\n\n partition_size?: number;\n\n partition_ttl?: number;\n\n allowed_flag_reasons?: string[];\n\n blocklists?: BlockListOptions[];\n\n automod_thresholds?: Thresholds;\n}\n\nexport interface ChannelConfigWithInfo {\n automod: 'disabled' | 'simple' | 'AI';\n\n automod_behavior: 'flag' | 'block' | 'shadow_block';\n\n connect_events: boolean;\n\n created_at: Date;\n\n custom_events: boolean;\n\n mark_messages_pending: boolean;\n\n max_message_length: number;\n\n mutes: boolean;\n\n name: string;\n\n polls: boolean;\n\n push_notifications: boolean;\n\n quotes: boolean;\n\n reactions: boolean;\n\n read_events: boolean;\n\n reminders: boolean;\n\n replies: boolean;\n\n search: boolean;\n\n shared_locations: boolean;\n\n skip_last_msg_update_for_system_msgs: boolean;\n\n typing_events: boolean;\n\n updated_at: Date;\n\n uploads: boolean;\n\n url_enrichment: boolean;\n\n user_message_reminders: boolean;\n\n commands: Command[];\n\n blocklist?: string;\n\n blocklist_behavior?: 'flag' | 'block' | 'shadow_block';\n\n partition_size?: number;\n\n partition_ttl?: string;\n\n allowed_flag_reasons?: string[];\n\n blocklists?: BlockListOptions[];\n\n automod_thresholds?: Thresholds;\n\n grants?: Record<string, string[]>;\n}\n\nexport interface ChannelMember {\n banned: boolean;\n\n channel_role: string;\n\n created_at: Date;\n\n notifications_muted: boolean;\n\n shadow_banned: boolean;\n\n updated_at: Date;\n\n custom: Record<string, any>;\n\n archived_at?: Date;\n\n ban_expires?: Date;\n\n deleted_at?: Date;\n\n invite_accepted_at?: Date;\n\n invite_rejected_at?: Date;\n\n invited?: boolean;\n\n is_moderator?: boolean;\n\n pinned_at?: Date;\n\n role?: 'member' | 'moderator' | 'admin' | 'owner';\n\n status?: string;\n\n user_id?: string;\n\n user?: UserResponse;\n}\n\nexport interface ChannelMute {\n created_at: Date;\n\n updated_at: Date;\n\n expires?: Date;\n\n channel?: ChannelResponse;\n\n user?: UserResponse;\n}\n\nexport const ChannelOwnCapability = {\n BAN_CHANNEL_MEMBERS: 'ban-channel-members',\n CAST_POLL_VOTE: 'cast-poll-vote',\n CONNECT_EVENTS: 'connect-events',\n CREATE_ATTACHMENT: 'create-attachment',\n DELETE_ANY_MESSAGE: 'delete-any-message',\n DELETE_CHANNEL: 'delete-channel',\n DELETE_OWN_MESSAGE: 'delete-own-message',\n FLAG_MESSAGE: 'flag-message',\n FREEZE_CHANNEL: 'freeze-channel',\n JOIN_CHANNEL: 'join-channel',\n LEAVE_CHANNEL: 'leave-channel',\n MUTE_CHANNEL: 'mute-channel',\n PIN_MESSAGE: 'pin-message',\n QUERY_POLL_VOTES: 'query-poll-votes',\n QUOTE_MESSAGE: 'quote-message',\n READ_EVENTS: 'read-events',\n SEARCH_MESSAGES: 'search-messages',\n SEND_CUSTOM_EVENTS: 'send-custom-events',\n SEND_LINKS: 'send-links',\n SEND_MESSAGE: 'send-message',\n SEND_POLL: 'send-poll',\n SEND_REACTION: 'send-reaction',\n SEND_REPLY: 'send-reply',\n SEND_RESTRICTED_VISIBILITY_MESSAGE: 'send-restricted-visibility-message',\n SEND_TYPING_EVENTS: 'send-typing-events',\n SET_CHANNEL_COOLDOWN: 'set-channel-cooldown',\n SHARE_LOCATION: 'share-location',\n SKIP_SLOW_MODE: 'skip-slow-mode',\n SLOW_MODE: 'slow-mode',\n TYPING_EVENTS: 'typing-events',\n UPDATE_ANY_MESSAGE: 'update-any-message',\n UPDATE_CHANNEL: 'update-channel',\n UPDATE_CHANNEL_MEMBERS: 'update-channel-members',\n UPDATE_OWN_MESSAGE: 'update-own-message',\n UPDATE_THREAD: 'update-thread',\n UPLOAD_FILE: 'upload-file',\n} as const;\n\nexport type ChannelOwnCapability =\n (typeof ChannelOwnCapability)[keyof typeof ChannelOwnCapability];\n\nexport interface ChannelResponse {\n cid: string;\n\n created_at: Date;\n\n disabled: boolean;\n\n frozen: boolean;\n\n id: string;\n\n type: string;\n\n updated_at: Date;\n\n custom: Record<string, any>;\n\n auto_translation_enabled?: boolean;\n\n auto_translation_language?: string;\n\n blocked?: boolean;\n\n cooldown?: number;\n\n deleted_at?: Date;\n\n hidden?: boolean;\n\n hide_messages_before?: Date;\n\n last_message_at?: Date;\n\n member_count?: number;\n\n mute_expires_at?: Date;\n\n muted?: boolean;\n\n team?: string;\n\n truncated_at?: Date;\n\n members?: ChannelMember[];\n\n own_capabilities?: ChannelOwnCapability[];\n\n config?: ChannelConfigWithInfo;\n\n created_by?: UserResponse;\n\n truncated_by?: UserResponse;\n}\n\nexport interface Command {\n args: string;\n\n description: string;\n\n name: string;\n\n set: string;\n\n created_at?: Date;\n\n updated_at?: Date;\n}\n\nexport interface CommentAddedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface CommentDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface CommentReactionAddedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface CommentReactionDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface CommentReactionUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n reaction: FeedsReactionResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface CommentResponse {\n confidence_score: number;\n\n created_at: Date;\n\n downvote_count: number;\n\n id: string;\n\n object_id: string;\n\n object_type: string;\n\n reaction_count: number;\n\n reply_count: number;\n\n score: number;\n\n status: string;\n\n updated_at: Date;\n\n upvote_count: number;\n\n mentioned_users: UserResponse[];\n\n own_reactions: FeedsReactionResponse[];\n\n user: UserResponse;\n\n controversy_score?: number;\n\n deleted_at?: Date;\n\n parent_id?: string;\n\n text?: string;\n\n attachments?: Attachment[];\n\n latest_reactions?: FeedsReactionResponse[];\n\n custom?: Record<string, any>;\n\n moderation?: ModerationV2Response;\n\n reaction_groups?: Record<string, ReactionGroupResponse>;\n}\n\nexport interface CommentUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n comment: CommentResponse;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface CompositeAppSettings {\n json_encoded_settings?: string;\n\n url?: string;\n}\n\nexport interface ConfigOverrides {\n commands: string[];\n\n grants: Record<string, string[]>;\n\n blocklist?: string;\n\n blocklist_behavior?: 'flag' | 'block';\n\n max_message_length?: number;\n\n quotes?: boolean;\n\n reactions?: boolean;\n\n replies?: boolean;\n\n shared_locations?: boolean;\n\n typing_events?: boolean;\n\n uploads?: boolean;\n\n url_enrichment?: boolean;\n\n user_message_reminders?: boolean;\n}\n\nexport interface ConfigResponse {\n async: boolean;\n\n created_at: Date;\n\n key: string;\n\n team: string;\n\n updated_at: Date;\n\n ai_image_config?: AIImageConfig;\n\n ai_text_config?: AITextConfig;\n\n ai_video_config?: AIVideoConfig;\n\n automod_platform_circumvention_config?: AutomodPlatformCircumventionConfig;\n\n automod_semantic_filters_config?: AutomodSemanticFiltersConfig;\n\n automod_toxicity_config?: AutomodToxicityConfig;\n\n block_list_config?: BlockListConfig;\n\n velocity_filter_config?: VelocityFilterConfig;\n\n video_call_rule_config?: VideoCallRuleConfig;\n}\n\nexport interface ConnectUserDetailsRequest {\n id: string;\n\n image?: string;\n\n invisible?: boolean;\n\n language?: string;\n\n name?: string;\n\n custom?: Record<string, any>;\n\n privacy_settings?: PrivacySettingsResponse;\n}\n\nexport interface CreateBlockListRequest {\n name: string;\n\n words: string[];\n\n team?: string;\n\n type?: 'regex' | 'domain' | 'domain_allowlist' | 'email' | 'word';\n}\n\nexport interface CreateBlockListResponse {\n duration: string;\n\n blocklist?: BlockListResponse;\n}\n\nexport interface CreateDeviceRequest {\n id: string;\n\n push_provider: 'firebase' | 'apn' | 'huawei' | 'xiaomi';\n\n push_provider_name?: string;\n\n voip_token?: boolean;\n}\n\nexport interface CreateFeedsBatchRequest {\n feeds: FeedRequest[];\n}\n\nexport interface CreateFeedsBatchResponse {\n duration: string;\n\n feeds: FeedResponse[];\n}\n\nexport interface CreateGuestRequest {\n user: UserRequest;\n}\n\nexport interface CreateGuestResponse {\n access_token: string;\n\n duration: string;\n\n user: UserResponse;\n}\n\nexport interface CreatePollOptionRequest {\n text: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface CreatePollRequest {\n name: string;\n\n allow_answers?: boolean;\n\n allow_user_suggested_options?: boolean;\n\n description?: string;\n\n enforce_unique_vote?: boolean;\n\n id?: string;\n\n is_closed?: boolean;\n\n max_votes_allowed?: number;\n\n voting_visibility?: 'anonymous' | 'public';\n\n options?: PollOptionInput[];\n\n custom?: Record<string, any>;\n}\n\nexport interface CustomActionRequest {\n id?: string;\n\n options?: Record<string, any>;\n}\n\nexport interface Data {\n id: string;\n}\n\nexport interface DeleteActivitiesRequest {\n activity_ids: string[];\n\n hard_delete?: boolean;\n}\n\nexport interface DeleteActivitiesResponse {\n duration: string;\n\n deleted_activity_ids: string[];\n}\n\nexport interface DeleteActivityReactionResponse {\n duration: string;\n\n activity: ActivityResponse;\n\n reaction: FeedsReactionResponse;\n}\n\nexport interface DeleteActivityRequest {\n hard_delete?: boolean;\n}\n\nexport interface DeleteActivityResponse {\n duration: string;\n}\n\nexport interface DeleteBookmarkResponse {\n duration: string;\n\n bookmark: BookmarkResponse;\n}\n\nexport interface DeleteCommentReactionResponse {\n duration: string;\n\n comment: CommentResponse;\n\n reaction: FeedsReactionResponse;\n}\n\nexport interface DeleteCommentResponse {\n duration: string;\n}\n\nexport interface DeleteFeedResponse {\n duration: string;\n}\n\nexport interface DeleteMessageRequest {\n hard_delete?: boolean;\n}\n\nexport interface DeleteModerationConfigResponse {\n duration: string;\n}\n\nexport interface DeleteReactionRequest {\n hard_delete?: boolean;\n}\n\nexport interface DeleteUserRequest {\n delete_conversation_channels?: boolean;\n\n delete_feeds_content?: boolean;\n\n hard_delete?: boolean;\n\n mark_messages_deleted?: boolean;\n}\n\nexport interface Device {\n created_at: Date;\n\n id: string;\n\n push_provider: 'firebase' | 'apn' | 'huawei' | 'xiaomi';\n\n user_id: string;\n\n disabled?: boolean;\n\n disabled_reason?: string;\n\n push_provider_name?: string;\n\n voip?: boolean;\n}\n\nexport interface DeviceResponse {\n created_at: Date;\n\n id: string;\n\n push_provider: string;\n\n user_id: string;\n\n disabled?: boolean;\n\n disabled_reason?: string;\n\n push_provider_name?: string;\n\n voip?: boolean;\n}\n\nexport interface DraftPayloadResponse {\n id: string;\n\n text: string;\n\n custom: Record<string, any>;\n\n html?: string;\n\n mml?: string;\n\n parent_id?: string;\n\n poll_id?: string;\n\n quoted_message_id?: string;\n\n show_in_channel?: boolean;\n\n silent?: boolean;\n\n type?: string;\n\n attachments?: Attachment[];\n\n mentioned_users?: UserResponse[];\n}\n\nexport interface DraftResponse {\n channel_cid: string;\n\n created_at: Date;\n\n message: DraftPayloadResponse;\n\n parent_id?: string;\n\n channel?: ChannelResponse;\n\n parent_message?: MessageResponse;\n\n quoted_message?: MessageResponse;\n}\n\nexport interface EgressHLSResponse {\n playlist_url: string;\n\n status: string;\n}\n\nexport interface EgressRTMPResponse {\n name: string;\n\n started_at: Date;\n\n stream_key?: string;\n\n stream_url?: string;\n}\n\nexport interface EgressResponse {\n broadcasting: boolean;\n\n rtmps: EgressRTMPResponse[];\n\n frame_recording?: FrameRecordingResponse;\n\n hls?: EgressHLSResponse;\n}\n\nexport interface EgressTaskConfig {\n egress_user?: EgressUser;\n\n frame_recording_egress_config?: FrameRecordingEgressConfig;\n\n hls_egress_config?: HLSEgressConfig;\n\n recording_egress_config?: RecordingEgressConfig;\n\n rtmp_egress_config?: RTMPEgressConfig;\n\n stt_egress_config?: STTEgressConfig;\n}\n\nexport interface EgressUser {\n token?: string;\n}\n\nexport interface EnrichedActivity {\n foreign_id?: string;\n\n id?: string;\n\n score?: number;\n\n verb?: string;\n\n to?: string[];\n\n actor?: Data;\n\n latest_reactions?: Record<string, EnrichedReaction[]>;\n\n object?: Data;\n\n origin?: Data;\n\n own_reactions?: Record<string, EnrichedReaction[]>;\n\n reaction_counts?: Record<string, number>;\n\n target?: Data;\n}\n\nexport interface EnrichedReaction {\n activity_id: string;\n\n kind: string;\n\n user_id: string;\n\n id?: string;\n\n parent?: string;\n\n target_feeds?: string[];\n\n children_counts?: Record<string, number>;\n\n created_at?: Time;\n\n data?: Record<string, any>;\n\n latest_children?: Record<string, EnrichedReaction[]>;\n\n own_children?: Record<string, EnrichedReaction[]>;\n\n updated_at?: Time;\n\n user?: Data;\n}\n\nexport interface EntityCreator {\n ban_count: number;\n\n banned: boolean;\n\n deleted_content_count: number;\n\n id: string;\n\n online: boolean;\n\n role: string;\n\n custom: Record<string, any>;\n\n teams_role: Record<string, string>;\n\n ban_expires?: Date;\n\n created_at?: Date;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n invisible?: boolean;\n\n language?: string;\n\n last_active?: Date;\n\n last_engaged_at?: Date;\n\n revoke_tokens_issued_before?: Date;\n\n updated_at?: Date;\n\n teams?: string[];\n\n privacy_settings?: PrivacySettings;\n}\n\nexport interface EntityCreatorResponse {\n ban_count: number;\n\n banned: boolean;\n\n created_at: Date;\n\n deleted_content_count: number;\n\n flagged_count: number;\n\n id: string;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface EventNotificationSettings {\n enabled: boolean;\n\n apns: APNS;\n\n fcm: FCM;\n}\n\nexport interface ExternalStorage {\n abs_account_name?: string;\n\n abs_client_id?: string;\n\n abs_client_secret?: string;\n\n abs_tenant_id?: string;\n\n bucket?: string;\n\n gcs_credentials?: string;\n\n path?: string;\n\n s3_api_key?: string;\n\n s3_custom_endpoint?: string;\n\n s3_region?: string;\n\n s3_secret_key?: string;\n\n storage_name?: string;\n\n storage_type?: number;\n}\n\nexport interface FCM {\n data?: Record<string, any>;\n}\n\nexport interface FeedCreatedEvent {\n created_at: Date;\n\n fid: string;\n\n members: FeedMemberResponse[];\n\n custom: Record<string, any>;\n\n feed: FeedResponse;\n\n user: UserResponseCommonFields;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface FeedDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface FeedGroup {\n app_pk: number;\n\n created_at: Date;\n\n default_view_id: string;\n\n default_visibility: string;\n\n id: string;\n\n updated_at: Date;\n\n custom: Record<string, any>;\n\n deleted_at?: Date;\n\n last_feed_get_at?: Date;\n\n notification?: NotificationConfig;\n\n stories?: StoriesConfig;\n}\n\nexport interface FeedGroupChangedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n feed_group?: FeedGroup;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface FeedGroupDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n group_id: string;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface FeedInput {\n description?: string;\n\n name?: string;\n\n visibility?: 'public' | 'visible' | 'followers' | 'members' | 'private';\n\n members?: FeedMemberRequest[];\n\n custom?: Record<string, any>;\n}\n\nexport interface FeedMemberAddedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n member: FeedMemberResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface FeedMemberRemovedEvent {\n created_at: Date;\n\n fid: string;\n\n member_id: string;\n\n custom: Record<string, any>;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface FeedMemberRequest {\n user_id: string;\n\n invite?: boolean;\n\n role?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface FeedMemberResponse {\n created_at: Date;\n\n role: string;\n\n status: 'member' | 'pending' | 'rejected';\n\n updated_at: Date;\n\n user: UserResponse;\n\n invite_accepted_at?: Date;\n\n invite_rejected_at?: Date;\n\n custom?: Record<string, any>;\n}\n\nexport interface FeedMemberUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n member: FeedMemberResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport const FeedOwnCapability = {\n ADD_ACTIVITY: 'add-activity',\n ADD_ACTIVITY_REACTION: 'add-activity-reaction',\n ADD_COMMENT: 'add-comment',\n ADD_COMMENT_REACTION: 'add-comment-reaction',\n BOOKMARK_ACTIVITY: 'bookmark-activity',\n CREATE_FEED: 'create-feed',\n DELETE_BOOKMARK: 'delete-bookmark',\n DELETE_COMMENT: 'delete-comment',\n DELETE_FEED: 'delete-feed',\n EDIT_BOOKMARK: 'edit-bookmark',\n FOLLOW: 'follow',\n INVITE_FEED: 'invite-feed',\n JOIN_FEED: 'join-feed',\n LEAVE_FEED: 'leave-feed',\n MANAGE_FEED_GROUP: 'manage-feed-group',\n MARK_ACTIVITY: 'mark-activity',\n PIN_ACTIVITY: 'pin-activity',\n QUERY_FEED_MEMBERS: 'query-feed-members',\n QUERY_FOLLOWS: 'query-follows',\n READ_ACTIVITIES: 'read-activities',\n READ_FEED: 'read-feed',\n REMOVE_ACTIVITY: 'remove-activity',\n REMOVE_ACTIVITY_REACTION: 'remove-activity-reaction',\n REMOVE_COMMENT_REACTION: 'remove-comment-reaction',\n UNFOLLOW: 'unfollow',\n UPDATE_ACTIVITY: 'update-activity',\n UPDATE_COMMENT: 'update-comment',\n UPDATE_FEED: 'update-feed',\n UPDATE_FEED_FOLLOWERS: 'update-feed-followers',\n UPDATE_FEED_MEMBERS: 'update-feed-members',\n} as const;\n\nexport type FeedOwnCapability =\n (typeof FeedOwnCapability)[keyof typeof FeedOwnCapability];\n\nexport interface FeedRequest {\n feed_group_id: string;\n\n feed_id: string;\n\n created_by_id?: string;\n\n description?: string;\n\n name?: string;\n\n visibility?: 'public' | 'visible' | 'followers' | 'members' | 'private';\n\n members?: FeedMemberRequest[];\n\n custom?: Record<string, any>;\n}\n\nexport interface FeedResponse {\n created_at: Date;\n\n description: string;\n\n fid: string;\n\n follower_count: number;\n\n following_count: number;\n\n group_id: string;\n\n id: string;\n\n member_count: number;\n\n name: string;\n\n pin_count: number;\n\n updated_at: Date;\n\n created_by: UserResponse;\n\n deleted_at?: Date;\n\n visibility?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface FeedUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n feed: FeedResponse;\n\n type: string;\n\n received_at?: Date;\n\n user?: UserResponseCommonFields;\n}\n\nexport interface FeedsReactionResponse {\n activity_id: string;\n\n created_at: Date;\n\n type: string;\n\n updated_at: Date;\n\n user: UserResponse;\n\n comment_id?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface Field {\n short: boolean;\n\n title: string;\n\n value: string;\n}\n\nexport interface FileUploadConfig {\n size_limit: number;\n\n allowed_file_extensions: string[];\n\n allowed_mime_types: string[];\n\n blocked_file_extensions: string[];\n\n blocked_mime_types: string[];\n}\n\nexport interface FileUploadRequest {\n file?: string;\n\n user?: OnlyUserID;\n}\n\nexport interface FileUploadResponse {\n duration: string;\n\n file?: string;\n\n thumb_url?: string;\n}\n\nexport interface Flag {\n created_at: Date;\n\n entity_id: string;\n\n entity_type: string;\n\n updated_at: Date;\n\n result: Array<Record<string, any>>;\n\n entity_creator_id?: string;\n\n is_streamed_content?: boolean;\n\n moderation_payload_hash?: string;\n\n reason?: string;\n\n review_queue_item_id?: string;\n\n type?: string;\n\n labels?: string[];\n\n custom?: Record<string, any>;\n\n moderation_payload?: ModerationPayload;\n\n review_queue_item?: ReviewQueueItem;\n\n user?: User;\n}\n\nexport interface FlagRequest {\n entity_id: string;\n\n entity_type: string;\n\n entity_creator_id?: string;\n\n reason?: string;\n\n custom?: Record<string, any>;\n\n moderation_payload?: ModerationPayload;\n}\n\nexport interface FlagResponse {\n duration: string;\n\n item_id: string;\n}\n\nexport interface FollowBatchRequest {\n follows: FollowRequest[];\n}\n\nexport interface FollowBatchResponse {\n duration: string;\n\n follows: FollowResponse[];\n}\n\nexport interface FollowCreatedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n follow: FollowResponse;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface FollowDeletedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n follow: FollowResponse;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface FollowRequest {\n source: string;\n\n target: string;\n\n push_preference?: 'all' | 'none';\n\n custom?: Record<string, any>;\n}\n\nexport interface FollowResponse {\n created_at: Date;\n\n follower_role: string;\n\n push_preference: 'all' | 'none';\n\n status: 'accepted' | 'pending' | 'rejected';\n\n updated_at: Date;\n\n source_feed: FeedResponse;\n\n target_feed: FeedResponse;\n\n request_accepted_at?: Date;\n\n request_rejected_at?: Date;\n\n custom?: Record<string, any>;\n}\n\nexport interface FollowUpdatedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n follow: FollowResponse;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface FrameRecordSettings {\n capture_interval_in_seconds: number;\n\n mode: 'available' | 'disabled' | 'auto-on';\n\n quality?: string;\n}\n\nexport interface FrameRecordingEgressConfig {\n capture_interval_in_seconds?: number;\n\n storage_name?: string;\n\n external_storage?: ExternalStorage;\n\n quality?: Quality;\n}\n\nexport interface FrameRecordingResponse {\n status: string;\n}\n\nexport interface FrameRecordingSettingsResponse {\n capture_interval_in_seconds: number;\n\n mode: 'available' | 'disabled' | 'auto-on';\n\n quality?: string;\n}\n\nexport interface FullUserResponse {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n invisible: boolean;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n shadow_banned: boolean;\n\n total_unread_count: number;\n\n unread_channels: number;\n\n unread_count: number;\n\n unread_threads: number;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n channel_mutes: ChannelMute[];\n\n devices: DeviceResponse[];\n\n mutes: UserMuteResponse[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n ban_expires?: Date;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n latest_hidden_channels?: string[];\n\n privacy_settings?: PrivacySettingsResponse;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface GeofenceSettings {\n names: string[];\n}\n\nexport interface GeofenceSettingsResponse {\n names: string[];\n}\n\nexport interface GetActivityResponse {\n duration: string;\n\n activity: ActivityResponse;\n}\n\nexport interface GetApplicationResponse {\n duration: string;\n\n app: AppResponseFields;\n}\n\nexport interface GetBlockedUsersResponse {\n duration: string;\n\n blocks: BlockedUserResponse[];\n}\n\nexport interface GetCommentRepliesResponse {\n duration: string;\n\n comments: ThreadedCommentResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface GetCommentResponse {\n duration: string;\n\n comment: CommentResponse;\n}\n\nexport interface GetCommentsResponse {\n duration: string;\n\n comments: ThreadedCommentResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface GetConfigResponse {\n duration: string;\n\n config?: ConfigResponse;\n}\n\nexport interface GetFollowSuggestionsResponse {\n duration: string;\n\n suggestions: FeedResponse[];\n}\n\nexport interface GetOGResponse {\n duration: string;\n\n custom: Record<string, any>;\n\n asset_url?: string;\n\n author_icon?: string;\n\n author_link?: string;\n\n author_name?: string;\n\n color?: string;\n\n fallback?: string;\n\n footer?: string;\n\n footer_icon?: string;\n\n image_url?: string;\n\n og_scrape_url?: string;\n\n original_height?: number;\n\n original_width?: number;\n\n pretext?: string;\n\n text?: string;\n\n thumb_url?: string;\n\n title?: string;\n\n title_link?: string;\n\n type?: string;\n\n actions?: Action[];\n\n fields?: Field[];\n\n giphy?: Images;\n}\n\nexport interface GetOrCreateFeedRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n view?: string;\n\n watch?: boolean;\n\n activity_selector_options?: Record<string, any>;\n\n data?: FeedInput;\n\n external_ranking?: Record<string, any>;\n\n filter?: Record<string, any>;\n\n followers_pagination?: PagerRequest;\n\n following_pagination?: PagerRequest;\n\n interest_weights?: Record<string, number>;\n\n member_pagination?: PagerRequest;\n}\n\nexport interface GetOrCreateFeedResponse {\n created: boolean;\n\n duration: string;\n\n activities: ActivityResponse[];\n\n aggregated_activities: AggregatedActivityResponse[];\n\n followers: FollowResponse[];\n\n following: FollowResponse[];\n\n members: FeedMemberResponse[];\n\n own_capabilities: FeedOwnCapability[];\n\n pinned_activities: ActivityPinResponse[];\n\n feed: FeedResponse;\n\n next?: string;\n\n prev?: string;\n\n own_follows?: FollowResponse[];\n\n followers_pagination?: PagerResponse;\n\n following_pagination?: PagerResponse;\n\n member_pagination?: PagerResponse;\n\n notification_status?: NotificationStatusResponse;\n\n own_membership?: FeedMemberResponse;\n}\n\nexport interface GoogleVisionConfig {\n enabled?: boolean;\n}\n\nexport interface HLSEgressConfig {\n playlist_url?: string;\n\n start_unix_nano?: number;\n\n qualities?: Quality[];\n\n composite_app_settings?: CompositeAppSettings;\n}\n\nexport interface HLSSettings {\n auto_on: boolean;\n\n enabled: boolean;\n\n quality_tracks: string[];\n\n layout?: LayoutSettings;\n}\n\nexport interface HLSSettingsResponse {\n auto_on: boolean;\n\n enabled: boolean;\n\n quality_tracks: string[];\n}\n\nexport interface HarmConfig {\n severity: number;\n\n action_sequences: ActionSequence[];\n}\n\nexport interface HealthCheckEvent {\n connection_id: string;\n\n created_at: Date;\n\n custom: Record<string, any>;\n\n type: string;\n\n cid?: string;\n\n received_at?: Date;\n\n me?: OwnUserResponse;\n}\n\nexport interface ImageData {\n frames: string;\n\n height: string;\n\n size: string;\n\n url: string;\n\n width: string;\n}\n\nexport interface ImageSize {\n crop?: 'top' | 'bottom' | 'left' | 'right' | 'center';\n\n height?: number;\n\n resize?: 'clip' | 'crop' | 'scale' | 'fill';\n\n width?: number;\n}\n\nexport interface ImageUploadRequest {\n file?: string;\n\n upload_sizes?: ImageSize[];\n\n user?: OnlyUserID;\n}\n\nexport interface ImageUploadResponse {\n duration: string;\n\n file?: string;\n\n thumb_url?: string;\n\n upload_sizes?: ImageSize[];\n}\n\nexport interface Images {\n fixed_height: ImageData;\n\n fixed_height_downsampled: ImageData;\n\n fixed_height_still: ImageData;\n\n fixed_width: ImageData;\n\n fixed_width_downsampled: ImageData;\n\n fixed_width_still: ImageData;\n\n original: ImageData;\n}\n\nexport interface LabelThresholds {\n block?: number;\n\n flag?: number;\n}\n\nexport interface LayoutSettings {\n external_app_url: string;\n\n external_css_url: string;\n\n name: 'spotlight' | 'grid' | 'single-participant' | 'mobile' | 'custom';\n\n detect_orientation?: boolean;\n\n options?: Record<string, any>;\n}\n\nexport interface LimitsSettings {\n max_participants_exclude_roles: string[];\n\n max_duration_seconds?: number;\n\n max_participants?: number;\n\n max_participants_exclude_owner?: boolean;\n}\n\nexport interface LimitsSettingsResponse {\n max_participants_exclude_roles: string[];\n\n max_duration_seconds?: number;\n\n max_participants?: number;\n\n max_participants_exclude_owner?: boolean;\n}\n\nexport interface ListBlockListResponse {\n duration: string;\n\n blocklists: BlockListResponse[];\n}\n\nexport interface ListDevicesResponse {\n duration: string;\n\n devices: DeviceResponse[];\n}\n\nexport interface MarkActivityRequest {\n mark_all_read?: boolean;\n\n mark_all_seen?: boolean;\n\n mark_read?: string[];\n\n mark_watched?: string[];\n}\n\nexport interface MarkReviewedRequest {\n content_to_mark_as_reviewed_limit?: number;\n\n disable_marking_content_as_reviewed?: boolean;\n}\n\nexport interface MemberLookup {\n limit: number;\n}\n\nexport interface Message {\n cid: string;\n\n created_at: Date;\n\n deleted_reply_count: number;\n\n html: string;\n\n id: string;\n\n pinned: boolean;\n\n reply_count: number;\n\n shadowed: boolean;\n\n silent: boolean;\n\n text: string;\n\n type: string;\n\n updated_at: Date;\n\n attachments: Attachment[];\n\n latest_reactions: Reaction[];\n\n mentioned_users: User[];\n\n own_reactions: Reaction[];\n\n restricted_visibility: string[];\n\n custom: Record<string, any>;\n\n reaction_counts: Record<string, number>;\n\n reaction_groups: Record<string, ReactionGroupResponse>;\n\n reaction_scores: Record<string, number>;\n\n before_message_send_failed?: boolean;\n\n command?: string;\n\n deleted_at?: Date;\n\n message_text_updated_at?: Date;\n\n mml?: string;\n\n parent_id?: string;\n\n pin_expires?: Date;\n\n pinned_at?: Date;\n\n poll_id?: string;\n\n quoted_message_id?: string;\n\n show_in_channel?: boolean;\n\n thread_participants?: User[];\n\n i18n?: Record<string, string>;\n\n image_labels?: Record<string, string[]>;\n\n moderation?: ModerationV2Response;\n\n pinned_by?: User;\n\n poll?: Poll;\n\n quoted_message?: Message;\n\n reminder?: MessageReminder;\n\n shared_location?: SharedLocation;\n\n user?: User;\n}\n\nexport interface MessageReminder {\n channel_cid: string;\n\n created_at: Date;\n\n message_id: string;\n\n task_id: string;\n\n updated_at: Date;\n\n user_id: string;\n\n remind_at?: Date;\n\n channel?: Channel;\n\n message?: Message;\n\n user?: User;\n}\n\nexport interface MessageResponse {\n cid: string;\n\n created_at: Date;\n\n deleted_reply_count: number;\n\n html: string;\n\n id: string;\n\n pinned: boolean;\n\n reply_count: number;\n\n shadowed: boolean;\n\n silent: boolean;\n\n text: string;\n\n type: 'regular' | 'ephemeral' | 'error' | 'reply' | 'system' | 'deleted';\n\n updated_at: Date;\n\n attachments: Attachment[];\n\n latest_reactions: ReactionResponse[];\n\n mentioned_users: UserResponse[];\n\n own_reactions: ReactionResponse[];\n\n restricted_visibility: string[];\n\n custom: Record<string, any>;\n\n reaction_counts: Record<string, number>;\n\n reaction_scores: Record<string, number>;\n\n user: UserResponse;\n\n command?: string;\n\n deleted_at?: Date;\n\n message_text_updated_at?: Date;\n\n mml?: string;\n\n parent_id?: string;\n\n pin_expires?: Date;\n\n pinned_at?: Date;\n\n poll_id?: string;\n\n quoted_message_id?: string;\n\n show_in_channel?: boolean;\n\n thread_participants?: UserResponse[];\n\n draft?: DraftResponse;\n\n i18n?: Record<string, string>;\n\n image_labels?: Record<string, string[]>;\n\n moderation?: ModerationV2Response;\n\n pinned_by?: UserResponse;\n\n poll?: PollResponseData;\n\n quoted_message?: MessageResponse;\n\n reaction_groups?: Record<string, ReactionGroupResponse>;\n\n reminder?: ReminderResponseData;\n\n shared_location?: SharedLocationResponseData;\n}\n\nexport interface ModerationActionConfig {\n action: string;\n\n description: string;\n\n entity_type: string;\n\n icon: string;\n\n order: number;\n\n custom: Record<string, any>;\n}\n\nexport interface ModerationCustomActionEvent {\n created_at: Date;\n\n type: string;\n\n item?: ReviewQueueItem;\n\n message?: Message;\n\n user?: User;\n}\n\nexport interface ModerationFlaggedEvent {\n created_at: Date;\n\n type: string;\n\n item?: string;\n\n object_id?: string;\n\n user?: User;\n}\n\nexport interface ModerationMarkReviewedEvent {\n created_at: Date;\n\n type: string;\n\n item?: ReviewQueueItem;\n\n message?: Message;\n\n user?: User;\n}\n\nexport interface ModerationPayload {\n images?: string[];\n\n texts?: string[];\n\n videos?: string[];\n\n custom?: Record<string, any>;\n}\n\nexport interface ModerationV2Response {\n action: string;\n\n original_text: string;\n\n blocklist_matched?: string;\n\n platform_circumvented?: boolean;\n\n semantic_filter_matched?: string;\n\n image_harms?: string[];\n\n text_harms?: string[];\n}\n\nexport interface MuteRequest {\n target_ids: string[];\n\n timeout?: number;\n}\n\nexport interface MuteResponse {\n duration: string;\n\n mutes?: UserMute[];\n\n non_existing_users?: string[];\n\n own_user?: OwnUser;\n}\n\nexport interface NoiseCancellationSettings {\n mode: 'available' | 'disabled' | 'auto-on';\n}\n\nexport interface NotificationConfig {\n track_read?: boolean;\n\n track_seen?: boolean;\n}\n\nexport interface NotificationSettings {\n enabled: boolean;\n\n call_live_started: EventNotificationSettings;\n\n call_missed: EventNotificationSettings;\n\n call_notification: EventNotificationSettings;\n\n call_ring: EventNotificationSettings;\n\n session_started: EventNotificationSettings;\n}\n\nexport interface NotificationStatusResponse {\n unread: number;\n\n unseen: number;\n\n last_seen_at?: Date;\n\n read_activities?: string[];\n}\n\nexport interface NullTime {}\n\nexport interface OCRRule {\n action:\n | 'flag'\n | 'shadow'\n | 'remove'\n | 'bounce'\n | 'bounce_flag'\n | 'bounce_remove';\n\n label: string;\n}\n\nexport interface OnlyUserID {\n id: string;\n}\n\nexport interface OwnUser {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n total_unread_count: number;\n\n unread_channels: number;\n\n unread_count: number;\n\n unread_threads: number;\n\n updated_at: Date;\n\n channel_mutes: ChannelMute[];\n\n devices: Device[];\n\n mutes: UserMute[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n invisible?: boolean;\n\n last_active?: Date;\n\n last_engaged_at?: Date;\n\n blocked_user_ids?: string[];\n\n latest_hidden_channels?: string[];\n\n teams?: string[];\n\n privacy_settings?: PrivacySettings;\n\n push_preferences?: PushPreferences;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface OwnUserResponse {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n invisible: boolean;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n total_unread_count: number;\n\n unread_channels: number;\n\n unread_count: number;\n\n unread_threads: number;\n\n updated_at: Date;\n\n channel_mutes: ChannelMute[];\n\n devices: DeviceResponse[];\n\n mutes: UserMuteResponse[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n blocked_user_ids?: string[];\n\n latest_hidden_channels?: string[];\n\n privacy_settings?: PrivacySettingsResponse;\n\n push_preferences?: PushPreferences;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface PagerRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface PagerResponse {\n next?: string;\n\n prev?: string;\n}\n\nexport interface PinActivityRequest {}\n\nexport interface PinActivityResponse {\n created_at: Date;\n\n duration: string;\n\n fid: string;\n\n user_id: string;\n\n activity: ActivityResponse;\n}\n\nexport interface Poll {\n allow_answers: boolean;\n\n allow_user_suggested_options: boolean;\n\n answers_count: number;\n\n created_at: Date;\n\n created_by_id: string;\n\n description: string;\n\n enforce_unique_vote: boolean;\n\n id: string;\n\n name: string;\n\n updated_at: Date;\n\n vote_count: number;\n\n latest_answers: PollVote[];\n\n options: PollOption[];\n\n own_votes: PollVote[];\n\n custom: Record<string, any>;\n\n latest_votes_by_option: Record<string, PollVote[]>;\n\n vote_counts_by_option: Record<string, number>;\n\n is_closed?: boolean;\n\n max_votes_allowed?: number;\n\n voting_visibility?: string;\n\n created_by?: User;\n}\n\nexport interface PollClosedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollDeletedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollOption {\n id: string;\n\n text: string;\n\n custom: Record<string, any>;\n}\n\nexport interface PollOptionInput {\n text?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface PollOptionRequest {\n id: string;\n\n text?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface PollOptionResponse {\n duration: string;\n\n poll_option: PollOptionResponseData;\n}\n\nexport interface PollOptionResponseData {\n id: string;\n\n text: string;\n\n custom: Record<string, any>;\n}\n\nexport interface PollResponse {\n duration: string;\n\n poll: PollResponseData;\n}\n\nexport interface PollResponseData {\n allow_answers: boolean;\n\n allow_user_suggested_options: boolean;\n\n answers_count: number;\n\n created_at: Date;\n\n created_by_id: string;\n\n description: string;\n\n enforce_unique_vote: boolean;\n\n id: string;\n\n name: string;\n\n updated_at: Date;\n\n vote_count: number;\n\n voting_visibility: string;\n\n latest_answers: PollVoteResponseData[];\n\n options: PollOptionResponseData[];\n\n own_votes: PollVoteResponseData[];\n\n custom: Record<string, any>;\n\n latest_votes_by_option: Record<string, PollVoteResponseData[]>;\n\n vote_counts_by_option: Record<string, number>;\n\n is_closed?: boolean;\n\n max_votes_allowed?: number;\n\n created_by?: UserResponse;\n}\n\nexport interface PollUpdatedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollVote {\n created_at: Date;\n\n id: string;\n\n option_id: string;\n\n poll_id: string;\n\n updated_at: Date;\n\n answer_text?: string;\n\n is_answer?: boolean;\n\n user_id?: string;\n\n user?: User;\n}\n\nexport interface PollVoteCastedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n poll_vote: PollVoteResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollVoteChangedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n poll_vote: PollVoteResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollVoteRemovedFeedEvent {\n created_at: Date;\n\n fid: string;\n\n custom: Record<string, any>;\n\n poll: PollResponseData;\n\n poll_vote: PollVoteResponseData;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface PollVoteResponse {\n duration: string;\n\n vote?: PollVoteResponseData;\n}\n\nexport interface PollVoteResponseData {\n created_at: Date;\n\n id: string;\n\n option_id: string;\n\n poll_id: string;\n\n updated_at: Date;\n\n answer_text?: string;\n\n is_answer?: boolean;\n\n user_id?: string;\n\n user?: UserResponse;\n}\n\nexport interface PollVotesResponse {\n duration: string;\n\n votes: PollVoteResponseData[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface PrivacySettings {\n read_receipts?: ReadReceipts;\n\n typing_indicators?: TypingIndicators;\n}\n\nexport interface PrivacySettingsResponse {\n read_receipts?: ReadReceiptsResponse;\n\n typing_indicators?: TypingIndicatorsResponse;\n}\n\nexport interface PushPreferences {\n call_level?: string;\n\n chat_level?: string;\n\n disabled_until?: Date;\n}\n\nexport interface Quality {\n bitdepth?: number;\n\n framerate?: number;\n\n height?: number;\n\n name?: string;\n\n video_bitrate?: number;\n\n width?: number;\n}\n\nexport interface QueryActivitiesRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryActivitiesResponse {\n duration: string;\n\n activities: ActivityResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryActivityReactionsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryActivityReactionsResponse {\n duration: string;\n\n reactions: FeedsReactionResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryBookmarkFoldersRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryBookmarkFoldersResponse {\n duration: string;\n\n bookmark_folders: BookmarkFolderResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryBookmarksRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryBookmarksResponse {\n duration: string;\n\n bookmarks: BookmarkResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryCommentReactionsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryCommentReactionsResponse {\n duration: string;\n\n reactions: FeedsReactionResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryCommentsRequest {\n filter: Record<string, any>;\n\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: 'first' | 'last' | 'top' | 'best' | 'controversial';\n}\n\nexport interface QueryCommentsResponse {\n duration: string;\n\n comments: CommentResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryFeedMembersRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryFeedMembersResponse {\n duration: string;\n\n members: FeedMemberResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryFeedsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n watch?: boolean;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryFeedsResponse {\n duration: string;\n\n feeds: FeedResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryFollowsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryFollowsResponse {\n duration: string;\n\n follows: FollowResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryModerationConfigsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryModerationConfigsResponse {\n duration: string;\n\n configs: ConfigResponse[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryPollVotesRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryPollsRequest {\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryPollsResponse {\n duration: string;\n\n polls: PollResponseData[];\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryReviewQueueRequest {\n limit?: number;\n\n lock_count?: number;\n\n lock_duration?: number;\n\n lock_items?: boolean;\n\n next?: string;\n\n prev?: string;\n\n stats_only?: boolean;\n\n sort?: SortParamRequest[];\n\n filter?: Record<string, any>;\n}\n\nexport interface QueryReviewQueueResponse {\n duration: string;\n\n items: ReviewQueueItemResponse[];\n\n action_config: Record<string, ModerationActionConfig[]>;\n\n stats: Record<string, any>;\n\n next?: string;\n\n prev?: string;\n}\n\nexport interface QueryUsersPayload {\n filter_conditions: Record<string, any>;\n\n include_deactivated_users?: boolean;\n\n limit?: number;\n\n offset?: number;\n\n presence?: boolean;\n\n sort?: SortParamRequest[];\n}\n\nexport interface QueryUsersResponse {\n duration: string;\n\n users: FullUserResponse[];\n}\n\nexport interface RTMPEgressConfig {\n rtmp_location?: string;\n\n composite_app_settings?: CompositeAppSettings;\n\n quality?: Quality;\n}\n\nexport interface RTMPIngress {\n address: string;\n}\n\nexport interface RTMPLocation {\n name: string;\n\n stream_key: string;\n\n stream_url: string;\n}\n\nexport interface RTMPSettings {\n enabled: boolean;\n\n quality_name?: string;\n\n layout?: LayoutSettings;\n\n location?: RTMPLocation;\n}\n\nexport interface RTMPSettingsResponse {\n enabled: boolean;\n\n quality: string;\n}\n\nexport interface Reaction {\n created_at: Date;\n\n message_id: string;\n\n score: number;\n\n type: string;\n\n updated_at: Date;\n\n custom: Record<string, any>;\n\n user_id?: string;\n\n user?: User;\n}\n\nexport interface ReactionGroupResponse {\n count: number;\n\n first_reaction_at: Date;\n\n last_reaction_at: Date;\n\n sum_scores: number;\n}\n\nexport interface ReactionResponse {\n created_at: Date;\n\n message_id: string;\n\n score: number;\n\n type: string;\n\n updated_at: Date;\n\n user_id: string;\n\n custom: Record<string, any>;\n\n user: UserResponse;\n}\n\nexport interface ReadReceipts {\n enabled: boolean;\n}\n\nexport interface ReadReceiptsResponse {\n enabled: boolean;\n}\n\nexport interface RecordSettings {\n mode: string;\n\n audio_only?: boolean;\n\n quality?: string;\n\n layout?: LayoutSettings;\n}\n\nexport interface RecordSettingsResponse {\n audio_only: boolean;\n\n mode: string;\n\n quality: string;\n}\n\nexport interface RecordingEgressConfig {\n audio_only?: boolean;\n\n storage_name?: string;\n\n composite_app_settings?: CompositeAppSettings;\n\n external_storage?: ExternalStorage;\n\n quality?: Quality;\n\n video_orientation_hint?: VideoOrientation;\n}\n\nexport interface RejectFeedMemberInviteRequest {}\n\nexport interface RejectFeedMemberInviteResponse {\n duration: string;\n\n member: FeedMemberResponse;\n}\n\nexport interface RejectFollowRequest {\n source_fid: string;\n\n target_fid: string;\n}\n\nexport interface RejectFollowResponse {\n duration: string;\n\n follow: FollowResponse;\n}\n\nexport interface ReminderResponseData {\n channel_cid: string;\n\n created_at: Date;\n\n message_id: string;\n\n updated_at: Date;\n\n user_id: string;\n\n remind_at?: Date;\n\n channel?: ChannelResponse;\n\n message?: Message;\n\n user?: User;\n}\n\nexport interface RepliesMeta {\n depth_truncated: boolean;\n\n has_more: boolean;\n\n remaining: number;\n\n next_cursor?: string;\n}\n\nexport interface Response {\n duration: string;\n}\n\nexport interface RestoreActionRequest {}\n\nexport interface ReviewQueueItem {\n ai_text_severity: string;\n\n bounce_count: number;\n\n config_key: string;\n\n content_changed: boolean;\n\n created_at: Date;\n\n entity_id: string;\n\n entity_type: string;\n\n flags_count: number;\n\n has_image: boolean;\n\n has_text: boolean;\n\n has_video: boolean;\n\n id: string;\n\n moderation_payload_hash: string;\n\n recommended_action: string;\n\n reviewed_by: string;\n\n severity: number;\n\n status: string;\n\n updated_at: Date;\n\n actions: ActionLog[];\n\n bans: Ban[];\n\n flags: Flag[];\n\n languages: string[];\n\n teams: string[];\n\n completed_at: NullTime;\n\n reviewed_at: NullTime;\n\n activity?: EnrichedActivity;\n\n assigned_to?: User;\n\n call?: Call;\n\n entity_creator?: EntityCreator;\n\n feeds_v2_activity?: EnrichedActivity;\n\n feeds_v2_reaction?: Reaction;\n\n message?: Message;\n\n moderation_payload?: ModerationPayload;\n\n reaction?: Reaction;\n}\n\nexport interface ReviewQueueItemResponse {\n ai_text_severity: string;\n\n created_at: Date;\n\n entity_id: string;\n\n entity_type: string;\n\n flags_count: number;\n\n id: string;\n\n recommended_action: string;\n\n reviewed_by: string;\n\n severity: number;\n\n status: string;\n\n updated_at: Date;\n\n actions: ActionLogResponse[];\n\n bans: Ban[];\n\n flags: FlagResponse[];\n\n languages: string[];\n\n completed_at?: Date;\n\n config_key?: string;\n\n entity_creator_id?: string;\n\n reviewed_at?: Date;\n\n teams?: string[];\n\n activity?: EnrichedActivity;\n\n assigned_to?: UserResponse;\n\n call?: CallResponse;\n\n entity_creator?: EntityCreatorResponse;\n\n feeds_v2_activity?: EnrichedActivity;\n\n feeds_v2_reaction?: Reaction;\n\n message?: MessageResponse;\n\n moderation_payload?: ModerationPayload;\n\n reaction?: Reaction;\n}\n\nexport interface RingSettings {\n auto_cancel_timeout_ms: number;\n\n incoming_call_timeout_ms: number;\n\n missed_call_timeout_ms: number;\n}\n\nexport interface RingSettingsResponse {\n auto_cancel_timeout_ms: number;\n\n incoming_call_timeout_ms: number;\n\n missed_call_timeout_ms: number;\n}\n\nexport interface RuleBuilderAction {\n duration?: number;\n\n ip_ban?: boolean;\n\n reason?: string;\n\n shadow_ban?: boolean;\n\n type?: string;\n}\n\nexport interface RuleBuilderCondition {\n provider?: string;\n\n threshold?: number;\n\n time_window?: string;\n\n labels?: string[];\n}\n\nexport interface RuleBuilderConfig {\n async?: boolean;\n\n enabled?: boolean;\n\n rules?: RuleBuilderRule[];\n}\n\nexport interface RuleBuilderRule {\n enabled?: boolean;\n\n id?: string;\n\n name?: string;\n\n conditions?: RuleBuilderCondition[];\n\n action?: RuleBuilderAction;\n}\n\nexport interface SFUIDLastSeen {\n id: string;\n\n last_seen: Date;\n\n process_start_time: number;\n}\n\nexport interface STTEgressConfig {\n closed_captions_enabled?: boolean;\n\n language?: string;\n\n storage_name?: string;\n\n translations_enabled?: boolean;\n\n upload_transcriptions?: boolean;\n\n whisper_server_base_url?: string;\n\n translation_languages?: string[];\n\n external_storage?: ExternalStorage;\n}\n\nexport interface ScreensharingSettings {\n access_request_enabled: boolean;\n\n enabled: boolean;\n\n target_resolution?: TargetResolution;\n}\n\nexport interface ScreensharingSettingsResponse {\n access_request_enabled: boolean;\n\n enabled: boolean;\n\n target_resolution?: TargetResolution;\n}\n\nexport interface SessionSettings {\n inactivity_timeout_seconds: number;\n}\n\nexport interface SessionSettingsResponse {\n inactivity_timeout_seconds: number;\n}\n\nexport interface ShadowBlockActionRequest {}\n\nexport interface SharedLocation {\n channel_cid: string;\n\n created_at: Date;\n\n created_by_device_id: string;\n\n message_id: string;\n\n updated_at: Date;\n\n user_id: string;\n\n end_at?: Date;\n\n latitude?: number;\n\n longitude?: number;\n\n channel?: Channel;\n\n message?: Message;\n}\n\nexport interface SharedLocationResponse {\n channel_cid: string;\n\n created_at: Date;\n\n created_by_device_id: string;\n\n duration: string;\n\n latitude: number;\n\n longitude: number;\n\n message_id: string;\n\n updated_at: Date;\n\n user_id: string;\n\n end_at?: Date;\n\n channel?: ChannelResponse;\n\n message?: MessageResponse;\n}\n\nexport interface SharedLocationResponseData {\n channel_cid: string;\n\n created_at: Date;\n\n created_by_device_id: string;\n\n latitude: number;\n\n longitude: number;\n\n message_id: string;\n\n updated_at: Date;\n\n user_id: string;\n\n end_at?: Date;\n\n channel?: ChannelResponse;\n\n message?: MessageResponse;\n}\n\nexport interface SharedLocationsResponse {\n duration: string;\n\n active_live_locations: SharedLocationResponseData[];\n}\n\nexport interface SingleFollowRequest {\n source: string;\n\n target: string;\n\n push_preference?: 'all' | 'none';\n\n custom?: Record<string, any>;\n}\n\nexport interface SingleFollowResponse {\n duration: string;\n\n follow: FollowResponse;\n}\n\nexport interface SortParamRequest {\n direction?: number;\n\n field?: string;\n}\n\nexport interface StoriesConfig {\n expiration_behaviour?: 'hide_for_everyone' | 'visible_for_author';\n\n skip_watched?: boolean;\n}\n\nexport interface SubmitActionRequest {\n action_type:\n | 'mark_reviewed'\n | 'delete_message'\n | 'delete_activity'\n | 'delete_reaction'\n | 'ban'\n | 'custom'\n | 'unban'\n | 'restore'\n | 'delete_user'\n | 'unblock'\n | 'shadow_block'\n | 'kick_user'\n | 'end_call';\n\n item_id: string;\n\n ban?: BanActionRequest;\n\n custom?: CustomActionRequest;\n\n delete_activity?: DeleteActivityRequest;\n\n delete_message?: DeleteMessageRequest;\n\n delete_reaction?: DeleteReactionRequest;\n\n delete_user?: DeleteUserRequest;\n\n mark_reviewed?: MarkReviewedRequest;\n\n unban?: UnbanActionRequest;\n}\n\nexport interface SubmitActionResponse {\n duration: string;\n\n item?: ReviewQueueItemResponse;\n}\n\nexport interface TargetResolution {\n bitrate: number;\n\n height: number;\n\n width: number;\n}\n\nexport interface ThreadedCommentResponse {\n confidence_score: number;\n\n created_at: Date;\n\n downvote_count: number;\n\n id: string;\n\n object_id: string;\n\n object_type: string;\n\n reaction_count: number;\n\n reply_count: number;\n\n score: number;\n\n status: string;\n\n updated_at: Date;\n\n upvote_count: number;\n\n mentioned_users: UserResponse[];\n\n own_reactions: FeedsReactionResponse[];\n\n user: UserResponse;\n\n controversy_score?: number;\n\n deleted_at?: Date;\n\n parent_id?: string;\n\n text?: string;\n\n attachments?: Attachment[];\n\n latest_reactions?: FeedsReactionResponse[];\n\n replies?: ThreadedCommentResponse[];\n\n custom?: Record<string, any>;\n\n meta?: RepliesMeta;\n\n moderation?: ModerationV2Response;\n\n reaction_groups?: Record<string, ReactionGroupResponse>;\n}\n\nexport interface Thresholds {\n explicit?: LabelThresholds;\n\n spam?: LabelThresholds;\n\n toxic?: LabelThresholds;\n}\n\nexport interface ThumbnailResponse {\n image_url: string;\n}\n\nexport interface ThumbnailsSettings {\n enabled: boolean;\n}\n\nexport interface ThumbnailsSettingsResponse {\n enabled: boolean;\n}\n\nexport interface Time {}\n\nexport interface TranscriptionSettings {\n closed_caption_mode: 'available' | 'disabled' | 'auto-on';\n\n language:\n | 'auto'\n | 'en'\n | 'fr'\n | 'es'\n | 'de'\n | 'it'\n | 'nl'\n | 'pt'\n | 'pl'\n | 'ca'\n | 'cs'\n | 'da'\n | 'el'\n | 'fi'\n | 'id'\n | 'ja'\n | 'ru'\n | 'sv'\n | 'ta'\n | 'th'\n | 'tr'\n | 'hu'\n | 'ro'\n | 'zh'\n | 'ar'\n | 'tl'\n | 'he'\n | 'hi'\n | 'hr'\n | 'ko'\n | 'ms'\n | 'no'\n | 'uk'\n | 'bg'\n | 'et'\n | 'sl'\n | 'sk';\n\n mode: 'available' | 'disabled' | 'auto-on';\n}\n\nexport interface TranscriptionSettingsResponse {\n closed_caption_mode: 'available' | 'disabled' | 'auto-on';\n\n language:\n | 'auto'\n | 'en'\n | 'fr'\n | 'es'\n | 'de'\n | 'it'\n | 'nl'\n | 'pt'\n | 'pl'\n | 'ca'\n | 'cs'\n | 'da'\n | 'el'\n | 'fi'\n | 'id'\n | 'ja'\n | 'ru'\n | 'sv'\n | 'ta'\n | 'th'\n | 'tr'\n | 'hu'\n | 'ro'\n | 'zh'\n | 'ar'\n | 'tl'\n | 'he'\n | 'hi'\n | 'hr'\n | 'ko'\n | 'ms'\n | 'no'\n | 'uk'\n | 'bg'\n | 'et'\n | 'sl'\n | 'sk';\n\n mode: 'available' | 'disabled' | 'auto-on';\n}\n\nexport interface TypingIndicators {\n enabled: boolean;\n}\n\nexport interface TypingIndicatorsResponse {\n enabled: boolean;\n}\n\nexport interface UnbanActionRequest {}\n\nexport interface UnblockActionRequest {}\n\nexport interface UnblockUsersRequest {\n blocked_user_id: string;\n}\n\nexport interface UnblockUsersResponse {\n duration: string;\n}\n\nexport interface UnfollowResponse {\n duration: string;\n}\n\nexport interface UnpinActivityResponse {\n duration: string;\n\n fid: string;\n\n user_id: string;\n\n activity: ActivityResponse;\n}\n\nexport interface UpdateActivityPartialRequest {\n unset?: string[];\n\n set?: Record<string, any>;\n}\n\nexport interface UpdateActivityPartialResponse {\n duration: string;\n\n activity: ActivityResponse;\n}\n\nexport interface UpdateActivityRequest {\n expires_at?: Date;\n\n poll_id?: string;\n\n text?: string;\n\n visibility?: string;\n\n attachments?: Attachment[];\n\n filter_tags?: string[];\n\n interest_tags?: string[];\n\n custom?: Record<string, any>;\n\n location?: ActivityLocation;\n}\n\nexport interface UpdateActivityResponse {\n duration: string;\n\n activity: ActivityResponse;\n}\n\nexport interface UpdateBlockListRequest {\n team?: string;\n\n words?: string[];\n}\n\nexport interface UpdateBlockListResponse {\n duration: string;\n\n blocklist?: BlockListResponse;\n}\n\nexport interface UpdateBookmarkRequest {\n folder_id?: string;\n\n new_folder_id?: string;\n\n custom?: Record<string, any>;\n\n new_folder?: AddFolderRequest;\n}\n\nexport interface UpdateBookmarkResponse {\n duration: string;\n\n bookmark: BookmarkResponse;\n}\n\nexport interface UpdateCommentRequest {\n comment?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface UpdateCommentResponse {\n duration: string;\n\n comment: CommentResponse;\n}\n\nexport interface UpdateFeedMembersRequest {\n operation: 'upsert' | 'remove' | 'set';\n\n limit?: number;\n\n next?: string;\n\n prev?: string;\n\n members?: FeedMemberRequest[];\n}\n\nexport interface UpdateFeedMembersResponse {\n duration: string;\n\n added: FeedMemberResponse[];\n\n removed_ids: string[];\n\n updated: FeedMemberResponse[];\n}\n\nexport interface UpdateFeedRequest {\n created_by_id?: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface UpdateFeedResponse {\n duration: string;\n\n feed: FeedResponse;\n}\n\nexport interface UpdateFollowRequest {\n source: string;\n\n target: string;\n\n follower_role?: string;\n\n push_preference?: 'all' | 'none';\n\n custom?: Record<string, any>;\n}\n\nexport interface UpdateFollowResponse {\n duration: string;\n\n follow: FollowResponse;\n}\n\nexport interface UpdateLiveLocationRequest {\n created_by_device_id: string;\n\n message_id: string;\n\n end_at?: Date;\n\n latitude?: number;\n\n longitude?: number;\n}\n\nexport interface UpdatePollOptionRequest {\n id: string;\n\n text: string;\n\n custom?: Record<string, any>;\n}\n\nexport interface UpdatePollPartialRequest {\n unset?: string[];\n\n set?: Record<string, any>;\n}\n\nexport interface UpdatePollRequest {\n id: string;\n\n name: string;\n\n allow_answers?: boolean;\n\n allow_user_suggested_options?: boolean;\n\n description?: string;\n\n enforce_unique_vote?: boolean;\n\n is_closed?: boolean;\n\n max_votes_allowed?: number;\n\n voting_visibility?: 'anonymous' | 'public';\n\n options?: PollOptionRequest[];\n\n custom?: Record<string, any>;\n}\n\nexport interface UpdateUserPartialRequest {\n id: string;\n\n unset?: string[];\n\n set?: Record<string, any>;\n}\n\nexport interface UpdateUsersPartialRequest {\n users: UpdateUserPartialRequest[];\n}\n\nexport interface UpdateUsersRequest {\n users: Record<string, UserRequest>;\n}\n\nexport interface UpdateUsersResponse {\n duration: string;\n\n membership_deletion_task_id: string;\n\n users: Record<string, FullUserResponse>;\n}\n\nexport interface UpsertActivitiesRequest {\n activities: ActivityRequest[];\n}\n\nexport interface UpsertActivitiesResponse {\n duration: string;\n\n activities: ActivityResponse[];\n}\n\nexport interface UpsertConfigRequest {\n key: string;\n\n async?: boolean;\n\n team?: string;\n\n ai_image_config?: AIImageConfig;\n\n ai_text_config?: AITextConfig;\n\n ai_video_config?: AIVideoConfig;\n\n automod_platform_circumvention_config?: AutomodPlatformCircumventionConfig;\n\n automod_semantic_filters_config?: AutomodSemanticFiltersConfig;\n\n automod_toxicity_config?: AutomodToxicityConfig;\n\n aws_rekognition_config?: AIImageConfig;\n\n block_list_config?: BlockListConfig;\n\n bodyguard_config?: AITextConfig;\n\n google_vision_config?: GoogleVisionConfig;\n\n rule_builder_config?: RuleBuilderConfig;\n\n velocity_filter_config?: VelocityFilterConfig;\n\n video_call_rule_config?: VideoCallRuleConfig;\n}\n\nexport interface UpsertConfigResponse {\n duration: string;\n\n config?: ConfigResponse;\n}\n\nexport interface User {\n banned: boolean;\n\n id: string;\n\n online: boolean;\n\n role: string;\n\n custom: Record<string, any>;\n\n teams_role: Record<string, string>;\n\n ban_expires?: Date;\n\n created_at?: Date;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n invisible?: boolean;\n\n language?: string;\n\n last_active?: Date;\n\n last_engaged_at?: Date;\n\n revoke_tokens_issued_before?: Date;\n\n updated_at?: Date;\n\n teams?: string[];\n\n privacy_settings?: PrivacySettings;\n}\n\nexport interface UserBannedEvent {\n channel_id: string;\n\n channel_type: string;\n\n cid: string;\n\n created_at: Date;\n\n shadow: boolean;\n\n created_by: User;\n\n type: string;\n\n expiration?: Date;\n\n reason?: string;\n\n team?: string;\n\n user?: User;\n}\n\nexport interface UserDeactivatedEvent {\n created_at: Date;\n\n created_by: User;\n\n type: string;\n\n user?: User;\n}\n\nexport interface UserMute {\n created_at: Date;\n\n updated_at: Date;\n\n expires?: Date;\n\n target?: User;\n\n user?: User;\n}\n\nexport interface UserMuteResponse {\n created_at: Date;\n\n updated_at: Date;\n\n expires?: Date;\n\n target?: UserResponse;\n\n user?: UserResponse;\n}\n\nexport interface UserMutedEvent {\n created_at: Date;\n\n type: string;\n\n target_user?: string;\n\n target_users?: string[];\n\n user?: User;\n}\n\nexport interface UserReactivatedEvent {\n created_at: Date;\n\n type: string;\n\n user?: User;\n}\n\nexport interface UserRequest {\n id: string;\n\n image?: string;\n\n invisible?: boolean;\n\n language?: string;\n\n name?: string;\n\n custom?: Record<string, any>;\n\n privacy_settings?: PrivacySettingsResponse;\n}\n\nexport interface UserResponse {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface UserResponseCommonFields {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface UserResponsePrivacyFields {\n banned: boolean;\n\n created_at: Date;\n\n id: string;\n\n language: string;\n\n online: boolean;\n\n role: string;\n\n updated_at: Date;\n\n blocked_user_ids: string[];\n\n teams: string[];\n\n custom: Record<string, any>;\n\n deactivated_at?: Date;\n\n deleted_at?: Date;\n\n image?: string;\n\n invisible?: boolean;\n\n last_active?: Date;\n\n name?: string;\n\n revoke_tokens_issued_before?: Date;\n\n privacy_settings?: PrivacySettingsResponse;\n\n teams_role?: Record<string, string>;\n}\n\nexport interface UserUpdatedEvent {\n created_at: Date;\n\n custom: Record<string, any>;\n\n user: UserResponsePrivacyFields;\n\n type: string;\n\n received_at?: Date;\n}\n\nexport interface VelocityFilterConfig {\n advanced_filters: boolean;\n\n cascading_actions: boolean;\n\n cids_per_user: number;\n\n enabled: boolean;\n\n first_message_only: boolean;\n\n rules: VelocityFilterConfigRule[];\n\n async?: boolean;\n}\n\nexport interface VelocityFilterConfigRule {\n action: 'flag' | 'shadow' | 'remove' | 'ban';\n\n ban_duration: number;\n\n cascading_action: 'flag' | 'shadow' | 'remove' | 'ban';\n\n cascading_threshold: number;\n\n check_message_context: boolean;\n\n fast_spam_threshold: number;\n\n fast_spam_ttl: number;\n\n ip_ban: boolean;\n\n probation_period: number;\n\n shadow_ban: boolean;\n\n slow_spam_threshold: number;\n\n slow_spam_ttl: number;\n\n url_only: boolean;\n\n slow_spam_ban_duration?: number;\n}\n\nexport interface VideoCallRuleConfig {\n rules: Record<string, HarmConfig>;\n}\n\nexport interface VideoEndCallRequest {}\n\nexport interface VideoKickUserRequest {}\n\nexport interface VideoOrientation {\n orientation?: number;\n}\n\nexport interface VideoSettings {\n access_request_enabled: boolean;\n\n camera_default_on: boolean;\n\n camera_facing: 'front' | 'back' | 'external';\n\n enabled: boolean;\n\n target_resolution: TargetResolution;\n}\n\nexport interface VideoSettingsResponse {\n access_request_enabled: boolean;\n\n camera_default_on: boolean;\n\n camera_facing: 'front' | 'back' | 'external';\n\n enabled: boolean;\n\n target_resolution: TargetResolution;\n}\n\nexport interface VoteData {\n answer_text?: string;\n\n option_id?: string;\n}\n\nexport interface WSAuthMessage {\n token: string;\n\n user_details: ConnectUserDetailsRequest;\n\n products?: string[];\n}\n\nexport type WSClientEvent =\n | ({ type: 'app.updated' } & AppUpdatedEvent)\n | ({ type: 'feeds.activity.added' } & ActivityAddedEvent)\n | ({ type: 'feeds.activity.deleted' } & ActivityDeletedEvent)\n | ({ type: 'feeds.activity.marked' } & ActivityMarkEvent)\n | ({ type: 'feeds.activity.pinned' } & ActivityPinnedEvent)\n | ({ type: 'feeds.activity.reaction.added' } & ActivityReactionAddedEvent)\n | ({ type: 'feeds.activity.reaction.deleted' } & ActivityReactionDeletedEvent)\n | ({ type: 'feeds.activity.reaction.updated' } & ActivityReactionUpdatedEvent)\n | ({\n type: 'feeds.activity.removed_from_feed';\n } & ActivityRemovedFromFeedEvent)\n | ({ type: 'feeds.activity.unpinned' } & ActivityUnpinnedEvent)\n | ({ type: 'feeds.activity.updated' } & ActivityUpdatedEvent)\n | ({ type: 'feeds.bookmark.added' } & BookmarkAddedEvent)\n | ({ type: 'feeds.bookmark.deleted' } & BookmarkDeletedEvent)\n | ({ type: 'feeds.bookmark.updated' } & BookmarkUpdatedEvent)\n | ({ type: 'feeds.comment.added' } & CommentAddedEvent)\n | ({ type: 'feeds.comment.deleted' } & CommentDeletedEvent)\n | ({ type: 'feeds.comment.reaction.added' } & CommentReactionAddedEvent)\n | ({ type: 'feeds.comment.reaction.deleted' } & CommentReactionDeletedEvent)\n | ({ type: 'feeds.comment.reaction.updated' } & CommentReactionUpdatedEvent)\n | ({ type: 'feeds.comment.updated' } & CommentUpdatedEvent)\n | ({ type: 'feeds.feed.created' } & FeedCreatedEvent)\n | ({ type: 'feeds.feed.deleted' } & FeedDeletedEvent)\n | ({ type: 'feeds.feed.updated' } & FeedUpdatedEvent)\n | ({ type: 'feeds.feed_group.changed' } & FeedGroupChangedEvent)\n | ({ type: 'feeds.feed_group.deleted' } & FeedGroupDeletedEvent)\n | ({ type: 'feeds.feed_member.added' } & FeedMemberAddedEvent)\n | ({ type: 'feeds.feed_member.removed' } & FeedMemberRemovedEvent)\n | ({ type: 'feeds.feed_member.updated' } & FeedMemberUpdatedEvent)\n | ({ type: 'feeds.follow.created' } & FollowCreatedEvent)\n | ({ type: 'feeds.follow.deleted' } & FollowDeletedEvent)\n | ({ type: 'feeds.follow.updated' } & FollowUpdatedEvent)\n | ({ type: 'feeds.poll.closed' } & PollClosedFeedEvent)\n | ({ type: 'feeds.poll.deleted' } & PollDeletedFeedEvent)\n | ({ type: 'feeds.poll.updated' } & PollUpdatedFeedEvent)\n | ({ type: 'feeds.poll.vote_casted' } & PollVoteCastedFeedEvent)\n | ({ type: 'feeds.poll.vote_changed' } & PollVoteChangedFeedEvent)\n | ({ type: 'feeds.poll.vote_removed' } & PollVoteRemovedFeedEvent)\n | ({ type: 'health.check' } & HealthCheckEvent)\n | ({ type: 'user.updated' } & UserUpdatedEvent);\n\nexport type WSEvent =\n | ({ type: 'app.updated' } & AppUpdatedEvent)\n | ({ type: 'feeds.activity.added' } & ActivityAddedEvent)\n | ({ type: 'feeds.activity.deleted' } & ActivityDeletedEvent)\n | ({ type: 'feeds.activity.marked' } & ActivityMarkEvent)\n | ({ type: 'feeds.activity.pinned' } & ActivityPinnedEvent)\n | ({ type: 'feeds.activity.reaction.added' } & ActivityReactionAddedEvent)\n | ({ type: 'feeds.activity.reaction.deleted' } & ActivityReactionDeletedEvent)\n | ({ type: 'feeds.activity.reaction.updated' } & ActivityReactionUpdatedEvent)\n | ({\n type: 'feeds.activity.removed_from_feed';\n } & ActivityRemovedFromFeedEvent)\n | ({ type: 'feeds.activity.unpinned' } & ActivityUnpinnedEvent)\n | ({ type: 'feeds.activity.updated' } & ActivityUpdatedEvent)\n | ({ type: 'feeds.bookmark.added' } & BookmarkAddedEvent)\n | ({ type: 'feeds.bookmark.deleted' } & BookmarkDeletedEvent)\n | ({ type: 'feeds.bookmark.updated' } & BookmarkUpdatedEvent)\n | ({ type: 'feeds.comment.added' } & CommentAddedEvent)\n | ({ type: 'feeds.comment.deleted' } & CommentDeletedEvent)\n | ({ type: 'feeds.comment.reaction.added' } & CommentReactionAddedEvent)\n | ({ type: 'feeds.comment.reaction.deleted' } & CommentReactionDeletedEvent)\n | ({ type: 'feeds.comment.reaction.updated' } & CommentReactionUpdatedEvent)\n | ({ type: 'feeds.comment.updated' } & CommentUpdatedEvent)\n | ({ type: 'feeds.feed.created' } & FeedCreatedEvent)\n | ({ type: 'feeds.feed.deleted' } & FeedDeletedEvent)\n | ({ type: 'feeds.feed.updated' } & FeedUpdatedEvent)\n | ({ type: 'feeds.feed_group.changed' } & FeedGroupChangedEvent)\n | ({ type: 'feeds.feed_group.deleted' } & FeedGroupDeletedEvent)\n | ({ type: 'feeds.feed_member.added' } & FeedMemberAddedEvent)\n | ({ type: 'feeds.feed_member.removed' } & FeedMemberRemovedEvent)\n | ({ type: 'feeds.feed_member.updated' } & FeedMemberUpdatedEvent)\n | ({ type: 'feeds.follow.created' } & FollowCreatedEvent)\n | ({ type: 'feeds.follow.deleted' } & FollowDeletedEvent)\n | ({ type: 'feeds.follow.updated' } & FollowUpdatedEvent)\n | ({ type: 'feeds.poll.closed' } & PollClosedFeedEvent)\n | ({ type: 'feeds.poll.deleted' } & PollDeletedFeedEvent)\n | ({ type: 'feeds.poll.updated' } & PollUpdatedFeedEvent)\n | ({ type: 'feeds.poll.vote_casted' } & PollVoteCastedFeedEvent)\n | ({ type: 'feeds.poll.vote_changed' } & PollVoteChangedFeedEvent)\n | ({ type: 'feeds.poll.vote_removed' } & PollVoteRemovedFeedEvent)\n | ({ type: 'health.check' } & HealthCheckEvent)\n | ({ type: 'moderation.custom_action' } & ModerationCustomActionEvent)\n | ({ type: 'moderation.flagged' } & ModerationFlaggedEvent)\n | ({ type: 'moderation.mark_reviewed' } & ModerationMarkReviewedEvent)\n | ({ type: 'user.banned' } & UserBannedEvent)\n | ({ type: 'user.deactivated' } & UserDeactivatedEvent)\n | ({ type: 'user.muted' } & UserMutedEvent)\n | ({ type: 'user.reactivated' } & UserReactivatedEvent)\n | ({ type: 'user.updated' } & UserUpdatedEvent);\n","import { useMemo } from 'react';\nimport type { Feed, FeedState } from '../../src/Feed';\nimport { FeedOwnCapability } from '../../src/gen/models';\nimport { useStateStore } from './useStateStore';\n\nconst stableEmptyArray: readonly FeedOwnCapability[] = [];\n\nconst selector = (currentState: FeedState) => ({\n oc: currentState.own_capabilities ?? stableEmptyArray,\n});\n\ntype KebabToCamelCase<S extends string> = S extends `${infer T}-${infer U}`\n ? `${T}${Capitalize<KebabToCamelCase<U>>}`\n : S;\n\nexport const useOwnCapabilities = (feed: Feed | undefined) => {\n const { oc = stableEmptyArray } = useStateStore(feed?.state, selector) ?? {};\n\n return useMemo(\n () =>\n ({\n canAddActivity: oc.indexOf(FeedOwnCapability.ADD_ACTIVITY) > -1,\n canAddActivityReaction:\n oc.indexOf(FeedOwnCapability.ADD_ACTIVITY_REACTION) > -1,\n canAddComment: oc.indexOf(FeedOwnCapability.ADD_COMMENT) > -1,\n canAddCommentReaction:\n oc.indexOf(FeedOwnCapability.ADD_COMMENT_REACTION) > -1,\n canBookmarkActivity:\n oc.indexOf(FeedOwnCapability.BOOKMARK_ACTIVITY) > -1,\n canCreateFeed: oc.indexOf(FeedOwnCapability.CREATE_FEED) > -1,\n canDeleteBookmark: oc.indexOf(FeedOwnCapability.DELETE_BOOKMARK) > -1,\n canDeleteComment: oc.indexOf(FeedOwnCapability.DELETE_COMMENT) > -1,\n canDeleteFeed: oc.indexOf(FeedOwnCapability.DELETE_FEED) > -1,\n canEditBookmark: oc.indexOf(FeedOwnCapability.EDIT_BOOKMARK) > -1,\n canFollow: oc.indexOf(FeedOwnCapability.FOLLOW) > -1,\n canRemoveActivity: oc.indexOf(FeedOwnCapability.REMOVE_ACTIVITY) > -1,\n canRemoveActivityReaction:\n oc.indexOf(FeedOwnCapability.REMOVE_ACTIVITY_REACTION) > -1,\n canRemoveCommentReaction:\n oc.indexOf(FeedOwnCapability.REMOVE_COMMENT_REACTION) > -1,\n canUnfollow: oc.indexOf(FeedOwnCapability.UNFOLLOW) > -1,\n canUpdateFeed: oc.indexOf(FeedOwnCapability.UPDATE_FEED) > -1,\n canInviteFeed: oc.indexOf(FeedOwnCapability.INVITE_FEED) > -1,\n canJoinFeed: oc.indexOf(FeedOwnCapability.JOIN_FEED) > -1,\n canLeaveFeed: oc.indexOf(FeedOwnCapability.LEAVE_FEED) > -1,\n canManageFeedGroup:\n oc.indexOf(FeedOwnCapability.MANAGE_FEED_GROUP) > -1,\n canMarkActivity: oc.indexOf(FeedOwnCapability.MARK_ACTIVITY) > -1,\n canPinActivity: oc.indexOf(FeedOwnCapability.PIN_ACTIVITY) > -1,\n canQueryFeedMembers:\n oc.indexOf(FeedOwnCapability.QUERY_FEED_MEMBERS) > -1,\n canQueryFollows: oc.indexOf(FeedOwnCapability.QUERY_FOLLOWS) > -1,\n canReadActivities: oc.indexOf(FeedOwnCapability.READ_ACTIVITIES) > -1,\n canReadFeed: oc.indexOf(FeedOwnCapability.READ_FEED) > -1,\n canUpdateActivity: oc.indexOf(FeedOwnCapability.UPDATE_ACTIVITY) > -1,\n canUpdateComment: oc.indexOf(FeedOwnCapability.UPDATE_COMMENT) > -1,\n canUpdateFeedFollowers:\n oc.indexOf(FeedOwnCapability.UPDATE_FEED_FOLLOWERS) > -1,\n canUpdateFeedMembers:\n oc.indexOf(FeedOwnCapability.UPDATE_FEED_MEMBERS) > -1,\n }) satisfies Record<\n `can${Capitalize<KebabToCamelCase<(typeof FeedOwnCapability)[keyof typeof FeedOwnCapability]>>}`,\n boolean\n >,\n [oc],\n );\n};\n"],"names":["useCallback","useMemo","useSyncExternalStore"],"mappings":";;;;AAGA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
54
|
+
ADD_ACTIVITY_REACTION: 'add-activity-reaction',
|
|
55
|
+
ADD_COMMENT: 'add-comment',
|
|
56
|
+
ADD_COMMENT_REACTION: 'add-comment-reaction',
|
|
57
|
+
BOOKMARK_ACTIVITY: 'bookmark-activity',
|
|
58
|
+
CREATE_FEED: 'create-feed',
|
|
59
|
+
DELETE_BOOKMARK: 'delete-bookmark',
|
|
60
|
+
DELETE_COMMENT: 'delete-comment',
|
|
61
|
+
DELETE_FEED: 'delete-feed',
|
|
62
|
+
EDIT_BOOKMARK: 'edit-bookmark',
|
|
63
|
+
FOLLOW: 'follow',
|
|
64
|
+
INVITE_FEED: 'invite-feed',
|
|
65
|
+
JOIN_FEED: 'join-feed',
|
|
66
|
+
LEAVE_FEED: 'leave-feed',
|
|
67
|
+
MANAGE_FEED_GROUP: 'manage-feed-group',
|
|
68
|
+
MARK_ACTIVITY: 'mark-activity',
|
|
69
|
+
PIN_ACTIVITY: 'pin-activity',
|
|
70
|
+
QUERY_FEED_MEMBERS: 'query-feed-members',
|
|
71
|
+
QUERY_FOLLOWS: 'query-follows',
|
|
72
|
+
READ_ACTIVITIES: 'read-activities',
|
|
73
|
+
READ_FEED: 'read-feed',
|
|
74
|
+
REMOVE_ACTIVITY: 'remove-activity',
|
|
75
|
+
REMOVE_ACTIVITY_REACTION: 'remove-activity-reaction',
|
|
76
|
+
REMOVE_COMMENT_REACTION: 'remove-comment-reaction',
|
|
77
|
+
UNFOLLOW: 'unfollow',
|
|
78
|
+
UPDATE_ACTIVITY: 'update-activity',
|
|
79
|
+
UPDATE_COMMENT: 'update-comment',
|
|
80
|
+
UPDATE_FEED: 'update-feed',
|
|
81
|
+
UPDATE_FEED_FOLLOWERS: 'update-feed-followers',
|
|
82
|
+
UPDATE_FEED_MEMBERS: 'update-feed-members',
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
const stableEmptyArray = [];
|
|
86
|
+
const selector = (currentState) => ({
|
|
87
|
+
oc: currentState.own_capabilities ?? stableEmptyArray,
|
|
88
|
+
});
|
|
89
|
+
const useOwnCapabilities = (feed) => {
|
|
90
|
+
const { oc = stableEmptyArray } = useStateStore(feed?.state, selector) ?? {};
|
|
91
|
+
return useMemo(() => ({
|
|
92
|
+
canAddActivity: oc.indexOf(FeedOwnCapability.ADD_ACTIVITY) > -1,
|
|
93
|
+
canAddActivityReaction: oc.indexOf(FeedOwnCapability.ADD_ACTIVITY_REACTION) > -1,
|
|
94
|
+
canAddComment: oc.indexOf(FeedOwnCapability.ADD_COMMENT) > -1,
|
|
95
|
+
canAddCommentReaction: oc.indexOf(FeedOwnCapability.ADD_COMMENT_REACTION) > -1,
|
|
96
|
+
canBookmarkActivity: oc.indexOf(FeedOwnCapability.BOOKMARK_ACTIVITY) > -1,
|
|
97
|
+
canCreateFeed: oc.indexOf(FeedOwnCapability.CREATE_FEED) > -1,
|
|
98
|
+
canDeleteBookmark: oc.indexOf(FeedOwnCapability.DELETE_BOOKMARK) > -1,
|
|
99
|
+
canDeleteComment: oc.indexOf(FeedOwnCapability.DELETE_COMMENT) > -1,
|
|
100
|
+
canDeleteFeed: oc.indexOf(FeedOwnCapability.DELETE_FEED) > -1,
|
|
101
|
+
canEditBookmark: oc.indexOf(FeedOwnCapability.EDIT_BOOKMARK) > -1,
|
|
102
|
+
canFollow: oc.indexOf(FeedOwnCapability.FOLLOW) > -1,
|
|
103
|
+
canRemoveActivity: oc.indexOf(FeedOwnCapability.REMOVE_ACTIVITY) > -1,
|
|
104
|
+
canRemoveActivityReaction: oc.indexOf(FeedOwnCapability.REMOVE_ACTIVITY_REACTION) > -1,
|
|
105
|
+
canRemoveCommentReaction: oc.indexOf(FeedOwnCapability.REMOVE_COMMENT_REACTION) > -1,
|
|
106
|
+
canUnfollow: oc.indexOf(FeedOwnCapability.UNFOLLOW) > -1,
|
|
107
|
+
canUpdateFeed: oc.indexOf(FeedOwnCapability.UPDATE_FEED) > -1,
|
|
108
|
+
canInviteFeed: oc.indexOf(FeedOwnCapability.INVITE_FEED) > -1,
|
|
109
|
+
canJoinFeed: oc.indexOf(FeedOwnCapability.JOIN_FEED) > -1,
|
|
110
|
+
canLeaveFeed: oc.indexOf(FeedOwnCapability.LEAVE_FEED) > -1,
|
|
111
|
+
canManageFeedGroup: oc.indexOf(FeedOwnCapability.MANAGE_FEED_GROUP) > -1,
|
|
112
|
+
canMarkActivity: oc.indexOf(FeedOwnCapability.MARK_ACTIVITY) > -1,
|
|
113
|
+
canPinActivity: oc.indexOf(FeedOwnCapability.PIN_ACTIVITY) > -1,
|
|
114
|
+
canQueryFeedMembers: oc.indexOf(FeedOwnCapability.QUERY_FEED_MEMBERS) > -1,
|
|
115
|
+
canQueryFollows: oc.indexOf(FeedOwnCapability.QUERY_FOLLOWS) > -1,
|
|
116
|
+
canReadActivities: oc.indexOf(FeedOwnCapability.READ_ACTIVITIES) > -1,
|
|
117
|
+
canReadFeed: oc.indexOf(FeedOwnCapability.READ_FEED) > -1,
|
|
118
|
+
canUpdateActivity: oc.indexOf(FeedOwnCapability.UPDATE_ACTIVITY) > -1,
|
|
119
|
+
canUpdateComment: oc.indexOf(FeedOwnCapability.UPDATE_COMMENT) > -1,
|
|
120
|
+
canUpdateFeedFollowers: oc.indexOf(FeedOwnCapability.UPDATE_FEED_FOLLOWERS) > -1,
|
|
121
|
+
canUpdateFeedMembers: oc.indexOf(FeedOwnCapability.UPDATE_FEED_MEMBERS) > -1,
|
|
122
|
+
}), [oc]);
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
export { useComments, useOwnCapabilities, useStateStore };
|
|
53
126
|
//# sourceMappingURL=index-react-bindings.node.js.map
|