diff --git a/CHANGELOG.md b/CHANGELOG.md index b2cef3a..f8382ea 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,12 +10,17 @@ * `TaskError < StreamError`. Raised by `wait_for_task` when an async task finishes with `status="failed"`. Exposes `task_id`, `error_type`, `description`, `stack_trace`, `version`. - New `Client#wait_for_task(task_id, poll_interval: 1, timeout: 60)` helper. Polls `/api/v2/tasks/:id` and: returns the task `result` payload when status reaches `completed`; raises `TaskError` when status reaches `failed`; raises `TransportError` with `error_type: "timeout"` when the deadline elapses. - `Client#post` (and the multipart upload path) now deserialize the full canonical `APIError` envelope (`code`, `message`, `exception_fields`, `more_info`, `StatusCode`, `details`, `unrecoverable`, `duration`) and populate the new `ApiError` attributes. +- Regenerated from the latest chat OpenAPI spec. New endpoints: `Moderation#analyze`, `Moderation#bulk_action_appeals`, `Moderation#get_setup_session`, `Moderation#upsert_setup_session`; `Feeds#get_or_create_follow`, `Feeds#get_or_create_unfollow`, `Feeds#get_user_interests`; `Chat#create_segment`, `Chat#update_segment`, `Chat#add_segment_targets`; `Common#cancel_import_v2_task`; `Video#report_client_call_event`, together with the request and response models backing them. +- New webhook event types `moderation.image_analysis.complete` and `moderation.text_analysis.complete`, parsed into `ModerationImageAnalysisCompleteEvent` and `ModerationTextAnalysisCompleteEvent`. ### Changed - The old `GetStreamRuby::APIError` constant remains as a deprecated alias for `GetStreamRuby::ApiError` for one minor cycle, slated for removal in v9.0. First access emits a one-time `Kernel.warn` deprecation notice. - The old `GetStreamRuby::Error` constant is preserved as an alias for `StreamError`. Existing `rescue GetStreamRuby::Error` clauses continue to match. - Pre-flight multipart validation (`file name must be provided`, `file not found`) now raises `ArgumentError` instead of the old `APIError`. These are caller-side programming errors and don't belong on the API-error surface. +- `Models::FlagResponse` now represents the full flag record (`created_at`, `updated_at`, `target_message`, `target_user`, `user`, `reason`, `details`, `custom`, and related fields). The moderation flag-action acknowledgement, which carries `item_id` and `duration`, moved to the new `Models::FlagItemResponse`; `Moderation#flag` now returns `FlagItemResponse`. The wire response of `/api/v2/moderation/flag` is unchanged, only the model name changed, so code reading `item_id`/`duration` off the parsed response is unaffected. Code referencing the `FlagResponse` model class for those two fields should switch to `FlagItemResponse`. +- `ChannelInput#config_overrides` and `ChannelDataUpdate#config_overrides` are now typed as `ChannelConfigOverrides` (the override-specific field set) instead of the full `ChannelConfig`. +- `LLMRule#description` and `TargetResolution#bitrate` are now optional. ### Webhook helpers diff --git a/lib/getstream_ruby/generated/chat_client.rb b/lib/getstream_ruby/generated/chat_client.rb index ad0429c..9a52c4a 100644 --- a/lib/getstream_ruby/generated/chat_client.rb +++ b/lib/getstream_ruby/generated/chat_client.rb @@ -1540,6 +1540,23 @@ def search(payload = nil) ) end + # Create a segment + # + # @param create_segment_request [CreateSegmentRequest] + # @return [Models::CreateSegmentResponse] + def create_segment(create_segment_request) + path = '/api/v2/chat/segments' + # Build request body + body = create_segment_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Query segments # # @param query_segments_request [QuerySegmentsRequest] @@ -1589,6 +1606,46 @@ def get_segment(_id) ) end + # Update an existing segment + # + # @param _id [String] + # @param update_segment_request [UpdateSegmentRequest] + # @return [Models::UpdateSegmentResponse] + def update_segment(_id, update_segment_request) + path = '/api/v2/chat/segments/{id}' + # Replace path parameters + path = path.gsub('{id}', _id.to_s) + # Build request body + body = update_segment_request + + # Make the API request + @client.make_request( + :put, + path, + body: body + ) + end + + # Add targets to a segment + # + # @param _id [String] + # @param add_segment_targets_request [AddSegmentTargetsRequest] + # @return [Models::Response] + def add_segment_targets(_id, add_segment_targets_request) + path = '/api/v2/chat/segments/{id}/addtargets' + # Replace path parameters + path = path.gsub('{id}', _id.to_s) + # Build request body + body = add_segment_targets_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Delete targets from a segment # # @param _id [String] diff --git a/lib/getstream_ruby/generated/common_client.rb b/lib/getstream_ruby/generated/common_client.rb index 566be57..bd7da47 100644 --- a/lib/getstream_ruby/generated/common_client.rb +++ b/lib/getstream_ruby/generated/common_client.rb @@ -531,6 +531,22 @@ def get_import_v2_task(_id) ) end + # Requests a controlled stop of an import v2 task. Allowed only for tasks in queued or processing state; a processing import stops cleanly on its next progress tick. + # + # @param _id [String] + # @return [Models::CancelImportV2TaskResponse] + def cancel_import_v2_task(_id) + path = '/api/v2/imports/v2/{id}/cancel' + # Replace path parameters + path = path.gsub('{id}', _id.to_s) + + # Make the API request + @client.make_request( + :post, + path + ) + end + # Gets an import # # @param _id [String] diff --git a/lib/getstream_ruby/generated/feeds_client.rb b/lib/getstream_ruby/generated/feeds_client.rb index fd461b9..39b0fdf 100644 --- a/lib/getstream_ruby/generated/feeds_client.rb +++ b/lib/getstream_ruby/generated/feeds_client.rb @@ -1746,6 +1746,23 @@ def reject_follow(reject_follow_request) ) end + # Creates a follow if it does not exist, or returns the existing one. Broadcasts feeds.follow.created (FollowCreatedEvent) only when the follow is newly created. + # + # @param follow_request [FollowRequest] + # @return [Models::GetOrCreateFollowResponse] + def get_or_create_follow(follow_request) + path = '/api/v2/feeds/follows/upsert' + # Build request body + body = follow_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Removes a follow and broadcasts FollowRemovedEvent # # @param source [String] @@ -1911,6 +1928,23 @@ def get_or_create_unfollows(unfollow_batch_request) ) end + # Removes a follow and broadcasts feeds.follow.deleted (FollowDeletedEvent). Does not return an error if the follow does not exist. + # + # @param get_or_create_unfollow_request [GetOrCreateUnfollowRequest] + # @return [Models::GetOrCreateUnfollowResponse] + def get_or_create_unfollow(get_or_create_unfollow_request) + path = '/api/v2/feeds/unfollow/upsert' + # Build request body + body = get_or_create_unfollow_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Delete all feed data for a user including: feeds, activities, follows, comments, feed reactions, bookmark folders, bookmarks, and collections owned by the user # # @param user_id [String] @@ -1947,6 +1981,27 @@ def export_feed_user_data(user_id) ) end + # Returns the user's most common interest tags ranked by the number of distinct activities they reacted to that carried each tag. Client-side callers may only read their own interests; server-side callers may fetch any user. Results are sorted by descending count, then alphabetically by tag. + # + # @param user_id [String] + # @param limit [Integer] + # @return [Models::GetUserInterestsResponse] + def get_user_interests(user_id, limit = nil) + path = '/api/v2/feeds/users/{user_id}/interests' + # Replace path parameters + path = path.gsub('{user_id}', user_id.to_s) + # Build query parameters + query_params = {} + query_params['limit'] = limit unless limit.nil? + + # Make the API request + @client.make_request( + :get, + path, + query_params: query_params + ) + end + end end end \ No newline at end of file diff --git a/lib/getstream_ruby/generated/models/add_segment_targets_request.rb b/lib/getstream_ruby/generated/models/add_segment_targets_request.rb new file mode 100644 index 0000000..9a6c4d3 --- /dev/null +++ b/lib/getstream_ruby/generated/models/add_segment_targets_request.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class AddSegmentTargetsRequest < GetStream::BaseModel + + # Model attributes + # @!attribute target_ids + # @return [Array] Target IDs + attr_accessor :target_ids + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @target_ids = attributes[:target_ids] || attributes['target_ids'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + target_ids: 'target_ids' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/analyze_image_field.rb b/lib/getstream_ruby/generated/models/analyze_image_field.rb new file mode 100644 index 0000000..7794165 --- /dev/null +++ b/lib/getstream_ruby/generated/models/analyze_image_field.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class AnalyzeImageField < GetStream::BaseModel + + # Model attributes + # @!attribute action + # @return [String] Per-image action: keep | flag | remove. + attr_accessor :action + # @!attribute confidence + # @return [Float] Highest confidence (0–1) across detected classifications + sub-classifications. Convenience aggregate over the nested values in `classifications`. + attr_accessor :confidence + # @!attribute error + # @return [String] Set when moderation couldn't be determined for this image — action is absent. + attr_accessor :error + # @!attribute id + # @return [String] Echo of `content_ids[label]` when supplied on the request; omitted otherwise. + attr_accessor :id + # @!attribute classifications + # @return [Array] Hierarchical list of L1 (parent) classifications. Each entry: `name`, `confidence` (0–1), and nested `subclassifications` (L2 leaves with their own confidence). Resolved against the app's effective taxonomy (custom taxonomy when configured, otherwise the standard Bodyguard catalogue). + attr_accessor :classifications + # @!attribute ocr_classifications + # @return [Array] Flat list of Bodyguard OCR text-moderation labels on the image's extracted text (e.g. VULGARITY, PII). Each entry: `name` + `severity`. Populated when BG's OCR pipeline returned non-empty results for this image. + attr_accessor :ocr_classifications + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @action = attributes[:action] || attributes['action'] || nil + @confidence = attributes[:confidence] || attributes['confidence'] || nil + @error = attributes[:error] || attributes['error'] || nil + @id = attributes[:id] || attributes['id'] || nil + @classifications = attributes[:classifications] || attributes['classifications'] || nil + @ocr_classifications = attributes[:ocr_classifications] || attributes['ocr_classifications'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + action: 'action', + confidence: 'confidence', + error: 'error', + id: 'id', + classifications: 'classifications', + ocr_classifications: 'ocr_classifications' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/analyze_request.rb b/lib/getstream_ruby/generated/models/analyze_request.rb new file mode 100644 index 0000000..00a6666 --- /dev/null +++ b/lib/getstream_ruby/generated/models/analyze_request.rb @@ -0,0 +1,81 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class AnalyzeRequest < GetStream::BaseModel + + # Model attributes + # @!attribute async_response + # @return [Boolean] When true, the response carries no verdicts (status `pending`) and per-modality results arrive via `moderation.text_analysis.complete` and `moderation.image_analysis.complete` webhooks. Image moderation runs on a background worker; text moderation runs synchronously and is then delivered via webhook. + attr_accessor :async_response + # @!attribute config_key + # @return [String] Moderation policy key. Optional in stateful mode, required in stateless mode. + attr_accessor :config_key + # @!attribute content_published_at + # @return [DateTime] Original timestamp when the content was produced. Used as the `published_at` timestamp on per-content log entries that surface in `matched_contents` on aggregation-rule webhooks. + attr_accessor :content_published_at + # @!attribute entity_creator_id + # @return [String] ID of the user who created the content. Required with entity_type + entity_id; omit all three for stateless mode. + attr_accessor :entity_creator_id + # @!attribute entity_id + # @return [String] Caller-supplied content identifier. Required with entity_type + entity_creator_id; omit all three for stateless mode. + attr_accessor :entity_id + # @!attribute entity_type + # @return [String] Caller-defined entity type. Required with entity_id + entity_creator_id; omit all three for stateless mode. + attr_accessor :entity_type + # @!attribute user_id + # @return [String] + attr_accessor :user_id + # @!attribute content_ids + # @return [Hash] Optional map from a content label (either a `texts` key or an `image:` multipart label) to a caller-supplied per-instance identifier. Echoed on per-field verdicts and surfaced in `matched_contents` when an aggregation rule fires. + attr_accessor :content_ids + # @!attribute custom + # @return [Object] Arbitrary metadata surfaced in the dashboard. + attr_accessor :custom + # @!attribute texts + # @return [Hash] Named text fields to moderate, keyed by caller label (e.g. title, description). + attr_accessor :texts + # @!attribute user + # @return [UserRequest] + attr_accessor :user + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @async_response = attributes[:async_response] || attributes['async_response'] || nil + @config_key = attributes[:config_key] || attributes['config_key'] || nil + @content_published_at = attributes[:content_published_at] || attributes['content_published_at'] || nil + @entity_creator_id = attributes[:entity_creator_id] || attributes['entity_creator_id'] || nil + @entity_id = attributes[:entity_id] || attributes['entity_id'] || nil + @entity_type = attributes[:entity_type] || attributes['entity_type'] || nil + @user_id = attributes[:user_id] || attributes['user_id'] || nil + @content_ids = attributes[:content_ids] || attributes['content_ids'] || nil + @custom = attributes[:custom] || attributes['custom'] || nil + @texts = attributes[:texts] || attributes['texts'] || nil + @user = attributes[:user] || attributes['user'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + async_response: 'async_response', + config_key: 'config_key', + content_published_at: 'content_published_at', + entity_creator_id: 'entity_creator_id', + entity_id: 'entity_id', + entity_type: 'entity_type', + user_id: 'user_id', + content_ids: 'content_ids', + custom: 'custom', + texts: 'texts', + user: 'user' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/analyze_response.rb b/lib/getstream_ruby/generated/models/analyze_response.rb new file mode 100644 index 0000000..cbbb7cb --- /dev/null +++ b/lib/getstream_ruby/generated/models/analyze_response.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class AnalyzeResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute status + # @return [String] Always `complete` — /analyze is sync-only and the full verdict is in the response. + attr_accessor :status + # @!attribute images + # @return [Hash] Per-image moderation verdicts keyed by caller label. + attr_accessor :images + # @!attribute texts + # @return [Hash] Per-text-field moderation verdicts keyed by caller label. + attr_accessor :texts + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @status = attributes[:status] || attributes['status'] + @images = attributes[:images] || attributes['images'] || nil + @texts = attributes[:texts] || attributes['texts'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + status: 'status', + images: 'images', + texts: 'texts' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/analyze_text_field.rb b/lib/getstream_ruby/generated/models/analyze_text_field.rb new file mode 100644 index 0000000..ae6fccb --- /dev/null +++ b/lib/getstream_ruby/generated/models/analyze_text_field.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class AnalyzeTextField < GetStream::BaseModel + + # Model attributes + # @!attribute action + # @return [String] Per-field action: keep | flag | remove. + attr_accessor :action + # @!attribute error + # @return [String] Set when moderation couldn't be determined for this field — action is absent. + attr_accessor :error + # @!attribute id + # @return [String] Echo of `content_ids[label]` when supplied on the request; omitted otherwise. + attr_accessor :id + # @!attribute language + # @return [String] Detected language code. + attr_accessor :language + # @!attribute severity + # @return [String] Aggregate severity across the field: LOW | MEDIUM | HIGH | CRITICAL. + attr_accessor :severity + # @!attribute classifications + # @return [Array] Flat list of detected Bodyguard text labels (e.g. INSULT, VULGARITY). Each entry carries `name` and `severity`. + attr_accessor :classifications + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @action = attributes[:action] || attributes['action'] || nil + @error = attributes[:error] || attributes['error'] || nil + @id = attributes[:id] || attributes['id'] || nil + @language = attributes[:language] || attributes['language'] || nil + @severity = attributes[:severity] || attributes['severity'] || nil + @classifications = attributes[:classifications] || attributes['classifications'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + action: 'action', + error: 'error', + id: 'id', + language: 'language', + severity: 'severity', + classifications: 'classifications' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/app_response_fields.rb b/lib/getstream_ruby/generated/models/app_response_fields.rb index 0176073..83d15a6 100644 --- a/lib/getstream_ruby/generated/models/app_response_fields.rb +++ b/lib/getstream_ruby/generated/models/app_response_fields.rb @@ -150,15 +150,24 @@ class AppResponseFields < GetStream::BaseModel # @!attribute push_notifications # @return [PushNotificationFields] attr_accessor :push_notifications + # @!attribute before_message_send_hook_attempt_timeout_ms + # @return [Integer] + attr_accessor :before_message_send_hook_attempt_timeout_ms # @!attribute before_message_send_hook_url # @return [String] attr_accessor :before_message_send_hook_url + # @!attribute moderation_onboarding_complete + # @return [Boolean] + attr_accessor :moderation_onboarding_complete # @!attribute moderation_s3_image_access_role_arn # @return [String] attr_accessor :moderation_s3_image_access_role_arn # @!attribute revoke_tokens_issued_before # @return [DateTime] attr_accessor :revoke_tokens_issued_before + # @!attribute video_primary_use_case + # @return [String] + attr_accessor :video_primary_use_case # @!attribute allowed_flag_reasons # @return [Array] attr_accessor :allowed_flag_reasons @@ -228,9 +237,12 @@ def initialize(attributes = {}) @image_upload_config = attributes[:image_upload_config] || attributes['image_upload_config'] @policies = attributes[:policies] || attributes['policies'] @push_notifications = attributes[:push_notifications] || attributes['push_notifications'] + @before_message_send_hook_attempt_timeout_ms = attributes[:before_message_send_hook_attempt_timeout_ms] || attributes['before_message_send_hook_attempt_timeout_ms'] || nil @before_message_send_hook_url = attributes[:before_message_send_hook_url] || attributes['before_message_send_hook_url'] || nil + @moderation_onboarding_complete = attributes[:moderation_onboarding_complete] || attributes['moderation_onboarding_complete'] || nil @moderation_s3_image_access_role_arn = attributes[:moderation_s3_image_access_role_arn] || attributes['moderation_s3_image_access_role_arn'] || nil @revoke_tokens_issued_before = attributes[:revoke_tokens_issued_before] || attributes['revoke_tokens_issued_before'] || nil + @video_primary_use_case = attributes[:video_primary_use_case] || attributes['video_primary_use_case'] || nil @allowed_flag_reasons = attributes[:allowed_flag_reasons] || attributes['allowed_flag_reasons'] || nil @geofences = attributes[:geofences] || attributes['geofences'] || nil @image_moderation_labels = attributes[:image_moderation_labels] || attributes['image_moderation_labels'] || nil @@ -289,9 +301,12 @@ def self.json_field_mappings image_upload_config: 'image_upload_config', policies: 'policies', push_notifications: 'push_notifications', + before_message_send_hook_attempt_timeout_ms: 'before_message_send_hook_attempt_timeout_ms', before_message_send_hook_url: 'before_message_send_hook_url', + moderation_onboarding_complete: 'moderation_onboarding_complete', moderation_s3_image_access_role_arn: 'moderation_s3_image_access_role_arn', revoke_tokens_issued_before: 'revoke_tokens_issued_before', + video_primary_use_case: 'video_primary_use_case', allowed_flag_reasons: 'allowed_flag_reasons', geofences: 'geofences', image_moderation_labels: 'image_moderation_labels', diff --git a/lib/getstream_ruby/generated/models/appeal_item_response.rb b/lib/getstream_ruby/generated/models/appeal_item_response.rb index dc30320..4beab2b 100644 --- a/lib/getstream_ruby/generated/models/appeal_item_response.rb +++ b/lib/getstream_ruby/generated/models/appeal_item_response.rb @@ -30,15 +30,51 @@ class AppealItemResponse < GetStream::BaseModel # @!attribute updated_at # @return [DateTime] When the flag was last updated attr_accessor :updated_at + # @!attribute ai_text_severity + # @return [String] Text severity level assigned by the AI provider + attr_accessor :ai_text_severity + # @!attribute channel_cid + # @return [String] CID of the channel the entity belongs to, if applicable + attr_accessor :channel_cid + # @!attribute config_key + # @return [String] Moderation policy key that was applied + attr_accessor :config_key # @!attribute decision_reason # @return [String] Decision Reason of the Appeal Item attr_accessor :decision_reason + # @!attribute recommended_action + # @return [String] Action recommended by the automated moderation system (e.g. flag, remove, shadow) + attr_accessor :recommended_action + # @!attribute review_queue_item_id + # @return [String] ID of the review queue item linked to this appeal, if the appeal was submitted with one + attr_accessor :review_queue_item_id + # @!attribute severity + # @return [Integer] Overall content severity score (1–100) + attr_accessor :severity + # @!attribute actions + # @return [Array] Full chronological history of all moderation actions on the review queue item + attr_accessor :actions # @!attribute attachments # @return [Array] Attachments(e.g. Images) of the Appeal Item attr_accessor :attachments + # @!attribute flag_labels + # @return [Array] Classification labels from automated and manual review + attr_accessor :flag_labels + # @!attribute flag_types + # @return [Array] Types of flags applied to the entity (e.g. user_report, bodyguard) + attr_accessor :flag_types + # @!attribute flags + # @return [Array] Per-provider flag records explaining why the action was taken + attr_accessor :flags # @!attribute entity_content # @return [ModerationPayload] attr_accessor :entity_content + # @!attribute moderation_action + # @return [ActionLogResponse] + attr_accessor :moderation_action + # @!attribute original_moderation_action + # @return [ActionLogResponse] + attr_accessor :original_moderation_action # @!attribute user # @return [UserResponse] attr_accessor :user @@ -53,9 +89,21 @@ def initialize(attributes = {}) @id = attributes[:id] || attributes['id'] @status = attributes[:status] || attributes['status'] @updated_at = attributes[:updated_at] || attributes['updated_at'] + @ai_text_severity = attributes[:ai_text_severity] || attributes['ai_text_severity'] || nil + @channel_cid = attributes[:channel_cid] || attributes['channel_cid'] || nil + @config_key = attributes[:config_key] || attributes['config_key'] || nil @decision_reason = attributes[:decision_reason] || attributes['decision_reason'] || nil + @recommended_action = attributes[:recommended_action] || attributes['recommended_action'] || nil + @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil + @severity = attributes[:severity] || attributes['severity'] || nil + @actions = attributes[:actions] || attributes['actions'] || nil @attachments = attributes[:attachments] || attributes['attachments'] || nil + @flag_labels = attributes[:flag_labels] || attributes['flag_labels'] || nil + @flag_types = attributes[:flag_types] || attributes['flag_types'] || nil + @flags = attributes[:flags] || attributes['flags'] || nil @entity_content = attributes[:entity_content] || attributes['entity_content'] || nil + @moderation_action = attributes[:moderation_action] || attributes['moderation_action'] || nil + @original_moderation_action = attributes[:original_moderation_action] || attributes['original_moderation_action'] || nil @user = attributes[:user] || attributes['user'] || nil end @@ -69,9 +117,21 @@ def self.json_field_mappings id: 'id', status: 'status', updated_at: 'updated_at', + ai_text_severity: 'ai_text_severity', + channel_cid: 'channel_cid', + config_key: 'config_key', decision_reason: 'decision_reason', + recommended_action: 'recommended_action', + review_queue_item_id: 'review_queue_item_id', + severity: 'severity', + actions: 'actions', attachments: 'attachments', + flag_labels: 'flag_labels', + flag_types: 'flag_types', + flags: 'flags', entity_content: 'entity_content', + moderation_action: 'moderation_action', + original_moderation_action: 'original_moderation_action', user: 'user' } end diff --git a/lib/getstream_ruby/generated/models/appeal_request.rb b/lib/getstream_ruby/generated/models/appeal_request.rb index ed3444b..219ebe3 100644 --- a/lib/getstream_ruby/generated/models/appeal_request.rb +++ b/lib/getstream_ruby/generated/models/appeal_request.rb @@ -18,6 +18,9 @@ class AppealRequest < GetStream::BaseModel # @!attribute entity_type # @return [String] Type of entity being appealed (e.g., message, user) attr_accessor :entity_type + # @!attribute review_queue_item_id + # @return [String] ID of the review queue item (flagged message) that triggered the ban. Applicable only for user ban appeals. + attr_accessor :review_queue_item_id # @!attribute user_id # @return [String] attr_accessor :user_id @@ -34,6 +37,7 @@ def initialize(attributes = {}) @appeal_reason = attributes[:appeal_reason] || attributes['appeal_reason'] @entity_id = attributes[:entity_id] || attributes['entity_id'] @entity_type = attributes[:entity_type] || attributes['entity_type'] + @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil @user_id = attributes[:user_id] || attributes['user_id'] || nil @attachments = attributes[:attachments] || attributes['attachments'] || nil @user = attributes[:user] || attributes['user'] || nil @@ -45,6 +49,7 @@ def self.json_field_mappings appeal_reason: 'appeal_reason', entity_id: 'entity_id', entity_type: 'entity_type', + review_queue_item_id: 'review_queue_item_id', user_id: 'user_id', attachments: 'attachments', user: 'user' diff --git a/lib/getstream_ruby/generated/models/block_list_response.rb b/lib/getstream_ruby/generated/models/block_list_response.rb index 2fd6ff2..ee77d76 100644 --- a/lib/getstream_ruby/generated/models/block_list_response.rb +++ b/lib/getstream_ruby/generated/models/block_list_response.rb @@ -9,12 +9,18 @@ module Models class BlockListResponse < GetStream::BaseModel # Model attributes + # @!attribute is_confusable_folding_enabled + # @return [Boolean] + attr_accessor :is_confusable_folding_enabled # @!attribute is_leet_check_enabled # @return [Boolean] attr_accessor :is_leet_check_enabled # @!attribute is_plural_check_enabled # @return [Boolean] attr_accessor :is_plural_check_enabled + # @!attribute is_substring_matching_enabled + # @return [Boolean] + attr_accessor :is_substring_matching_enabled # @!attribute name # @return [String] Block list name attr_accessor :name @@ -40,8 +46,10 @@ class BlockListResponse < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) + @is_confusable_folding_enabled = attributes[:is_confusable_folding_enabled] || attributes['is_confusable_folding_enabled'] @is_leet_check_enabled = attributes[:is_leet_check_enabled] || attributes['is_leet_check_enabled'] @is_plural_check_enabled = attributes[:is_plural_check_enabled] || attributes['is_plural_check_enabled'] + @is_substring_matching_enabled = attributes[:is_substring_matching_enabled] || attributes['is_substring_matching_enabled'] @name = attributes[:name] || attributes['name'] @type = attributes[:type] || attributes['type'] @words = attributes[:words] || attributes['words'] @@ -54,8 +62,10 @@ def initialize(attributes = {}) # Override field mappings for JSON serialization def self.json_field_mappings { + is_confusable_folding_enabled: 'is_confusable_folding_enabled', is_leet_check_enabled: 'is_leet_check_enabled', is_plural_check_enabled: 'is_plural_check_enabled', + is_substring_matching_enabled: 'is_substring_matching_enabled', name: 'name', type: 'type', words: 'words', diff --git a/lib/getstream_ruby/generated/models/bulk_action_appeals_request.rb b/lib/getstream_ruby/generated/models/bulk_action_appeals_request.rb new file mode 100644 index 0000000..32d5df3 --- /dev/null +++ b/lib/getstream_ruby/generated/models/bulk_action_appeals_request.rb @@ -0,0 +1,71 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class BulkActionAppealsRequest < GetStream::BaseModel + + # Model attributes + # @!attribute action_type + # @return [String] Action to apply: unban, restore, unblock, mark_reviewed, or reject_appeal + attr_accessor :action_type + # @!attribute appeal_ids + # @return [Array] List of appeal UUIDs to process + attr_accessor :appeal_ids + # @!attribute user_id + # @return [String] + attr_accessor :user_id + # @!attribute mark_reviewed + # @return [MarkReviewedRequestPayload] + attr_accessor :mark_reviewed + # @!attribute reject_appeal + # @return [RejectAppealRequestPayload] + attr_accessor :reject_appeal + # @!attribute restore + # @return [RestoreActionRequestPayload] + attr_accessor :restore + # @!attribute unban + # @return [UnbanActionRequestPayload] + attr_accessor :unban + # @!attribute unblock + # @return [UnblockActionRequestPayload] + attr_accessor :unblock + # @!attribute user + # @return [UserRequest] + attr_accessor :user + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @action_type = attributes[:action_type] || attributes['action_type'] + @appeal_ids = attributes[:appeal_ids] || attributes['appeal_ids'] + @user_id = attributes[:user_id] || attributes['user_id'] || nil + @mark_reviewed = attributes[:mark_reviewed] || attributes['mark_reviewed'] || nil + @reject_appeal = attributes[:reject_appeal] || attributes['reject_appeal'] || nil + @restore = attributes[:restore] || attributes['restore'] || nil + @unban = attributes[:unban] || attributes['unban'] || nil + @unblock = attributes[:unblock] || attributes['unblock'] || nil + @user = attributes[:user] || attributes['user'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + action_type: 'action_type', + appeal_ids: 'appeal_ids', + user_id: 'user_id', + mark_reviewed: 'mark_reviewed', + reject_appeal: 'reject_appeal', + restore: 'restore', + unban: 'unban', + unblock: 'unblock', + user: 'user' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/bulk_action_appeals_response.rb b/lib/getstream_ruby/generated/models/bulk_action_appeals_response.rb new file mode 100644 index 0000000..67906c8 --- /dev/null +++ b/lib/getstream_ruby/generated/models/bulk_action_appeals_response.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class BulkActionAppealsResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute errors + # @return [Array] Appeals that could not be processed, with per-item error messages + attr_accessor :errors + # @!attribute results + # @return [Array] Successfully processed appeals + attr_accessor :results + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @errors = attributes[:errors] || attributes['errors'] + @results = attributes[:results] || attributes['results'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + errors: 'errors', + results: 'results' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/bulk_appeal_error.rb b/lib/getstream_ruby/generated/models/bulk_appeal_error.rb new file mode 100644 index 0000000..f452ca5 --- /dev/null +++ b/lib/getstream_ruby/generated/models/bulk_appeal_error.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class BulkAppealError < GetStream::BaseModel + + # Model attributes + # @!attribute appeal_id + # @return [String] + attr_accessor :appeal_id + # @!attribute error + # @return [String] + attr_accessor :error + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @appeal_id = attributes[:appeal_id] || attributes['appeal_id'] + @error = attributes[:error] || attributes['error'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + appeal_id: 'appeal_id', + error: 'error' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/bulk_appeal_result.rb b/lib/getstream_ruby/generated/models/bulk_appeal_result.rb new file mode 100644 index 0000000..274125b --- /dev/null +++ b/lib/getstream_ruby/generated/models/bulk_appeal_result.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class BulkAppealResult < GetStream::BaseModel + + # Model attributes + # @!attribute appeal_id + # @return [String] + attr_accessor :appeal_id + # @!attribute appeal_item + # @return [AppealItemResponse] + attr_accessor :appeal_item + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @appeal_id = attributes[:appeal_id] || attributes['appeal_id'] + @appeal_item = attributes[:appeal_item] || attributes['appeal_item'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + appeal_id: 'appeal_id', + appeal_item: 'appeal_item' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/call_stats_participant_counts.rb b/lib/getstream_ruby/generated/models/call_stats_participant_counts.rb index c2d7842..e4df1f7 100644 --- a/lib/getstream_ruby/generated/models/call_stats_participant_counts.rb +++ b/lib/getstream_ruby/generated/models/call_stats_participant_counts.rb @@ -36,6 +36,9 @@ class CallStatsParticipantCounts < GetStream::BaseModel # @!attribute average_latency_ms # @return [Integer] attr_accessor :average_latency_ms + # @!attribute avg_user_rating + # @return [Float] + attr_accessor :avg_user_rating # @!attribute call_event_count # @return [Integer] attr_accessor :call_event_count @@ -45,6 +48,9 @@ class CallStatsParticipantCounts < GetStream::BaseModel # @!attribute max_freezes_duration_ms # @return [Integer] attr_accessor :max_freezes_duration_ms + # @!attribute min_user_rating + # @return [Integer] + attr_accessor :min_user_rating # @!attribute total_participant_duration # @return [Integer] attr_accessor :total_participant_duration @@ -61,9 +67,11 @@ def initialize(attributes = {}) @sfus_used = attributes[:sfus_used] || attributes['sfus_used'] @average_jitter_ms = attributes[:average_jitter_ms] || attributes['average_jitter_ms'] || nil @average_latency_ms = attributes[:average_latency_ms] || attributes['average_latency_ms'] || nil + @avg_user_rating = attributes[:avg_user_rating] || attributes['avg_user_rating'] || nil @call_event_count = attributes[:call_event_count] || attributes['call_event_count'] || nil @cq_score = attributes[:cq_score] || attributes['cq_score'] || nil @max_freezes_duration_ms = attributes[:max_freezes_duration_ms] || attributes['max_freezes_duration_ms'] || nil + @min_user_rating = attributes[:min_user_rating] || attributes['min_user_rating'] || nil @total_participant_duration = attributes[:total_participant_duration] || attributes['total_participant_duration'] || nil end @@ -79,9 +87,11 @@ def self.json_field_mappings sfus_used: 'sfus_used', average_jitter_ms: 'average_jitter_ms', average_latency_ms: 'average_latency_ms', + avg_user_rating: 'avg_user_rating', call_event_count: 'call_event_count', cq_score: 'cq_score', max_freezes_duration_ms: 'max_freezes_duration_ms', + min_user_rating: 'min_user_rating', total_participant_duration: 'total_participant_duration' } end diff --git a/lib/getstream_ruby/generated/models/cancel_import_v2_task_request.rb b/lib/getstream_ruby/generated/models/cancel_import_v2_task_request.rb new file mode 100644 index 0000000..d0a4a87 --- /dev/null +++ b/lib/getstream_ruby/generated/models/cancel_import_v2_task_request.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class CancelImportV2TaskRequest < GetStream::BaseModel + # Empty model - inherits all functionality from BaseModel + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/cancel_import_v2_task_response.rb b/lib/getstream_ruby/generated/models/cancel_import_v2_task_response.rb new file mode 100644 index 0000000..91aaa9b --- /dev/null +++ b/lib/getstream_ruby/generated/models/cancel_import_v2_task_response.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Basic response information + class CancelImportV2TaskResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] Duration of the request in milliseconds + attr_accessor :duration + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/channel_config_overrides.rb b/lib/getstream_ruby/generated/models/channel_config_overrides.rb new file mode 100644 index 0000000..f75f031 --- /dev/null +++ b/lib/getstream_ruby/generated/models/channel_config_overrides.rb @@ -0,0 +1,106 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Channel configuration overrides + class ChannelConfigOverrides < GetStream::BaseModel + + # Model attributes + # @!attribute blocklist + # @return [String] + attr_accessor :blocklist + # @!attribute blocklist_behavior + # @return [String] + attr_accessor :blocklist_behavior + # @!attribute count_messages + # @return [Boolean] Enable/disable message counting + attr_accessor :count_messages + # @!attribute max_message_length + # @return [Integer] Overrides max message length + attr_accessor :max_message_length + # @!attribute push_level + # @return [String] Overrides the push notification level for this channel + attr_accessor :push_level + # @!attribute quotes + # @return [Boolean] Enables message quotes + attr_accessor :quotes + # @!attribute reactions + # @return [Boolean] Enables or disables reactions + attr_accessor :reactions + # @!attribute replies + # @return [Boolean] Enables message replies (threads) + attr_accessor :replies + # @!attribute shared_locations + # @return [Boolean] Enable/disable shared locations + attr_accessor :shared_locations + # @!attribute typing_events + # @return [Boolean] Enables or disables typing events + attr_accessor :typing_events + # @!attribute uploads + # @return [Boolean] Enables or disables file uploads + attr_accessor :uploads + # @!attribute url_enrichment + # @return [Boolean] Enables or disables URL enrichment + attr_accessor :url_enrichment + # @!attribute user_message_reminders + # @return [Boolean] Enable/disable user message reminders + attr_accessor :user_message_reminders + # @!attribute commands + # @return [Array] List of commands that channel supports + attr_accessor :commands + # @!attribute chat_preferences + # @return [ChatPreferences] + attr_accessor :chat_preferences + # @!attribute grants + # @return [Hash>] + attr_accessor :grants + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @blocklist = attributes[:blocklist] || attributes['blocklist'] || nil + @blocklist_behavior = attributes[:blocklist_behavior] || attributes['blocklist_behavior'] || nil + @count_messages = attributes[:count_messages] || attributes['count_messages'] || nil + @max_message_length = attributes[:max_message_length] || attributes['max_message_length'] || nil + @push_level = attributes[:push_level] || attributes['push_level'] || nil + @quotes = attributes[:quotes] || attributes['quotes'] || nil + @reactions = attributes[:reactions] || attributes['reactions'] || nil + @replies = attributes[:replies] || attributes['replies'] || nil + @shared_locations = attributes[:shared_locations] || attributes['shared_locations'] || nil + @typing_events = attributes[:typing_events] || attributes['typing_events'] || nil + @uploads = attributes[:uploads] || attributes['uploads'] || nil + @url_enrichment = attributes[:url_enrichment] || attributes['url_enrichment'] || nil + @user_message_reminders = attributes[:user_message_reminders] || attributes['user_message_reminders'] || nil + @commands = attributes[:commands] || attributes['commands'] || nil + @chat_preferences = attributes[:chat_preferences] || attributes['chat_preferences'] || nil + @grants = attributes[:grants] || attributes['grants'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + blocklist: 'blocklist', + blocklist_behavior: 'blocklist_behavior', + count_messages: 'count_messages', + max_message_length: 'max_message_length', + push_level: 'push_level', + quotes: 'quotes', + reactions: 'reactions', + replies: 'replies', + shared_locations: 'shared_locations', + typing_events: 'typing_events', + uploads: 'uploads', + url_enrichment: 'url_enrichment', + user_message_reminders: 'user_message_reminders', + commands: 'commands', + chat_preferences: 'chat_preferences', + grants: 'grants' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/channel_data_update.rb b/lib/getstream_ruby/generated/models/channel_data_update.rb index 886e2c6..31f321d 100644 --- a/lib/getstream_ruby/generated/models/channel_data_update.rb +++ b/lib/getstream_ruby/generated/models/channel_data_update.rb @@ -25,7 +25,7 @@ class ChannelDataUpdate < GetStream::BaseModel # @return [String] attr_accessor :team # @!attribute config_overrides - # @return [ChannelConfig] + # @return [ChannelConfigOverrides] attr_accessor :config_overrides # @!attribute custom # @return [Object] diff --git a/lib/getstream_ruby/generated/models/channel_input.rb b/lib/getstream_ruby/generated/models/channel_input.rb index 9a38fd0..9e48c58 100644 --- a/lib/getstream_ruby/generated/models/channel_input.rb +++ b/lib/getstream_ruby/generated/models/channel_input.rb @@ -40,7 +40,7 @@ class ChannelInput < GetStream::BaseModel # @return [Array] attr_accessor :members # @!attribute config_overrides - # @return [ChannelConfig] + # @return [ChannelConfigOverrides] attr_accessor :config_overrides # @!attribute created_by # @return [UserRequest] diff --git a/lib/getstream_ruby/generated/models/chat_message_response.rb b/lib/getstream_ruby/generated/models/chat_message_response.rb index 0204fc7..0c7b488 100644 --- a/lib/getstream_ruby/generated/models/chat_message_response.rb +++ b/lib/getstream_ruby/generated/models/chat_message_response.rb @@ -114,6 +114,9 @@ class ChatMessageResponse < GetStream::BaseModel # @!attribute mentioned_group_ids # @return [Array] attr_accessor :mentioned_group_ids + # @!attribute mentioned_groups + # @return [Array] + attr_accessor :mentioned_groups # @!attribute mentioned_roles # @return [Array] attr_accessor :mentioned_roles @@ -192,6 +195,7 @@ def initialize(attributes = {}) @quoted_message_id = attributes[:quoted_message_id] || attributes['quoted_message_id'] || nil @show_in_channel = attributes[:show_in_channel] || attributes['show_in_channel'] || nil @mentioned_group_ids = attributes[:mentioned_group_ids] || attributes['mentioned_group_ids'] || nil + @mentioned_groups = attributes[:mentioned_groups] || attributes['mentioned_groups'] || nil @mentioned_roles = attributes[:mentioned_roles] || attributes['mentioned_roles'] || nil @thread_participants = attributes[:thread_participants] || attributes['thread_participants'] || nil @draft = attributes[:draft] || attributes['draft'] || nil @@ -245,6 +249,7 @@ def self.json_field_mappings quoted_message_id: 'quoted_message_id', show_in_channel: 'show_in_channel', mentioned_group_ids: 'mentioned_group_ids', + mentioned_groups: 'mentioned_groups', mentioned_roles: 'mentioned_roles', thread_participants: 'thread_participants', draft: 'draft', diff --git a/lib/getstream_ruby/generated/models/classification.rb b/lib/getstream_ruby/generated/models/classification.rb new file mode 100644 index 0000000..72cb5e3 --- /dev/null +++ b/lib/getstream_ruby/generated/models/classification.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class Classification < GetStream::BaseModel + + # Model attributes + # @!attribute name + # @return [String] + attr_accessor :name + # @!attribute confidence + # @return [Float] + attr_accessor :confidence + # @!attribute severity + # @return [String] + attr_accessor :severity + # @!attribute subclassifications + # @return [Array] + attr_accessor :subclassifications + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @name = attributes[:name] || attributes['name'] + @confidence = attributes[:confidence] || attributes['confidence'] || nil + @severity = attributes[:severity] || attributes['severity'] || nil + @subclassifications = attributes[:subclassifications] || attributes['subclassifications'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + name: 'name', + confidence: 'confidence', + severity: 'severity', + subclassifications: 'subclassifications' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/client_event.rb b/lib/getstream_ruby/generated/models/client_event.rb new file mode 100644 index 0000000..fb34299 --- /dev/null +++ b/lib/getstream_ruby/generated/models/client_event.rb @@ -0,0 +1,156 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # A single client-side telemetry event. JoinInitiated is the top-level marker emitted when a user begins a join attempt and carries only join_attempt_id (no stage_id or coordinator_connect_id). When stage is CoordinatorJoin, CoordinatorWS, WSJoin, or PeerConnectionConnect the event reports a join-lifecycle attempt; initiation and completion of a stage attempt share the same stage_id. FirstAudioFrame and FirstVideoFrame report media readiness and only ever carry an initiated event. MediaDevicePermission reports the result of requesting screen-share, microphone, and camera permissions. Other stage values denote generic client events. + class ClientEvent < GetStream::BaseModel + + # Model attributes + # @!attribute call_session_id + # @return [String] Call session ID associated with the attempt. Required on every event except CoordinatorJoin initiation and CoordinatorJoin failure (where the call session is not yet established); optional on MediaDevicePermission. + attr_accessor :call_session_id + # @!attribute camera_permission_status + # @return [String] Camera permission status: INITIATED, FAILED, GRANTED, or NOT_INITIATED. Required on every MediaDevicePermission event. + attr_accessor :camera_permission_status + # @!attribute coordinator_connect_id + # @return [String] UUID generated by the client and shared across every event of the same coordinator connection. Required on every event except JoinInitiated, which is reported before a coordinator connection exists. + attr_accessor :coordinator_connect_id + # @!attribute elapsed_time + # @return [Integer] Milliseconds elapsed between the stage attempt's initiation and this event. + attr_accessor :elapsed_time + # @!attribute event_type + # @return [String] Whether the event marks the start (initiated) or resolution (completed) of a stage attempt, or another event-specific value + attr_accessor :event_type + # @!attribute ice_state + # @return [String] Terminal state of the peer connection. Required on PeerConnectionConnect failure. + attr_accessor :ice_state + # @!attribute id + # @return [String] Call ID associated with the event. Required on every stage except CoordinatorWS, where it is optional. + attr_accessor :id + # @!attribute join_attempt_id + # @return [String] UUID generated by the client and shared across JoinInitiated and the join-lifecycle events (CoordinatorJoin, WSJoin, PeerConnectionConnect) of the same overall join attempt. Required on every join event except CoordinatorWS, which is reported before a join attempt is established. + attr_accessor :join_attempt_id + # @!attribute microphone_permission_status + # @return [String] Microphone permission status: INITIATED, FAILED, GRANTED, or NOT_INITIATED. Required on every MediaDevicePermission event. + attr_accessor :microphone_permission_status + # @!attribute outcome + # @return [String] Resolution of a completed event: success or failure. Required on completed join events; forbidden on initiated join events. + attr_accessor :outcome + # @!attribute peer_connection + # @return [String] Which peer connection a PeerConnectionConnect event reports on: publish or subscribe. Required on every PeerConnectionConnect event. + attr_accessor :peer_connection + # @!attribute previously_connected_timestamp + # @return [DateTime] UTC timestamp at which the ICE connection was established earlier in the session, when applicable + attr_accessor :previously_connected_timestamp + # @!attribute retry_count_attempt + # @return [Integer] Total in-stage retries the client made before resolving (0–1000). Required on completed join events. + attr_accessor :retry_count_attempt + # @!attribute retry_failure_code + # @return [String] Failure code string. Required on CoordinatorJoin, CoordinatorWS, WSJoin, and PeerConnectionConnect failure. + attr_accessor :retry_failure_code + # @!attribute retry_failure_reason + # @return [String] Failure reason string. Required on CoordinatorJoin, CoordinatorWS, WSJoin, and PeerConnectionConnect failure. + attr_accessor :retry_failure_reason + # @!attribute screen_share_status + # @return [String] Screen-share permission status: INITIATED, FAILED, GRANTED, or NOT_INITIATED. Optional on MediaDevicePermission events. + attr_accessor :screen_share_status + # @!attribute sdk_version + # @return [String] Version of the client SDK + attr_accessor :sdk_version + # @!attribute sfu_id + # @return [String] Identifier of the SFU the client was attempting to connect to. Required on WSJoin and PeerConnectionConnect failure, and on FirstAudioFrame and FirstVideoFrame. + attr_accessor :sfu_id + # @!attribute stage + # @return [String] Discriminator identifying the event kind. JoinInitiated marks the start of a join attempt; join-lifecycle events use CoordinatorJoin, CoordinatorWS, WSJoin, or PeerConnectionConnect; media-readiness events use FirstAudioFrame or FirstVideoFrame; MediaDevicePermission reports device permission results; other values denote generic client events. + attr_accessor :stage + # @!attribute stage_id + # @return [String] UUID generated by the client at initiation. Identical on the matching completion event. Absent on JoinInitiated. + attr_accessor :stage_id + # @!attribute timestamp + # @return [DateTime] UTC timestamp at which the event was recorded + attr_accessor :timestamp + # @!attribute track_id + # @return [String] Identifier of the media track the frame belongs to. Required on FirstVideoFrame; optional on FirstAudioFrame. + attr_accessor :track_id + # @!attribute type + # @return [String] Call type associated with the event. Required on every stage except CoordinatorWS, where it is optional. + attr_accessor :type + # @!attribute user_agent + # @return [String] User agent string of the client SDK + attr_accessor :user_agent + # @!attribute user_id + # @return [String] ID of the user the event was recorded for + attr_accessor :user_id + # @!attribute was_previously_connected + # @return [Boolean] Whether the ICE connection had been established earlier in the same session. Required on every PeerConnectionConnect event so reconnects can be distinguished from fresh connects. + attr_accessor :was_previously_connected + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @call_session_id = attributes[:call_session_id] || attributes['call_session_id'] || nil + @camera_permission_status = attributes[:camera_permission_status] || attributes['camera_permission_status'] || nil + @coordinator_connect_id = attributes[:coordinator_connect_id] || attributes['coordinator_connect_id'] || nil + @elapsed_time = attributes[:elapsed_time] || attributes['elapsed_time'] || nil + @event_type = attributes[:event_type] || attributes['event_type'] || nil + @ice_state = attributes[:ice_state] || attributes['ice_state'] || nil + @id = attributes[:id] || attributes['id'] || nil + @join_attempt_id = attributes[:join_attempt_id] || attributes['join_attempt_id'] || nil + @microphone_permission_status = attributes[:microphone_permission_status] || attributes['microphone_permission_status'] || nil + @outcome = attributes[:outcome] || attributes['outcome'] || nil + @peer_connection = attributes[:peer_connection] || attributes['peer_connection'] || nil + @previously_connected_timestamp = attributes[:previously_connected_timestamp] || attributes['previously_connected_timestamp'] || nil + @retry_count_attempt = attributes[:retry_count_attempt] || attributes['retry_count_attempt'] || nil + @retry_failure_code = attributes[:retry_failure_code] || attributes['retry_failure_code'] || nil + @retry_failure_reason = attributes[:retry_failure_reason] || attributes['retry_failure_reason'] || nil + @screen_share_status = attributes[:screen_share_status] || attributes['screen_share_status'] || nil + @sdk_version = attributes[:sdk_version] || attributes['sdk_version'] || nil + @sfu_id = attributes[:sfu_id] || attributes['sfu_id'] || nil + @stage = attributes[:stage] || attributes['stage'] || nil + @stage_id = attributes[:stage_id] || attributes['stage_id'] || nil + @timestamp = attributes[:timestamp] || attributes['timestamp'] || nil + @track_id = attributes[:track_id] || attributes['track_id'] || nil + @type = attributes[:type] || attributes['type'] || nil + @user_agent = attributes[:user_agent] || attributes['user_agent'] || nil + @user_id = attributes[:user_id] || attributes['user_id'] || nil + @was_previously_connected = attributes[:was_previously_connected] || attributes['was_previously_connected'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + call_session_id: 'call_session_id', + camera_permission_status: 'camera_permission_status', + coordinator_connect_id: 'coordinator_connect_id', + elapsed_time: 'elapsed_time', + event_type: 'event_type', + ice_state: 'ice_state', + id: 'id', + join_attempt_id: 'join_attempt_id', + microphone_permission_status: 'microphone_permission_status', + outcome: 'outcome', + peer_connection: 'peer_connection', + previously_connected_timestamp: 'previously_connected_timestamp', + retry_count_attempt: 'retry_count_attempt', + retry_failure_code: 'retry_failure_code', + retry_failure_reason: 'retry_failure_reason', + screen_share_status: 'screen_share_status', + sdk_version: 'sdk_version', + sfu_id: 'sfu_id', + stage: 'stage', + stage_id: 'stage_id', + timestamp: 'timestamp', + track_id: 'track_id', + type: 'type', + user_agent: 'user_agent', + user_id: 'user_id', + was_previously_connected: 'was_previously_connected' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/closed_caption_rule_parameters.rb b/lib/getstream_ruby/generated/models/closed_caption_rule_parameters.rb index 0712e04..1fc5fe8 100644 --- a/lib/getstream_ruby/generated/models/closed_caption_rule_parameters.rb +++ b/lib/getstream_ruby/generated/models/closed_caption_rule_parameters.rb @@ -12,6 +12,9 @@ class ClosedCaptionRuleParameters < GetStream::BaseModel # @!attribute threshold # @return [Integer] attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window # @!attribute harm_labels # @return [Array] attr_accessor :harm_labels @@ -23,6 +26,7 @@ class ClosedCaptionRuleParameters < GetStream::BaseModel def initialize(attributes = {}) super(attributes) @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil @harm_labels = attributes[:harm_labels] || attributes['harm_labels'] || nil @llm_harm_labels = attributes[:llm_harm_labels] || attributes['llm_harm_labels'] || nil end @@ -31,6 +35,7 @@ def initialize(attributes = {}) def self.json_field_mappings { threshold: 'threshold', + time_window: 'time_window', harm_labels: 'harm_labels', llm_harm_labels: 'llm_harm_labels' } diff --git a/lib/getstream_ruby/generated/models/config_response.rb b/lib/getstream_ruby/generated/models/config_response.rb index b6c8337..5b187b1 100644 --- a/lib/getstream_ruby/generated/models/config_response.rb +++ b/lib/getstream_ruby/generated/models/config_response.rb @@ -57,6 +57,9 @@ class ConfigResponse < GetStream::BaseModel # @!attribute block_list_config # @return [BlockListConfig] attr_accessor :block_list_config + # @!attribute flood_config + # @return [FloodConfig] + attr_accessor :flood_config # @!attribute llm_config # @return [LLMConfig] attr_accessor :llm_config @@ -86,6 +89,7 @@ def initialize(attributes = {}) @automod_semantic_filters_config = attributes[:automod_semantic_filters_config] || attributes['automod_semantic_filters_config'] || nil @automod_toxicity_config = attributes[:automod_toxicity_config] || attributes['automod_toxicity_config'] || nil @block_list_config = attributes[:block_list_config] || attributes['block_list_config'] || nil + @flood_config = attributes[:flood_config] || attributes['flood_config'] || nil @llm_config = attributes[:llm_config] || attributes['llm_config'] || nil @velocity_filter_config = attributes[:velocity_filter_config] || attributes['velocity_filter_config'] || nil @video_call_rule_config = attributes[:video_call_rule_config] || attributes['video_call_rule_config'] || nil @@ -110,6 +114,7 @@ def self.json_field_mappings automod_semantic_filters_config: 'automod_semantic_filters_config', automod_toxicity_config: 'automod_toxicity_config', block_list_config: 'block_list_config', + flood_config: 'flood_config', llm_config: 'llm_config', velocity_filter_config: 'velocity_filter_config', video_call_rule_config: 'video_call_rule_config' diff --git a/lib/getstream_ruby/generated/models/content_custom_property_count_parameters.rb b/lib/getstream_ruby/generated/models/content_custom_property_count_parameters.rb new file mode 100644 index 0000000..eb61e3c --- /dev/null +++ b/lib/getstream_ruby/generated/models/content_custom_property_count_parameters.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class ContentCustomPropertyCountParameters < GetStream::BaseModel + + # Model attributes + # @!attribute operator + # @return [String] + attr_accessor :operator + # @!attribute property_key + # @return [String] + attr_accessor :property_key + # @!attribute threshold + # @return [Integer] + attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @operator = attributes[:operator] || attributes['operator'] || nil + @property_key = attributes[:property_key] || attributes['property_key'] || nil + @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + operator: 'operator', + property_key: 'property_key', + threshold: 'threshold', + time_window: 'time_window' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/content_custom_property_parameters.rb b/lib/getstream_ruby/generated/models/content_custom_property_parameters.rb new file mode 100644 index 0000000..668cab6 --- /dev/null +++ b/lib/getstream_ruby/generated/models/content_custom_property_parameters.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class ContentCustomPropertyParameters < GetStream::BaseModel + + # Model attributes + # @!attribute operator + # @return [String] + attr_accessor :operator + # @!attribute property_key + # @return [String] + attr_accessor :property_key + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @operator = attributes[:operator] || attributes['operator'] || nil + @property_key = attributes[:property_key] || attributes['property_key'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + operator: 'operator', + property_key: 'property_key' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/create_block_list_request.rb b/lib/getstream_ruby/generated/models/create_block_list_request.rb index 7309234..39c3ba2 100644 --- a/lib/getstream_ruby/generated/models/create_block_list_request.rb +++ b/lib/getstream_ruby/generated/models/create_block_list_request.rb @@ -15,12 +15,18 @@ class CreateBlockListRequest < GetStream::BaseModel # @!attribute words # @return [Array] List of words to block attr_accessor :words + # @!attribute is_confusable_folding_enabled + # @return [Boolean] + attr_accessor :is_confusable_folding_enabled # @!attribute is_leet_check_enabled # @return [Boolean] attr_accessor :is_leet_check_enabled # @!attribute is_plural_check_enabled # @return [Boolean] attr_accessor :is_plural_check_enabled + # @!attribute is_substring_matching_enabled + # @return [Boolean] + attr_accessor :is_substring_matching_enabled # @!attribute team # @return [String] attr_accessor :team @@ -33,8 +39,10 @@ def initialize(attributes = {}) super(attributes) @name = attributes[:name] || attributes['name'] @words = attributes[:words] || attributes['words'] + @is_confusable_folding_enabled = attributes[:is_confusable_folding_enabled] || attributes['is_confusable_folding_enabled'] || nil @is_leet_check_enabled = attributes[:is_leet_check_enabled] || attributes['is_leet_check_enabled'] || nil @is_plural_check_enabled = attributes[:is_plural_check_enabled] || attributes['is_plural_check_enabled'] || nil + @is_substring_matching_enabled = attributes[:is_substring_matching_enabled] || attributes['is_substring_matching_enabled'] || nil @team = attributes[:team] || attributes['team'] || nil @type = attributes[:type] || attributes['type'] || nil end @@ -44,8 +52,10 @@ def self.json_field_mappings { name: 'name', words: 'words', + is_confusable_folding_enabled: 'is_confusable_folding_enabled', is_leet_check_enabled: 'is_leet_check_enabled', is_plural_check_enabled: 'is_plural_check_enabled', + is_substring_matching_enabled: 'is_substring_matching_enabled', team: 'team', type: 'type' } diff --git a/lib/getstream_ruby/generated/models/create_device_request.rb b/lib/getstream_ruby/generated/models/create_device_request.rb index d975e54..a2f60a4 100644 --- a/lib/getstream_ruby/generated/models/create_device_request.rb +++ b/lib/getstream_ruby/generated/models/create_device_request.rb @@ -15,6 +15,9 @@ class CreateDeviceRequest < GetStream::BaseModel # @!attribute push_provider # @return [String] Push provider attr_accessor :push_provider + # @!attribute hardware_id + # @return [String] Stable physical device identifier used to deduplicate pushes across push providers (e.g. APNs VoIP and Firebase on the same iOS device). Distinct from 'id', which is the push token. + attr_accessor :hardware_id # @!attribute push_provider_name # @return [String] Push provider name attr_accessor :push_provider_name @@ -33,6 +36,7 @@ def initialize(attributes = {}) super(attributes) @id = attributes[:id] || attributes['id'] @push_provider = attributes[:push_provider] || attributes['push_provider'] + @hardware_id = attributes[:hardware_id] || attributes['hardware_id'] || nil @push_provider_name = attributes[:push_provider_name] || attributes['push_provider_name'] || nil @user_id = attributes[:user_id] || attributes['user_id'] || nil @voip_token = attributes[:voip_token] || attributes['voip_token'] || nil @@ -44,6 +48,7 @@ def self.json_field_mappings { id: 'id', push_provider: 'push_provider', + hardware_id: 'hardware_id', push_provider_name: 'push_provider_name', user_id: 'user_id', voip_token: 'voip_token', diff --git a/lib/getstream_ruby/generated/models/create_segment_request.rb b/lib/getstream_ruby/generated/models/create_segment_request.rb new file mode 100644 index 0000000..0328787 --- /dev/null +++ b/lib/getstream_ruby/generated/models/create_segment_request.rb @@ -0,0 +1,61 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class CreateSegmentRequest < GetStream::BaseModel + + # Model attributes + # @!attribute type + # @return [String] The type of the segment + attr_accessor :type + # @!attribute all_sender_channels + # @return [Boolean] If true, all sender channels are included in the segment + attr_accessor :all_sender_channels + # @!attribute all_users + # @return [Boolean] If true, all users are included in the segment + attr_accessor :all_users + # @!attribute description + # @return [String] The description of the segment (max 256 characters) + attr_accessor :description + # @!attribute id + # @return [String] The ID of the segment + attr_accessor :id + # @!attribute name + # @return [String] The name of the segment (max 128 characters) + attr_accessor :name + # @!attribute filter + # @return [Object] Filter to apply to the query + attr_accessor :filter + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @type = attributes[:type] || attributes['type'] + @all_sender_channels = attributes[:all_sender_channels] || attributes['all_sender_channels'] || nil + @all_users = attributes[:all_users] || attributes['all_users'] || nil + @description = attributes[:description] || attributes['description'] || nil + @id = attributes[:id] || attributes['id'] || nil + @name = attributes[:name] || attributes['name'] || nil + @filter = attributes[:filter] || attributes['filter'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + type: 'type', + all_sender_channels: 'all_sender_channels', + all_users: 'all_users', + description: 'description', + id: 'id', + name: 'name', + filter: 'filter' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/create_segment_response.rb b/lib/getstream_ruby/generated/models/create_segment_response.rb new file mode 100644 index 0000000..a7c42bd --- /dev/null +++ b/lib/getstream_ruby/generated/models/create_segment_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Basic response information + class CreateSegmentResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] Duration of the request in milliseconds + attr_accessor :duration + # @!attribute segment + # @return [SegmentResponse] + attr_accessor :segment + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @segment = attributes[:segment] || attributes['segment'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + segment: 'segment' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/delivery_receipts_response.rb b/lib/getstream_ruby/generated/models/delivery_receipts_response.rb index cb465f3..8707bfc 100644 --- a/lib/getstream_ruby/generated/models/delivery_receipts_response.rb +++ b/lib/getstream_ruby/generated/models/delivery_receipts_response.rb @@ -16,7 +16,7 @@ class DeliveryReceiptsResponse < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) - @enabled = attributes[:enabled] || attributes['enabled'] || nil + @enabled = attributes[:enabled] || attributes['enabled'] end # Override field mappings for JSON serialization diff --git a/lib/getstream_ruby/generated/models/device_response.rb b/lib/getstream_ruby/generated/models/device_response.rb index 664127c..d24c235 100644 --- a/lib/getstream_ruby/generated/models/device_response.rb +++ b/lib/getstream_ruby/generated/models/device_response.rb @@ -27,6 +27,9 @@ class DeviceResponse < GetStream::BaseModel # @!attribute disabled_reason # @return [String] Reason explaining why device had been disabled attr_accessor :disabled_reason + # @!attribute hardware_id + # @return [String] Stable physical device identifier used to deduplicate pushes across push providers + attr_accessor :hardware_id # @!attribute push_provider_name # @return [String] Push provider name attr_accessor :push_provider_name @@ -43,6 +46,7 @@ def initialize(attributes = {}) @user_id = attributes[:user_id] || attributes['user_id'] @disabled = attributes[:disabled] || attributes['disabled'] || nil @disabled_reason = attributes[:disabled_reason] || attributes['disabled_reason'] || nil + @hardware_id = attributes[:hardware_id] || attributes['hardware_id'] || nil @push_provider_name = attributes[:push_provider_name] || attributes['push_provider_name'] || nil @voip = attributes[:voip] || attributes['voip'] || nil end @@ -56,6 +60,7 @@ def self.json_field_mappings user_id: 'user_id', disabled: 'disabled', disabled_reason: 'disabled_reason', + hardware_id: 'hardware_id', push_provider_name: 'push_provider_name', voip: 'voip' } diff --git a/lib/getstream_ruby/generated/models/filter_config_response.rb b/lib/getstream_ruby/generated/models/filter_config_response.rb index ea72840..14d23e1 100644 --- a/lib/getstream_ruby/generated/models/filter_config_response.rb +++ b/lib/getstream_ruby/generated/models/filter_config_response.rb @@ -10,14 +10,17 @@ class FilterConfigResponse < GetStream::BaseModel # Model attributes # @!attribute llm_labels - # @return [Array] + # @return [Array] LLM moderation labels available as filter values attr_accessor :llm_labels # @!attribute ai_text_labels - # @return [Array] + # @return [Array] AI text moderation labels available as filter values attr_accessor :ai_text_labels # @!attribute config_keys - # @return [Array] + # @return [Array] Moderation config keys present in the queue, available as filter values attr_accessor :config_keys + # @!attribute filterable_custom_keys + # @return [Array] The moderation_payload.custom keys the app has configured as review-queue filter chips (via moderation_dashboard_preferences.filterable_custom_keys). Discovery hint for the dashboard only — the filter accepts any custom key regardless of this list. + attr_accessor :filterable_custom_keys # Initialize with attributes def initialize(attributes = {}) @@ -25,6 +28,7 @@ def initialize(attributes = {}) @llm_labels = attributes[:llm_labels] || attributes['llm_labels'] @ai_text_labels = attributes[:ai_text_labels] || attributes['ai_text_labels'] || nil @config_keys = attributes[:config_keys] || attributes['config_keys'] || nil + @filterable_custom_keys = attributes[:filterable_custom_keys] || attributes['filterable_custom_keys'] || nil end # Override field mappings for JSON serialization @@ -32,7 +36,8 @@ def self.json_field_mappings { llm_labels: 'llm_labels', ai_text_labels: 'ai_text_labels', - config_keys: 'config_keys' + config_keys: 'config_keys', + filterable_custom_keys: 'filterable_custom_keys' } end end diff --git a/lib/getstream_ruby/generated/models/flag_details.rb b/lib/getstream_ruby/generated/models/flag_details.rb new file mode 100644 index 0000000..1c9a377 --- /dev/null +++ b/lib/getstream_ruby/generated/models/flag_details.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class FlagDetails < GetStream::BaseModel + + # Model attributes + # @!attribute original_text + # @return [String] + attr_accessor :original_text + # @!attribute automod + # @return [AutomodDetailsResponse] + attr_accessor :automod + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @original_text = attributes[:original_text] || attributes['original_text'] + @automod = attributes[:automod] || attributes['automod'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + original_text: 'original_text', + automod: 'automod' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/flag_item_response.rb b/lib/getstream_ruby/generated/models/flag_item_response.rb new file mode 100644 index 0000000..b03ed52 --- /dev/null +++ b/lib/getstream_ruby/generated/models/flag_item_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class FlagItemResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute item_id + # @return [String] Unique identifier of the created moderation item + attr_accessor :item_id + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @item_id = attributes[:item_id] || attributes['item_id'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + item_id: 'item_id' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/flag_response.rb b/lib/getstream_ruby/generated/models/flag_response.rb index c111857..91a7efd 100644 --- a/lib/getstream_ruby/generated/models/flag_response.rb +++ b/lib/getstream_ruby/generated/models/flag_response.rb @@ -9,25 +9,85 @@ module Models class FlagResponse < GetStream::BaseModel # Model attributes - # @!attribute duration + # @!attribute created_at + # @return [DateTime] + attr_accessor :created_at + # @!attribute created_by_automod + # @return [Boolean] + attr_accessor :created_by_automod + # @!attribute updated_at + # @return [DateTime] + attr_accessor :updated_at + # @!attribute approved_at + # @return [DateTime] + attr_accessor :approved_at + # @!attribute reason # @return [String] - attr_accessor :duration - # @!attribute item_id - # @return [String] Unique identifier of the created moderation item - attr_accessor :item_id + attr_accessor :reason + # @!attribute rejected_at + # @return [DateTime] + attr_accessor :rejected_at + # @!attribute reviewed_at + # @return [DateTime] + attr_accessor :reviewed_at + # @!attribute reviewed_by + # @return [String] + attr_accessor :reviewed_by + # @!attribute target_message_id + # @return [String] + attr_accessor :target_message_id + # @!attribute custom + # @return [Object] + attr_accessor :custom + # @!attribute details + # @return [FlagDetails] + attr_accessor :details + # @!attribute target_message + # @return [MessageResponse] + attr_accessor :target_message + # @!attribute target_user + # @return [UserResponse] + attr_accessor :target_user + # @!attribute user + # @return [UserResponse] + attr_accessor :user # Initialize with attributes def initialize(attributes = {}) super(attributes) - @duration = attributes[:duration] || attributes['duration'] - @item_id = attributes[:item_id] || attributes['item_id'] + @created_at = attributes[:created_at] || attributes['created_at'] + @created_by_automod = attributes[:created_by_automod] || attributes['created_by_automod'] + @updated_at = attributes[:updated_at] || attributes['updated_at'] + @approved_at = attributes[:approved_at] || attributes['approved_at'] || nil + @reason = attributes[:reason] || attributes['reason'] || nil + @rejected_at = attributes[:rejected_at] || attributes['rejected_at'] || nil + @reviewed_at = attributes[:reviewed_at] || attributes['reviewed_at'] || nil + @reviewed_by = attributes[:reviewed_by] || attributes['reviewed_by'] || nil + @target_message_id = attributes[:target_message_id] || attributes['target_message_id'] || nil + @custom = attributes[:custom] || attributes['custom'] || nil + @details = attributes[:details] || attributes['details'] || nil + @target_message = attributes[:target_message] || attributes['target_message'] || nil + @target_user = attributes[:target_user] || attributes['target_user'] || nil + @user = attributes[:user] || attributes['user'] || nil end # Override field mappings for JSON serialization def self.json_field_mappings { - duration: 'duration', - item_id: 'item_id' + created_at: 'created_at', + created_by_automod: 'created_by_automod', + updated_at: 'updated_at', + approved_at: 'approved_at', + reason: 'reason', + rejected_at: 'rejected_at', + reviewed_at: 'reviewed_at', + reviewed_by: 'reviewed_by', + target_message_id: 'target_message_id', + custom: 'custom', + details: 'details', + target_message: 'target_message', + target_user: 'target_user', + user: 'user' } end end diff --git a/lib/getstream_ruby/generated/models/flood_config.rb b/lib/getstream_ruby/generated/models/flood_config.rb new file mode 100644 index 0000000..1333eb9 --- /dev/null +++ b/lib/getstream_ruby/generated/models/flood_config.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class FloodConfig < GetStream::BaseModel + + # Model attributes + # @!attribute identical + # @return [FloodIdenticalConfig] + attr_accessor :identical + # @!attribute similar + # @return [FloodSimilarConfig] + attr_accessor :similar + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @identical = attributes[:identical] || attributes['identical'] || nil + @similar = attributes[:similar] || attributes['similar'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + identical: 'identical', + similar: 'similar' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/flood_identical_config.rb b/lib/getstream_ruby/generated/models/flood_identical_config.rb new file mode 100644 index 0000000..61de61a --- /dev/null +++ b/lib/getstream_ruby/generated/models/flood_identical_config.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class FloodIdenticalConfig < GetStream::BaseModel + + # Model attributes + # @!attribute action + # @return [String] + attr_accessor :action + # @!attribute enabled + # @return [Boolean] + attr_accessor :enabled + # @!attribute threshold + # @return [Integer] + attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @action = attributes[:action] || attributes['action'] || nil + @enabled = attributes[:enabled] || attributes['enabled'] || nil + @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + action: 'action', + enabled: 'enabled', + threshold: 'threshold', + time_window: 'time_window' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/flood_similar_config.rb b/lib/getstream_ruby/generated/models/flood_similar_config.rb new file mode 100644 index 0000000..08b60fe --- /dev/null +++ b/lib/getstream_ruby/generated/models/flood_similar_config.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class FloodSimilarConfig < GetStream::BaseModel + + # Model attributes + # @!attribute action + # @return [String] + attr_accessor :action + # @!attribute enabled + # @return [Boolean] + attr_accessor :enabled + # @!attribute similarity_distance + # @return [Integer] + attr_accessor :similarity_distance + # @!attribute threshold + # @return [Integer] + attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @action = attributes[:action] || attributes['action'] || nil + @enabled = attributes[:enabled] || attributes['enabled'] || nil + @similarity_distance = attributes[:similarity_distance] || attributes['similarity_distance'] || nil + @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + action: 'action', + enabled: 'enabled', + similarity_distance: 'similarity_distance', + threshold: 'threshold', + time_window: 'time_window' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/follow_request.rb b/lib/getstream_ruby/generated/models/follow_request.rb index d70a52d..71a6b3c 100644 --- a/lib/getstream_ruby/generated/models/follow_request.rb +++ b/lib/getstream_ruby/generated/models/follow_request.rb @@ -26,7 +26,7 @@ class FollowRequest < GetStream::BaseModel # @return [Boolean] Whether to create a notification activity for this follow attr_accessor :create_notification_activity # @!attribute create_users - # @return [Boolean] If true, auto-creates users referenced by the source and target FIDs when they don't already exist. Server-side only. Defaults to false. For FollowBatch/GetOrCreateFollows, use the top-level create_users field; per-item follows[i].create_users is rejected. + # @return [Boolean] If true, auto-creates users referenced by the source and target FIDs when they don't already exist. Server-side only. Defaults to false. Use directly on single follow endpoints (Follow, GetOrCreateFollow). On batch endpoints (FollowBatch, GetOrCreateFollows), use the top-level create_users field; per-item follows[i].create_users is rejected. attr_accessor :create_users # @!attribute enrich_own_fields # @return [Boolean] If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_followings, own_capabilities, own_membership). Defaults to false for performance. diff --git a/lib/getstream_ruby/generated/models/get_or_create_feed_request.rb b/lib/getstream_ruby/generated/models/get_or_create_feed_request.rb index 2104d0c..921e279 100644 --- a/lib/getstream_ruby/generated/models/get_or_create_feed_request.rb +++ b/lib/getstream_ruby/generated/models/get_or_create_feed_request.rb @@ -18,6 +18,9 @@ class GetOrCreateFeedRequest < GetStream::BaseModel # @!attribute next # @return [String] attr_accessor :next + # @!attribute overwrite_interest_weights + # @return [Boolean] + attr_accessor :overwrite_interest_weights # @!attribute prev # @return [String] attr_accessor :prev @@ -67,6 +70,7 @@ def initialize(attributes = {}) @id_around = attributes[:id_around] || attributes['id_around'] || nil @limit = attributes[:limit] || attributes['limit'] || nil @next = attributes[:next] || attributes['next'] || nil + @overwrite_interest_weights = attributes[:overwrite_interest_weights] || attributes['overwrite_interest_weights'] || nil @prev = attributes[:prev] || attributes['prev'] || nil @user_id = attributes[:user_id] || attributes['user_id'] || nil @view = attributes[:view] || attributes['view'] || nil @@ -89,6 +93,7 @@ def self.json_field_mappings id_around: 'id_around', limit: 'limit', next: 'next', + overwrite_interest_weights: 'overwrite_interest_weights', prev: 'prev', user_id: 'user_id', view: 'view', diff --git a/lib/getstream_ruby/generated/models/get_or_create_follow_response.rb b/lib/getstream_ruby/generated/models/get_or_create_follow_response.rb new file mode 100644 index 0000000..25e3218 --- /dev/null +++ b/lib/getstream_ruby/generated/models/get_or_create_follow_response.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class GetOrCreateFollowResponse < GetStream::BaseModel + + # Model attributes + # @!attribute created + # @return [Boolean] True if the follow was newly created by this request; false if it already existed + attr_accessor :created + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute follow + # @return [FollowResponse] + attr_accessor :follow + # @!attribute notification_created + # @return [Boolean] Whether a notification activity was successfully created (only set when the follow was newly created) + attr_accessor :notification_created + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @created = attributes[:created] || attributes['created'] + @duration = attributes[:duration] || attributes['duration'] + @follow = attributes[:follow] || attributes['follow'] + @notification_created = attributes[:notification_created] || attributes['notification_created'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + created: 'created', + duration: 'duration', + follow: 'follow', + notification_created: 'notification_created' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/get_or_create_unfollow_request.rb b/lib/getstream_ruby/generated/models/get_or_create_unfollow_request.rb new file mode 100644 index 0000000..15db06e --- /dev/null +++ b/lib/getstream_ruby/generated/models/get_or_create_unfollow_request.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class GetOrCreateUnfollowRequest < GetStream::BaseModel + + # Model attributes + # @!attribute source + # @return [String] Fully qualified ID of the source feed + attr_accessor :source + # @!attribute target + # @return [String] Fully qualified ID of the target feed + attr_accessor :target + # @!attribute delete_notification_activity + # @return [Boolean] Whether to delete the corresponding notification activity (default: false) + attr_accessor :delete_notification_activity + # @!attribute enrich_own_fields + # @return [Boolean] If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_followings, own_capabilities, own_membership). Defaults to false for performance. + attr_accessor :enrich_own_fields + # @!attribute keep_history + # @return [Boolean] When true, activities from the unfollowed feed will remain in the source feed's timeline (default: false) + attr_accessor :keep_history + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @source = attributes[:source] || attributes['source'] + @target = attributes[:target] || attributes['target'] + @delete_notification_activity = attributes[:delete_notification_activity] || attributes['delete_notification_activity'] || nil + @enrich_own_fields = attributes[:enrich_own_fields] || attributes['enrich_own_fields'] || nil + @keep_history = attributes[:keep_history] || attributes['keep_history'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + source: 'source', + target: 'target', + delete_notification_activity: 'delete_notification_activity', + enrich_own_fields: 'enrich_own_fields', + keep_history: 'keep_history' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/get_or_create_unfollow_response.rb b/lib/getstream_ruby/generated/models/get_or_create_unfollow_response.rb new file mode 100644 index 0000000..7d75299 --- /dev/null +++ b/lib/getstream_ruby/generated/models/get_or_create_unfollow_response.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class GetOrCreateUnfollowResponse < GetStream::BaseModel + + # Model attributes + # @!attribute deleted + # @return [Boolean] True if a follow was found and removed by this request; false if no follow existed + attr_accessor :deleted + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute follow + # @return [FollowResponse] + attr_accessor :follow + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @deleted = attributes[:deleted] || attributes['deleted'] + @duration = attributes[:duration] || attributes['duration'] + @follow = attributes[:follow] || attributes['follow'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + deleted: 'deleted', + duration: 'duration', + follow: 'follow' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/get_setup_session_response.rb b/lib/getstream_ruby/generated/models/get_setup_session_response.rb new file mode 100644 index 0000000..c0e2363 --- /dev/null +++ b/lib/getstream_ruby/generated/models/get_setup_session_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class GetSetupSessionResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute setup_session + # @return [SetupSession] + attr_accessor :setup_session + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @setup_session = attributes[:setup_session] || attributes['setup_session'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + setup_session: 'setup_session' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/get_user_interests_response.rb b/lib/getstream_ruby/generated/models/get_user_interests_response.rb new file mode 100644 index 0000000..8d9882d --- /dev/null +++ b/lib/getstream_ruby/generated/models/get_user_interests_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # User's computed interest tags ordered by descending count, then ascending tag name + class GetUserInterestsResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute interests + # @return [Array] Top-N interest tags sorted by descending count, then alphabetically by tag + attr_accessor :interests + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @interests = attributes[:interests] || attributes['interests'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + interests: 'interests' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/grouped_channels_bucket.rb b/lib/getstream_ruby/generated/models/grouped_channels_bucket.rb index d520788..b43ae8c 100644 --- a/lib/getstream_ruby/generated/models/grouped_channels_bucket.rb +++ b/lib/getstream_ruby/generated/models/grouped_channels_bucket.rb @@ -12,6 +12,12 @@ class GroupedChannelsBucket < GetStream::BaseModel # @!attribute channels # @return [Array] Channels returned for this bucket attr_accessor :channels + # @!attribute next + # @return [String] Cursor for the next page of this group + attr_accessor :next + # @!attribute prev + # @return [String] Cursor for the previous page of this group + attr_accessor :prev # @!attribute unread_channels # @return [Integer] Unread channels currently classified into this bucket attr_accessor :unread_channels @@ -20,6 +26,8 @@ class GroupedChannelsBucket < GetStream::BaseModel def initialize(attributes = {}) super(attributes) @channels = attributes[:channels] || attributes['channels'] + @next = attributes[:next] || attributes['next'] || nil + @prev = attributes[:prev] || attributes['prev'] || nil @unread_channels = attributes[:unread_channels] || attributes['unread_channels'] || nil end @@ -27,6 +35,8 @@ def initialize(attributes = {}) def self.json_field_mappings { channels: 'channels', + next: 'next', + prev: 'prev', unread_channels: 'unread_channels' } end diff --git a/lib/getstream_ruby/generated/models/grouped_channels_group_request.rb b/lib/getstream_ruby/generated/models/grouped_channels_group_request.rb new file mode 100644 index 0000000..737e19e --- /dev/null +++ b/lib/getstream_ruby/generated/models/grouped_channels_group_request.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class GroupedChannelsGroupRequest < GetStream::BaseModel + + # Model attributes + # @!attribute limit + # @return [Integer] + attr_accessor :limit + # @!attribute next + # @return [String] + attr_accessor :next + # @!attribute prev + # @return [String] + attr_accessor :prev + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @limit = attributes[:limit] || attributes['limit'] || nil + @next = attributes[:next] || attributes['next'] || nil + @prev = attributes[:prev] || attributes['prev'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + limit: 'limit', + next: 'next', + prev: 'prev' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/grouped_query_channels_request.rb b/lib/getstream_ruby/generated/models/grouped_query_channels_request.rb index a99fd96..880f767 100644 --- a/lib/getstream_ruby/generated/models/grouped_query_channels_request.rb +++ b/lib/getstream_ruby/generated/models/grouped_query_channels_request.rb @@ -10,11 +10,14 @@ class GroupedQueryChannelsRequest < GetStream::BaseModel # Model attributes # @!attribute limit - # @return [Integer] Max channels per bucket (default 10) + # @return [Integer] Default max channels per group (default 10) attr_accessor :limit # @!attribute user_id # @return [String] attr_accessor :user_id + # @!attribute groups + # @return [Hash] Groups to return, keyed by group name. Each group can define limit, next, or prev. 'next' and 'prev' cursors are only allowed when the request contains exactly one group; multi-group pagination is rejected. + attr_accessor :groups # @!attribute user # @return [UserRequest] attr_accessor :user @@ -24,6 +27,7 @@ def initialize(attributes = {}) super(attributes) @limit = attributes[:limit] || attributes['limit'] || nil @user_id = attributes[:user_id] || attributes['user_id'] || nil + @groups = attributes[:groups] || attributes['groups'] || nil @user = attributes[:user] || attributes['user'] || nil end @@ -32,6 +36,7 @@ def self.json_field_mappings { limit: 'limit', user_id: 'user_id', + groups: 'groups', user: 'user' } end diff --git a/lib/getstream_ruby/generated/models/import_v2_task_settings.rb b/lib/getstream_ruby/generated/models/import_v2_task_settings.rb index d802749..878369b 100644 --- a/lib/getstream_ruby/generated/models/import_v2_task_settings.rb +++ b/lib/getstream_ruby/generated/models/import_v2_task_settings.rb @@ -24,6 +24,9 @@ class ImportV2TaskSettings < GetStream::BaseModel # @!attribute source # @return [String] attr_accessor :source + # @!attribute use_import_time_as_op_time + # @return [Boolean] + attr_accessor :use_import_time_as_op_time # @!attribute s3 # @return [ImportV2TaskSettingsS3] attr_accessor :s3 @@ -36,6 +39,7 @@ def initialize(attributes = {}) @path = attributes[:path] || attributes['path'] || nil @skip_references_check = attributes[:skip_references_check] || attributes['skip_references_check'] || nil @source = attributes[:source] || attributes['source'] || nil + @use_import_time_as_op_time = attributes[:use_import_time_as_op_time] || attributes['use_import_time_as_op_time'] || nil @s3 = attributes[:s3] || attributes['s3'] || nil end @@ -47,6 +51,7 @@ def self.json_field_mappings path: 'path', skip_references_check: 'skip_references_check', source: 'source', + use_import_time_as_op_time: 'use_import_time_as_op_time', s3: 's3' } end diff --git a/lib/getstream_ruby/generated/models/interest_tag_response.rb b/lib/getstream_ruby/generated/models/interest_tag_response.rb new file mode 100644 index 0000000..30adc8e --- /dev/null +++ b/lib/getstream_ruby/generated/models/interest_tag_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # An interest tag with the number of distinct activities the user reacted to that carried it + class InterestTagResponse < GetStream::BaseModel + + # Model attributes + # @!attribute count + # @return [Integer] Number of distinct reacted-to activities tagged with this value + attr_accessor :count + # @!attribute tag + # @return [String] The interest tag value + attr_accessor :tag + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @count = attributes[:count] || attributes['count'] + @tag = attributes[:tag] || attributes['tag'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + count: 'count', + tag: 'tag' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/keyframe_ocr_rule_parameters.rb b/lib/getstream_ruby/generated/models/keyframe_ocr_rule_parameters.rb new file mode 100644 index 0000000..c6e921d --- /dev/null +++ b/lib/getstream_ruby/generated/models/keyframe_ocr_rule_parameters.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class KeyframeOCRRuleParameters < GetStream::BaseModel + + # Model attributes + # @!attribute threshold + # @return [Integer] + attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window + # @!attribute harm_labels + # @return [Array] + attr_accessor :harm_labels + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil + @harm_labels = attributes[:harm_labels] || attributes['harm_labels'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + threshold: 'threshold', + time_window: 'time_window', + harm_labels: 'harm_labels' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/keyframe_rule_parameters.rb b/lib/getstream_ruby/generated/models/keyframe_rule_parameters.rb index d3448a4..03b06d9 100644 --- a/lib/getstream_ruby/generated/models/keyframe_rule_parameters.rb +++ b/lib/getstream_ruby/generated/models/keyframe_rule_parameters.rb @@ -15,6 +15,9 @@ class KeyframeRuleParameters < GetStream::BaseModel # @!attribute threshold # @return [Integer] attr_accessor :threshold + # @!attribute time_window + # @return [String] + attr_accessor :time_window # @!attribute harm_labels # @return [Array] attr_accessor :harm_labels @@ -24,6 +27,7 @@ def initialize(attributes = {}) super(attributes) @min_confidence = attributes[:min_confidence] || attributes['min_confidence'] || nil @threshold = attributes[:threshold] || attributes['threshold'] || nil + @time_window = attributes[:time_window] || attributes['time_window'] || nil @harm_labels = attributes[:harm_labels] || attributes['harm_labels'] || nil end @@ -32,6 +36,7 @@ def self.json_field_mappings { min_confidence: 'min_confidence', threshold: 'threshold', + time_window: 'time_window', harm_labels: 'harm_labels' } end diff --git a/lib/getstream_ruby/generated/models/label_result_response.rb b/lib/getstream_ruby/generated/models/label_result_response.rb index f459273..3161d19 100644 --- a/lib/getstream_ruby/generated/models/label_result_response.rb +++ b/lib/getstream_ruby/generated/models/label_result_response.rb @@ -45,6 +45,9 @@ class LabelResultResponse < GetStream::BaseModel # @!attribute directed_at # @return [String] Who the content is directed at (USER, GROUP, EVERYONE, NONE, etc.) attr_accessor :directed_at + # @!attribute fully_masked_content + # @return [String] The stored content with every non-whitespace character masked. Present only when recommended_action is not 'keep'. Derived at runtime and never stored. + attr_accessor :fully_masked_content # @!attribute masked_content # @return [String] Content with blocklisted tokens masked (when a blocklist rule with action=mask rewrote the original) attr_accessor :masked_content @@ -70,6 +73,7 @@ def initialize(attributes = {}) @labels = attributes[:labels] || attributes['labels'] @content_id = attributes[:content_id] || attributes['content_id'] || nil @directed_at = attributes[:directed_at] || attributes['directed_at'] || nil + @fully_masked_content = attributes[:fully_masked_content] || attributes['fully_masked_content'] || nil @masked_content = attributes[:masked_content] || attributes['masked_content'] || nil @policy = attributes[:policy] || attributes['policy'] || nil @user_id = attributes[:user_id] || attributes['user_id'] || nil @@ -90,6 +94,7 @@ def self.json_field_mappings labels: 'labels', content_id: 'content_id', directed_at: 'directed_at', + fully_masked_content: 'fully_masked_content', masked_content: 'masked_content', policy: 'policy', user_id: 'user_id' diff --git a/lib/getstream_ruby/generated/models/labels_request.rb b/lib/getstream_ruby/generated/models/labels_request.rb index 25a403f..64fa6ea 100644 --- a/lib/getstream_ruby/generated/models/labels_request.rb +++ b/lib/getstream_ruby/generated/models/labels_request.rb @@ -25,7 +25,7 @@ class LabelsRequest < GetStream::BaseModel # @return [Boolean] When true, run moderation and return labels without persisting the result. Useful for one-off checks (e.g. UI testers) that should not be recorded in the stored history. attr_accessor :dry_run # @!attribute policy - # @return [String] Optional moderation policy key (max 128 chars) + # @return [String] Optional moderation policy key (max 128 chars). For username moderation, set this to a policy whose key starts with 'username:' (e.g. 'username:default') to opt into the low-latency fast-path: blocklists (customer + Stream-managed defaults) short-circuit the LLM, and the LLM fallback uses gpt-4.1-nano with a 24h Valkey verdict cache. Without a 'username:' prefix the request falls through to the standard Bodyguard Analyze v1 username path. attr_accessor :policy # @!attribute user_id # @return [String] Optional customer-supplied user identifier for the content author (max 256 chars). Enables filtering stored results by user_id. diff --git a/lib/getstream_ruby/generated/models/labels_response.rb b/lib/getstream_ruby/generated/models/labels_response.rb index d807143..57181fd 100644 --- a/lib/getstream_ruby/generated/models/labels_response.rb +++ b/lib/getstream_ruby/generated/models/labels_response.rb @@ -21,6 +21,9 @@ class LabelsResponse < GetStream::BaseModel # @!attribute directed_at # @return [String] Who the content is directed at (USER, GROUP, EVERYONE, NONE, etc.), when the provider exposes it attr_accessor :directed_at + # @!attribute fully_masked_content + # @return [String] The original content with every non-whitespace character masked. Present only when recommended_action is not 'keep'. Derived at runtime and never stored. + attr_accessor :fully_masked_content # @!attribute harm_type # @return [String] High-level harm category attr_accessor :harm_type @@ -44,6 +47,7 @@ def initialize(attributes = {}) @recommended_action = attributes[:recommended_action] || attributes['recommended_action'] @content_id = attributes[:content_id] || attributes['content_id'] || nil @directed_at = attributes[:directed_at] || attributes['directed_at'] || nil + @fully_masked_content = attributes[:fully_masked_content] || attributes['fully_masked_content'] || nil @harm_type = attributes[:harm_type] || attributes['harm_type'] || nil @language = attributes[:language] || attributes['language'] || nil @masked_content = attributes[:masked_content] || attributes['masked_content'] || nil @@ -58,6 +62,7 @@ def self.json_field_mappings recommended_action: 'recommended_action', content_id: 'content_id', directed_at: 'directed_at', + fully_masked_content: 'fully_masked_content', harm_type: 'harm_type', language: 'language', masked_content: 'masked_content', diff --git a/lib/getstream_ruby/generated/models/llm_rule.rb b/lib/getstream_ruby/generated/models/llm_rule.rb index 70eaeae..00587f3 100644 --- a/lib/getstream_ruby/generated/models/llm_rule.rb +++ b/lib/getstream_ruby/generated/models/llm_rule.rb @@ -9,15 +9,15 @@ module Models class LLMRule < GetStream::BaseModel # Model attributes - # @!attribute description - # @return [String] - attr_accessor :description # @!attribute label # @return [String] attr_accessor :label # @!attribute action # @return [String] attr_accessor :action + # @!attribute description + # @return [String] + attr_accessor :description # @!attribute severity_rules # @return [Array] attr_accessor :severity_rules @@ -25,18 +25,18 @@ class LLMRule < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) - @description = attributes[:description] || attributes['description'] @label = attributes[:label] || attributes['label'] @action = attributes[:action] || attributes['action'] || nil + @description = attributes[:description] || attributes['description'] || nil @severity_rules = attributes[:severity_rules] || attributes['severity_rules'] || nil end # Override field mappings for JSON serialization def self.json_field_mappings { - description: 'description', label: 'label', action: 'action', + description: 'description', severity_rules: 'severity_rules' } end diff --git a/lib/getstream_ruby/generated/models/matched_content.rb b/lib/getstream_ruby/generated/models/matched_content.rb new file mode 100644 index 0000000..ff2f845 --- /dev/null +++ b/lib/getstream_ruby/generated/models/matched_content.rb @@ -0,0 +1,61 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class MatchedContent < GetStream::BaseModel + + # Model attributes + # @!attribute id + # @return [String] The `content_ids[label]` value supplied on the `/analyze` request that contributed this entry. + attr_accessor :id + # @!attribute published_at + # @return [DateTime] `content_published_at` from the contributing `/analyze` request, or server receive time when that field was omitted. + attr_accessor :published_at + # @!attribute type + # @return [String] Content type that contributed this entry: `image` or `text`. + attr_accessor :type + # @!attribute confidence + # @return [Float] Image-classification entries only. Aggregate (max) confidence score across the entry's classifications + sub-classifications. Absent on text and OCR entries. + attr_accessor :confidence + # @!attribute severity + # @return [String] Text and OCR entries. Aggregate (max) Bodyguard severity level (`LOW` / `MEDIUM` / `HIGH` / `CRITICAL`). Absent on image-classification entries. + attr_accessor :severity + # @!attribute classifications + # @return [Array] Image-classification entries (keyframe rule, Type=image) carry nested L1 → L2 classifications. Text entries (closed_caption rule, Type=text) carry flat label + severity. Resolved against the app's effective taxonomy on the image side. + attr_accessor :classifications + # @!attribute ocr_classifications + # @return [Array] OCR entries only (keyframe_ocr rule, Type=image). Bodyguard labels that fired against the keyframe's OCR-extracted text (e.g. `INSULT`, `HATE_SPEECH`). Distinct from `classifications` so consumers can route OCR matches separately from image-classification matches. + attr_accessor :ocr_classifications + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @id = attributes[:id] || attributes['id'] + @published_at = attributes[:published_at] || attributes['published_at'] + @type = attributes[:type] || attributes['type'] + @confidence = attributes[:confidence] || attributes['confidence'] || nil + @severity = attributes[:severity] || attributes['severity'] || nil + @classifications = attributes[:classifications] || attributes['classifications'] || nil + @ocr_classifications = attributes[:ocr_classifications] || attributes['ocr_classifications'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + id: 'id', + published_at: 'published_at', + type: 'type', + confidence: 'confidence', + severity: 'severity', + classifications: 'classifications', + ocr_classifications: 'ocr_classifications' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/message_response.rb b/lib/getstream_ruby/generated/models/message_response.rb index cc62372..0be0da3 100644 --- a/lib/getstream_ruby/generated/models/message_response.rb +++ b/lib/getstream_ruby/generated/models/message_response.rb @@ -114,6 +114,9 @@ class MessageResponse < GetStream::BaseModel # @!attribute mentioned_group_ids # @return [Array] List of user group IDs mentioned in the message. Group members who are also channel members will receive push notifications based on their push preferences. Max 10 groups attr_accessor :mentioned_group_ids + # @!attribute mentioned_groups + # @return [Array] List of mentioned user group objects. + attr_accessor :mentioned_groups # @!attribute mentioned_roles # @return [Array] List of roles mentioned in the message (e.g. admin, channel_moderator, custom roles). Members with matching roles will receive push notifications based on their push preferences. Max 10 roles attr_accessor :mentioned_roles @@ -192,6 +195,7 @@ def initialize(attributes = {}) @quoted_message_id = attributes[:quoted_message_id] || attributes['quoted_message_id'] || nil @show_in_channel = attributes[:show_in_channel] || attributes['show_in_channel'] || nil @mentioned_group_ids = attributes[:mentioned_group_ids] || attributes['mentioned_group_ids'] || nil + @mentioned_groups = attributes[:mentioned_groups] || attributes['mentioned_groups'] || nil @mentioned_roles = attributes[:mentioned_roles] || attributes['mentioned_roles'] || nil @thread_participants = attributes[:thread_participants] || attributes['thread_participants'] || nil @draft = attributes[:draft] || attributes['draft'] || nil @@ -245,6 +249,7 @@ def self.json_field_mappings quoted_message_id: 'quoted_message_id', show_in_channel: 'show_in_channel', mentioned_group_ids: 'mentioned_group_ids', + mentioned_groups: 'mentioned_groups', mentioned_roles: 'mentioned_roles', thread_participants: 'thread_participants', draft: 'draft', diff --git a/lib/getstream_ruby/generated/models/message_with_channel_response.rb b/lib/getstream_ruby/generated/models/message_with_channel_response.rb index 82cd649..82e369a 100644 --- a/lib/getstream_ruby/generated/models/message_with_channel_response.rb +++ b/lib/getstream_ruby/generated/models/message_with_channel_response.rb @@ -117,6 +117,9 @@ class MessageWithChannelResponse < GetStream::BaseModel # @!attribute mentioned_group_ids # @return [Array] List of user group IDs mentioned in the message. Group members who are also channel members will receive push notifications based on their push preferences. Max 10 groups attr_accessor :mentioned_group_ids + # @!attribute mentioned_groups + # @return [Array] List of mentioned user group objects. + attr_accessor :mentioned_groups # @!attribute mentioned_roles # @return [Array] List of roles mentioned in the message (e.g. admin, channel_moderator, custom roles). Members with matching roles will receive push notifications based on their push preferences. Max 10 roles attr_accessor :mentioned_roles @@ -196,6 +199,7 @@ def initialize(attributes = {}) @quoted_message_id = attributes[:quoted_message_id] || attributes['quoted_message_id'] || nil @show_in_channel = attributes[:show_in_channel] || attributes['show_in_channel'] || nil @mentioned_group_ids = attributes[:mentioned_group_ids] || attributes['mentioned_group_ids'] || nil + @mentioned_groups = attributes[:mentioned_groups] || attributes['mentioned_groups'] || nil @mentioned_roles = attributes[:mentioned_roles] || attributes['mentioned_roles'] || nil @thread_participants = attributes[:thread_participants] || attributes['thread_participants'] || nil @draft = attributes[:draft] || attributes['draft'] || nil @@ -250,6 +254,7 @@ def self.json_field_mappings quoted_message_id: 'quoted_message_id', show_in_channel: 'show_in_channel', mentioned_group_ids: 'mentioned_group_ids', + mentioned_groups: 'mentioned_groups', mentioned_roles: 'mentioned_roles', thread_participants: 'thread_participants', draft: 'draft', diff --git a/lib/getstream_ruby/generated/models/moderation_ban_response.rb b/lib/getstream_ruby/generated/models/moderation_ban_response.rb new file mode 100644 index 0000000..7adbcd2 --- /dev/null +++ b/lib/getstream_ruby/generated/models/moderation_ban_response.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class ModerationBanResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/moderation_config.rb b/lib/getstream_ruby/generated/models/moderation_config.rb index 648ad58..29b8980 100644 --- a/lib/getstream_ruby/generated/models/moderation_config.rb +++ b/lib/getstream_ruby/generated/models/moderation_config.rb @@ -51,6 +51,9 @@ class ModerationConfig < GetStream::BaseModel # @!attribute block_list_config # @return [BlockListConfig] attr_accessor :block_list_config + # @!attribute flood_config + # @return [FloodConfig] + attr_accessor :flood_config # @!attribute google_vision_config # @return [GoogleVisionConfig] attr_accessor :google_vision_config @@ -81,6 +84,7 @@ def initialize(attributes = {}) @automod_semantic_filters_config = attributes[:automod_semantic_filters_config] || attributes['automod_semantic_filters_config'] || nil @automod_toxicity_config = attributes[:automod_toxicity_config] || attributes['automod_toxicity_config'] || nil @block_list_config = attributes[:block_list_config] || attributes['block_list_config'] || nil + @flood_config = attributes[:flood_config] || attributes['flood_config'] || nil @google_vision_config = attributes[:google_vision_config] || attributes['google_vision_config'] || nil @llm_config = attributes[:llm_config] || attributes['llm_config'] || nil @velocity_filter_config = attributes[:velocity_filter_config] || attributes['velocity_filter_config'] || nil @@ -104,6 +108,7 @@ def self.json_field_mappings automod_semantic_filters_config: 'automod_semantic_filters_config', automod_toxicity_config: 'automod_toxicity_config', block_list_config: 'block_list_config', + flood_config: 'flood_config', google_vision_config: 'google_vision_config', llm_config: 'llm_config', velocity_filter_config: 'velocity_filter_config', diff --git a/lib/getstream_ruby/generated/models/moderation_dashboard_preferences.rb b/lib/getstream_ruby/generated/models/moderation_dashboard_preferences.rb index 33ea6c4..29b3a8a 100644 --- a/lib/getstream_ruby/generated/models/moderation_dashboard_preferences.rb +++ b/lib/getstream_ruby/generated/models/moderation_dashboard_preferences.rb @@ -9,6 +9,9 @@ module Models class ModerationDashboardPreferences < GetStream::BaseModel # Model attributes + # @!attribute analyze_max_image_size_bytes + # @return [Integer] + attr_accessor :analyze_max_image_size_bytes # @!attribute async_review_queue_upsert # @return [Boolean] attr_accessor :async_review_queue_upsert @@ -30,12 +33,18 @@ class ModerationDashboardPreferences < GetStream::BaseModel # @!attribute media_queue_blur_enabled # @return [Boolean] attr_accessor :media_queue_blur_enabled + # @!attribute webhook_header_client_request_id_key + # @return [String] + attr_accessor :webhook_header_client_request_id_key # @!attribute allowed_moderation_action_reasons # @return [Array] attr_accessor :allowed_moderation_action_reasons # @!attribute escalation_reasons # @return [Array] attr_accessor :escalation_reasons + # @!attribute filterable_custom_keys + # @return [Array] + attr_accessor :filterable_custom_keys # @!attribute keyframe_classifications_map # @return [Hash>] attr_accessor :keyframe_classifications_map @@ -46,6 +55,7 @@ class ModerationDashboardPreferences < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) + @analyze_max_image_size_bytes = attributes[:analyze_max_image_size_bytes] || attributes['analyze_max_image_size_bytes'] || nil @async_review_queue_upsert = attributes[:async_review_queue_upsert] || attributes['async_review_queue_upsert'] || nil @disable_audit_logs = attributes[:disable_audit_logs] || attributes['disable_audit_logs'] || nil @disable_flagging_reviewed_entity = attributes[:disable_flagging_reviewed_entity] || attributes['disable_flagging_reviewed_entity'] || nil @@ -53,8 +63,10 @@ def initialize(attributes = {}) @flag_user_on_flagged_content = attributes[:flag_user_on_flagged_content] || attributes['flag_user_on_flagged_content'] || nil @include_attachment_payload = attributes[:include_attachment_payload] || attributes['include_attachment_payload'] || nil @media_queue_blur_enabled = attributes[:media_queue_blur_enabled] || attributes['media_queue_blur_enabled'] || nil + @webhook_header_client_request_id_key = attributes[:webhook_header_client_request_id_key] || attributes['webhook_header_client_request_id_key'] || nil @allowed_moderation_action_reasons = attributes[:allowed_moderation_action_reasons] || attributes['allowed_moderation_action_reasons'] || nil @escalation_reasons = attributes[:escalation_reasons] || attributes['escalation_reasons'] || nil + @filterable_custom_keys = attributes[:filterable_custom_keys] || attributes['filterable_custom_keys'] || nil @keyframe_classifications_map = attributes[:keyframe_classifications_map] || attributes['keyframe_classifications_map'] || nil @overview_dashboard = attributes[:overview_dashboard] || attributes['overview_dashboard'] || nil end @@ -62,6 +74,7 @@ def initialize(attributes = {}) # Override field mappings for JSON serialization def self.json_field_mappings { + analyze_max_image_size_bytes: 'analyze_max_image_size_bytes', async_review_queue_upsert: 'async_review_queue_upsert', disable_audit_logs: 'disable_audit_logs', disable_flagging_reviewed_entity: 'disable_flagging_reviewed_entity', @@ -69,8 +82,10 @@ def self.json_field_mappings flag_user_on_flagged_content: 'flag_user_on_flagged_content', include_attachment_payload: 'include_attachment_payload', media_queue_blur_enabled: 'media_queue_blur_enabled', + webhook_header_client_request_id_key: 'webhook_header_client_request_id_key', allowed_moderation_action_reasons: 'allowed_moderation_action_reasons', escalation_reasons: 'escalation_reasons', + filterable_custom_keys: 'filterable_custom_keys', keyframe_classifications_map: 'keyframe_classifications_map', overview_dashboard: 'overview_dashboard' } diff --git a/lib/getstream_ruby/generated/models/moderation_image_analysis_complete_event.rb b/lib/getstream_ruby/generated/models/moderation_image_analysis_complete_event.rb new file mode 100644 index 0000000..5d25283 --- /dev/null +++ b/lib/getstream_ruby/generated/models/moderation_image_analysis_complete_event.rb @@ -0,0 +1,81 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Per-image moderation verdict from /analyze. Fires on every /analyze call that included image inputs (callers also get the verdict on the HTTP response — this event is the audit / reconciliation tap). For the /analyze origin it replaces the legacy review_queue_item.* + moderation_check.completed events. + class ModerationImageAnalysisCompleteEvent < GetStream::BaseModel + + # Model attributes + # @!attribute created_at + # @return [DateTime] + attr_accessor :created_at + # @!attribute type + # @return [String] + attr_accessor :type + # @!attribute config_key + # @return [String] The moderation policy key that was applied. + attr_accessor :config_key + # @!attribute entity_creator_id + # @return [String] Echo of the `entity_creator_id` on the /analyze request. + attr_accessor :entity_creator_id + # @!attribute entity_id + # @return [String] Echo of the `entity_id` on the /analyze request. + attr_accessor :entity_id + # @!attribute entity_type + # @return [String] Echo of the `entity_type` on the /analyze request. + attr_accessor :entity_type + # @!attribute received_at + # @return [DateTime] + attr_accessor :received_at + # @!attribute review_queue_item_id + # @return [String] Review queue row ID for deep-linking into the dashboard. + attr_accessor :review_queue_item_id + # @!attribute custom + # @return [Object] Echo of the `custom` metadata on the /analyze request. + attr_accessor :custom + # @!attribute images + # @return [Hash] Per-image verdicts, same shape as the /analyze HTTP response. Each entry carries `id` when the request supplied `content_ids`. + attr_accessor :images + # @!attribute texts + # @return [Hash] Per-text-field verdicts, same shape as the /analyze HTTP response. Each entry carries `id` when the request supplied `content_ids`. + attr_accessor :texts + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @created_at = attributes[:created_at] || attributes['created_at'] + @type = attributes[:type] || attributes['type'] || "moderation.image_analysis.complete" + @config_key = attributes[:config_key] || attributes['config_key'] || nil + @entity_creator_id = attributes[:entity_creator_id] || attributes['entity_creator_id'] || nil + @entity_id = attributes[:entity_id] || attributes['entity_id'] || nil + @entity_type = attributes[:entity_type] || attributes['entity_type'] || nil + @received_at = attributes[:received_at] || attributes['received_at'] || nil + @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil + @custom = attributes[:custom] || attributes['custom'] || nil + @images = attributes[:images] || attributes['images'] || nil + @texts = attributes[:texts] || attributes['texts'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + created_at: 'created_at', + type: 'type', + config_key: 'config_key', + entity_creator_id: 'entity_creator_id', + entity_id: 'entity_id', + entity_type: 'entity_type', + received_at: 'received_at', + review_queue_item_id: 'review_queue_item_id', + custom: 'custom', + images: 'images', + texts: 'texts' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/moderation_rules_triggered_event.rb b/lib/getstream_ruby/generated/models/moderation_rules_triggered_event.rb index 37265b0..57eed56 100644 --- a/lib/getstream_ruby/generated/models/moderation_rules_triggered_event.rb +++ b/lib/getstream_ruby/generated/models/moderation_rules_triggered_event.rb @@ -42,6 +42,9 @@ class ModerationRulesTriggeredEvent < GetStream::BaseModel # @!attribute violation_number # @return [Integer] The violation number for call rules (optional) attr_accessor :violation_number + # @!attribute matched_contents + # @return [Array] Ordered list of contents whose verdicts contributed to an aggregation rule's threshold. Populated only for aggregation rules when callers supplied `content_ids`. + attr_accessor :matched_contents # Initialize with attributes def initialize(attributes = {}) @@ -57,6 +60,7 @@ def initialize(attributes = {}) @received_at = attributes[:received_at] || attributes['received_at'] || nil @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil @violation_number = attributes[:violation_number] || attributes['violation_number'] || nil + @matched_contents = attributes[:matched_contents] || attributes['matched_contents'] || nil end # Override field mappings for JSON serialization @@ -72,7 +76,8 @@ def self.json_field_mappings type: 'type', received_at: 'received_at', review_queue_item_id: 'review_queue_item_id', - violation_number: 'violation_number' + violation_number: 'violation_number', + matched_contents: 'matched_contents' } end end diff --git a/lib/getstream_ruby/generated/models/moderation_text_analysis_complete_event.rb b/lib/getstream_ruby/generated/models/moderation_text_analysis_complete_event.rb new file mode 100644 index 0000000..77018a7 --- /dev/null +++ b/lib/getstream_ruby/generated/models/moderation_text_analysis_complete_event.rb @@ -0,0 +1,76 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Per-text moderation verdict from /analyze. Fires on every /analyze call that included text inputs. Sibling of moderation.image_analysis.complete with the same audit / reconciliation purpose; for the /analyze origin this event replaces the legacy review_queue_item.* + moderation_check.completed events. + class ModerationTextAnalysisCompleteEvent < GetStream::BaseModel + + # Model attributes + # @!attribute created_at + # @return [DateTime] + attr_accessor :created_at + # @!attribute type + # @return [String] + attr_accessor :type + # @!attribute config_key + # @return [String] The moderation policy key that was applied. + attr_accessor :config_key + # @!attribute entity_creator_id + # @return [String] Echo of the `entity_creator_id` on the /analyze request. + attr_accessor :entity_creator_id + # @!attribute entity_id + # @return [String] Echo of the `entity_id` on the /analyze request. + attr_accessor :entity_id + # @!attribute entity_type + # @return [String] Echo of the `entity_type` on the /analyze request. + attr_accessor :entity_type + # @!attribute received_at + # @return [DateTime] + attr_accessor :received_at + # @!attribute review_queue_item_id + # @return [String] Review queue row ID for deep-linking into the dashboard. + attr_accessor :review_queue_item_id + # @!attribute custom + # @return [Object] Echo of the `custom` metadata on the /analyze request. + attr_accessor :custom + # @!attribute texts + # @return [Hash] Per-text-field verdicts, same shape as the /analyze HTTP response. Each entry carries `id` when the request supplied `content_ids`. + attr_accessor :texts + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @created_at = attributes[:created_at] || attributes['created_at'] + @type = attributes[:type] || attributes['type'] || "moderation.text_analysis.complete" + @config_key = attributes[:config_key] || attributes['config_key'] || nil + @entity_creator_id = attributes[:entity_creator_id] || attributes['entity_creator_id'] || nil + @entity_id = attributes[:entity_id] || attributes['entity_id'] || nil + @entity_type = attributes[:entity_type] || attributes['entity_type'] || nil + @received_at = attributes[:received_at] || attributes['received_at'] || nil + @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil + @custom = attributes[:custom] || attributes['custom'] || nil + @texts = attributes[:texts] || attributes['texts'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + created_at: 'created_at', + type: 'type', + config_key: 'config_key', + entity_creator_id: 'entity_creator_id', + entity_id: 'entity_id', + entity_type: 'entity_type', + received_at: 'received_at', + review_queue_item_id: 'review_queue_item_id', + custom: 'custom', + texts: 'texts' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/query_moderation_rules_response.rb b/lib/getstream_ruby/generated/models/query_moderation_rules_response.rb index fe8e249..bf5fd2b 100644 --- a/lib/getstream_ruby/generated/models/query_moderation_rules_response.rb +++ b/lib/getstream_ruby/generated/models/query_moderation_rules_response.rb @@ -21,6 +21,9 @@ class QueryModerationRulesResponse < GetStream::BaseModel # @!attribute keyframe_labels # @return [Array] Deprecated: use keyframe_label_classifications instead. Available L1 harm labels for keyframe rules attr_accessor :keyframe_labels + # @!attribute ocr_labels + # @return [Array] Available harm labels for keyframe OCR rules. Mirrors `closed_caption_labels` today but kept as a separate field so the two pickers can diverge later. + attr_accessor :ocr_labels # @!attribute rules # @return [Array] List of moderation rules attr_accessor :rules @@ -30,6 +33,9 @@ class QueryModerationRulesResponse < GetStream::BaseModel # @!attribute default_llm_labels # @return [Hash] Default LLM label descriptions attr_accessor :default_llm_labels + # @!attribute default_username_llm_labels + # @return [Hash] Recommended LLM label descriptions for username-scoped policies (key starts with 'username:'). Used by /moderation/v2/labels fast-path. + attr_accessor :default_username_llm_labels # @!attribute keyframe_label_classifications # @return [Hash>] L1 to L2 mapping of keyframe harm label classifications attr_accessor :keyframe_label_classifications @@ -47,9 +53,11 @@ def initialize(attributes = {}) @ai_image_label_definitions = attributes[:ai_image_label_definitions] || attributes['ai_image_label_definitions'] @closed_caption_labels = attributes[:closed_caption_labels] || attributes['closed_caption_labels'] @keyframe_labels = attributes[:keyframe_labels] || attributes['keyframe_labels'] + @ocr_labels = attributes[:ocr_labels] || attributes['ocr_labels'] @rules = attributes[:rules] || attributes['rules'] @ai_image_subclassifications = attributes[:ai_image_subclassifications] || attributes['ai_image_subclassifications'] @default_llm_labels = attributes[:default_llm_labels] || attributes['default_llm_labels'] + @default_username_llm_labels = attributes[:default_username_llm_labels] || attributes['default_username_llm_labels'] @keyframe_label_classifications = attributes[:keyframe_label_classifications] || attributes['keyframe_label_classifications'] @next = attributes[:next] || attributes['next'] || nil @prev = attributes[:prev] || attributes['prev'] || nil @@ -62,9 +70,11 @@ def self.json_field_mappings ai_image_label_definitions: 'ai_image_label_definitions', closed_caption_labels: 'closed_caption_labels', keyframe_labels: 'keyframe_labels', + ocr_labels: 'ocr_labels', rules: 'rules', ai_image_subclassifications: 'ai_image_subclassifications', default_llm_labels: 'default_llm_labels', + default_username_llm_labels: 'default_username_llm_labels', keyframe_label_classifications: 'keyframe_label_classifications', next: 'next', prev: 'prev' diff --git a/lib/getstream_ruby/generated/models/query_review_queue_request.rb b/lib/getstream_ruby/generated/models/query_review_queue_request.rb index 011b836..6439993 100644 --- a/lib/getstream_ruby/generated/models/query_review_queue_request.rb +++ b/lib/getstream_ruby/generated/models/query_review_queue_request.rb @@ -40,7 +40,7 @@ class QueryReviewQueueRequest < GetStream::BaseModel # @return [Array] Sorting parameters for the results attr_accessor :sort # @!attribute filter - # @return [Object] Filter conditions for review queue items + # @return [Object] Filter conditions for review queue items. Accepts built-in fields (e.g. status, channel_cid, severity, recommended_action) and customer-supplied moderation_payload.custom keys: any key that is not a built-in field is matched against the item's custom moderation data (e.g. {"location_id": "loc-42"}). Use filter_config.filterable_custom_keys to discover which custom keys the app exposes as chips. attr_accessor :filter # @!attribute user # @return [UserRequest] diff --git a/lib/getstream_ruby/generated/models/read_receipts_response.rb b/lib/getstream_ruby/generated/models/read_receipts_response.rb index 309b54c..d56a6f9 100644 --- a/lib/getstream_ruby/generated/models/read_receipts_response.rb +++ b/lib/getstream_ruby/generated/models/read_receipts_response.rb @@ -16,7 +16,7 @@ class ReadReceiptsResponse < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) - @enabled = attributes[:enabled] || attributes['enabled'] || nil + @enabled = attributes[:enabled] || attributes['enabled'] end # Override field mappings for JSON serialization diff --git a/lib/getstream_ruby/generated/models/report_client_event_request.rb b/lib/getstream_ruby/generated/models/report_client_event_request.rb new file mode 100644 index 0000000..629fbae --- /dev/null +++ b/lib/getstream_ruby/generated/models/report_client_event_request.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Reports a batch of client-side telemetry events. Each event is validated and processed independently; one invalid event does not block the rest of the batch. + class ReportClientEventRequest < GetStream::BaseModel + + # Model attributes + # @!attribute events + # @return [Array] Client-side events to report (1-100 per request) + attr_accessor :events + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @events = attributes[:events] || attributes['events'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + events: 'events' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/report_client_event_response.rb b/lib/getstream_ruby/generated/models/report_client_event_response.rb new file mode 100644 index 0000000..e5c2316 --- /dev/null +++ b/lib/getstream_ruby/generated/models/report_client_event_response.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # Response for reporting client-side telemetry events + class ReportClientEventResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] Duration of the request in milliseconds + attr_accessor :duration + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/rule_builder_action.rb b/lib/getstream_ruby/generated/models/rule_builder_action.rb index 489c0e4..f42b59d 100644 --- a/lib/getstream_ruby/generated/models/rule_builder_action.rb +++ b/lib/getstream_ruby/generated/models/rule_builder_action.rb @@ -9,6 +9,9 @@ module Models class RuleBuilderAction < GetStream::BaseModel # Model attributes + # @!attribute reason + # @return [String] + attr_accessor :reason # @!attribute skip_inbox # @return [Boolean] attr_accessor :skip_inbox @@ -28,6 +31,7 @@ class RuleBuilderAction < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) + @reason = attributes[:reason] || attributes['reason'] || nil @skip_inbox = attributes[:skip_inbox] || attributes['skip_inbox'] || nil @type = attributes[:type] || attributes['type'] || nil @ban_options = attributes[:ban_options] || attributes['ban_options'] || nil @@ -38,6 +42,7 @@ def initialize(attributes = {}) # Override field mappings for JSON serialization def self.json_field_mappings { + reason: 'reason', skip_inbox: 'skip_inbox', type: 'type', ban_options: 'ban_options', diff --git a/lib/getstream_ruby/generated/models/rule_builder_condition.rb b/lib/getstream_ruby/generated/models/rule_builder_condition.rb index ec4289d..aa3c25f 100644 --- a/lib/getstream_ruby/generated/models/rule_builder_condition.rb +++ b/lib/getstream_ruby/generated/models/rule_builder_condition.rb @@ -33,6 +33,12 @@ class RuleBuilderCondition < GetStream::BaseModel # @!attribute content_count_rule_params # @return [ContentCountRuleParameters] attr_accessor :content_count_rule_params + # @!attribute content_custom_property_count_params + # @return [ContentCustomPropertyCountParameters] + attr_accessor :content_custom_property_count_params + # @!attribute content_custom_property_params + # @return [ContentCustomPropertyParameters] + attr_accessor :content_custom_property_params # @!attribute content_flag_count_rule_params # @return [FlagCountRuleParameters] attr_accessor :content_flag_count_rule_params @@ -42,6 +48,9 @@ class RuleBuilderCondition < GetStream::BaseModel # @!attribute image_rule_params # @return [ImageRuleParameters] attr_accessor :image_rule_params + # @!attribute keyframe_ocr_rule_params + # @return [KeyframeOCRRuleParameters] + attr_accessor :keyframe_ocr_rule_params # @!attribute keyframe_rule_params # @return [KeyframeRuleParameters] attr_accessor :keyframe_rule_params @@ -87,9 +96,12 @@ def initialize(attributes = {}) @channel_message_count_rule_params = attributes[:channel_message_count_rule_params] || attributes['channel_message_count_rule_params'] || nil @closed_caption_rule_params = attributes[:closed_caption_rule_params] || attributes['closed_caption_rule_params'] || nil @content_count_rule_params = attributes[:content_count_rule_params] || attributes['content_count_rule_params'] || nil + @content_custom_property_count_params = attributes[:content_custom_property_count_params] || attributes['content_custom_property_count_params'] || nil + @content_custom_property_params = attributes[:content_custom_property_params] || attributes['content_custom_property_params'] || nil @content_flag_count_rule_params = attributes[:content_flag_count_rule_params] || attributes['content_flag_count_rule_params'] || nil @image_content_params = attributes[:image_content_params] || attributes['image_content_params'] || nil @image_rule_params = attributes[:image_rule_params] || attributes['image_rule_params'] || nil + @keyframe_ocr_rule_params = attributes[:keyframe_ocr_rule_params] || attributes['keyframe_ocr_rule_params'] || nil @keyframe_rule_params = attributes[:keyframe_rule_params] || attributes['keyframe_rule_params'] || nil @text_content_params = attributes[:text_content_params] || attributes['text_content_params'] || nil @text_rule_params = attributes[:text_rule_params] || attributes['text_rule_params'] || nil @@ -114,9 +126,12 @@ def self.json_field_mappings channel_message_count_rule_params: 'channel_message_count_rule_params', closed_caption_rule_params: 'closed_caption_rule_params', content_count_rule_params: 'content_count_rule_params', + content_custom_property_count_params: 'content_custom_property_count_params', + content_custom_property_params: 'content_custom_property_params', content_flag_count_rule_params: 'content_flag_count_rule_params', image_content_params: 'image_content_params', image_rule_params: 'image_rule_params', + keyframe_ocr_rule_params: 'keyframe_ocr_rule_params', keyframe_rule_params: 'keyframe_rule_params', text_content_params: 'text_content_params', text_rule_params: 'text_rule_params', diff --git a/lib/getstream_ruby/generated/models/search_result_message.rb b/lib/getstream_ruby/generated/models/search_result_message.rb index f3e1317..1ff5cbf 100644 --- a/lib/getstream_ruby/generated/models/search_result_message.rb +++ b/lib/getstream_ruby/generated/models/search_result_message.rb @@ -114,6 +114,9 @@ class SearchResultMessage < GetStream::BaseModel # @!attribute mentioned_group_ids # @return [Array] attr_accessor :mentioned_group_ids + # @!attribute mentioned_groups + # @return [Array] + attr_accessor :mentioned_groups # @!attribute mentioned_roles # @return [Array] attr_accessor :mentioned_roles @@ -195,6 +198,7 @@ def initialize(attributes = {}) @quoted_message_id = attributes[:quoted_message_id] || attributes['quoted_message_id'] || nil @show_in_channel = attributes[:show_in_channel] || attributes['show_in_channel'] || nil @mentioned_group_ids = attributes[:mentioned_group_ids] || attributes['mentioned_group_ids'] || nil + @mentioned_groups = attributes[:mentioned_groups] || attributes['mentioned_groups'] || nil @mentioned_roles = attributes[:mentioned_roles] || attributes['mentioned_roles'] || nil @thread_participants = attributes[:thread_participants] || attributes['thread_participants'] || nil @channel = attributes[:channel] || attributes['channel'] || nil @@ -249,6 +253,7 @@ def self.json_field_mappings quoted_message_id: 'quoted_message_id', show_in_channel: 'show_in_channel', mentioned_group_ids: 'mentioned_group_ids', + mentioned_groups: 'mentioned_groups', mentioned_roles: 'mentioned_roles', thread_participants: 'thread_participants', channel: 'channel', diff --git a/lib/getstream_ruby/generated/models/setup_session.rb b/lib/getstream_ruby/generated/models/setup_session.rb new file mode 100644 index 0000000..14a7643 --- /dev/null +++ b/lib/getstream_ruby/generated/models/setup_session.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class SetupSession < GetStream::BaseModel + + # Model attributes + # @!attribute created_at + # @return [DateTime] + attr_accessor :created_at + # @!attribute current_step + # @return [String] + attr_accessor :current_step + # @!attribute status + # @return [String] + attr_accessor :status + # @!attribute updated_at + # @return [DateTime] + attr_accessor :updated_at + # @!attribute setup_data + # @return [Object] + attr_accessor :setup_data + # @!attribute completed_at + # @return [DateTime] + attr_accessor :completed_at + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @created_at = attributes[:created_at] || attributes['created_at'] + @current_step = attributes[:current_step] || attributes['current_step'] + @status = attributes[:status] || attributes['status'] + @updated_at = attributes[:updated_at] || attributes['updated_at'] + @setup_data = attributes[:setup_data] || attributes['setup_data'] + @completed_at = attributes[:completed_at] || attributes['completed_at'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + created_at: 'created_at', + current_step: 'current_step', + status: 'status', + updated_at: 'updated_at', + setup_data: 'setup_data', + completed_at: 'completed_at' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/submit_action_response.rb b/lib/getstream_ruby/generated/models/submit_action_response.rb index b266fdc..7454ab1 100644 --- a/lib/getstream_ruby/generated/models/submit_action_response.rb +++ b/lib/getstream_ruby/generated/models/submit_action_response.rb @@ -12,6 +12,9 @@ class SubmitActionResponse < GetStream::BaseModel # @!attribute duration # @return [String] attr_accessor :duration + # @!attribute auto_restore_warning + # @return [String] Present when the appeal was accepted but the entity could not be restored automatically. The moderator should restore it manually. + attr_accessor :auto_restore_warning # @!attribute appeal_item # @return [AppealItemResponse] attr_accessor :appeal_item @@ -23,6 +26,7 @@ class SubmitActionResponse < GetStream::BaseModel def initialize(attributes = {}) super(attributes) @duration = attributes[:duration] || attributes['duration'] + @auto_restore_warning = attributes[:auto_restore_warning] || attributes['auto_restore_warning'] || nil @appeal_item = attributes[:appeal_item] || attributes['appeal_item'] || nil @item = attributes[:item] || attributes['item'] || nil end @@ -31,6 +35,7 @@ def initialize(attributes = {}) def self.json_field_mappings { duration: 'duration', + auto_restore_warning: 'auto_restore_warning', appeal_item: 'appeal_item', item: 'item' } diff --git a/lib/getstream_ruby/generated/models/target_resolution.rb b/lib/getstream_ruby/generated/models/target_resolution.rb index 05e7d15..2300612 100644 --- a/lib/getstream_ruby/generated/models/target_resolution.rb +++ b/lib/getstream_ruby/generated/models/target_resolution.rb @@ -9,30 +9,30 @@ module Models class TargetResolution < GetStream::BaseModel # Model attributes - # @!attribute bitrate - # @return [Integer] - attr_accessor :bitrate # @!attribute height # @return [Integer] attr_accessor :height # @!attribute width # @return [Integer] attr_accessor :width + # @!attribute bitrate + # @return [Integer] + attr_accessor :bitrate # Initialize with attributes def initialize(attributes = {}) super(attributes) - @bitrate = attributes[:bitrate] || attributes['bitrate'] @height = attributes[:height] || attributes['height'] @width = attributes[:width] || attributes['width'] + @bitrate = attributes[:bitrate] || attributes['bitrate'] || nil end # Override field mappings for JSON serialization def self.json_field_mappings { - bitrate: 'bitrate', height: 'height', - width: 'width' + width: 'width', + bitrate: 'bitrate' } end end diff --git a/lib/getstream_ruby/generated/models/text_content_parameters.rb b/lib/getstream_ruby/generated/models/text_content_parameters.rb index f46fb5a..15df07c 100644 --- a/lib/getstream_ruby/generated/models/text_content_parameters.rb +++ b/lib/getstream_ruby/generated/models/text_content_parameters.rb @@ -18,6 +18,12 @@ class TextContentParameters < GetStream::BaseModel # @!attribute severity # @return [String] attr_accessor :severity + # @!attribute text_length + # @return [Integer] + attr_accessor :text_length + # @!attribute text_length_operator + # @return [String] + attr_accessor :text_length_operator # @!attribute blocklist_match # @return [Array] attr_accessor :blocklist_match @@ -34,6 +40,8 @@ def initialize(attributes = {}) @contains_url = attributes[:contains_url] || attributes['contains_url'] || nil @label_operator = attributes[:label_operator] || attributes['label_operator'] || nil @severity = attributes[:severity] || attributes['severity'] || nil + @text_length = attributes[:text_length] || attributes['text_length'] || nil + @text_length_operator = attributes[:text_length_operator] || attributes['text_length_operator'] || nil @blocklist_match = attributes[:blocklist_match] || attributes['blocklist_match'] || nil @harm_labels = attributes[:harm_labels] || attributes['harm_labels'] || nil @llm_harm_labels = attributes[:llm_harm_labels] || attributes['llm_harm_labels'] || nil @@ -45,6 +53,8 @@ def self.json_field_mappings contains_url: 'contains_url', label_operator: 'label_operator', severity: 'severity', + text_length: 'text_length', + text_length_operator: 'text_length_operator', blocklist_match: 'blocklist_match', harm_labels: 'harm_labels', llm_harm_labels: 'llm_harm_labels' diff --git a/lib/getstream_ruby/generated/models/translation_settings.rb b/lib/getstream_ruby/generated/models/translation_settings.rb index 4b25a03..af1dbad 100644 --- a/lib/getstream_ruby/generated/models/translation_settings.rb +++ b/lib/getstream_ruby/generated/models/translation_settings.rb @@ -19,8 +19,8 @@ class TranslationSettings < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) - @enabled = attributes[:enabled] || attributes['enabled'] - @languages = attributes[:languages] || attributes['languages'] + @enabled = attributes[:enabled] || attributes['enabled'] || nil + @languages = attributes[:languages] || attributes['languages'] || nil end # Override field mappings for JSON serialization diff --git a/lib/getstream_ruby/generated/models/typing_indicators_response.rb b/lib/getstream_ruby/generated/models/typing_indicators_response.rb index 4a31562..84f92a3 100644 --- a/lib/getstream_ruby/generated/models/typing_indicators_response.rb +++ b/lib/getstream_ruby/generated/models/typing_indicators_response.rb @@ -16,7 +16,7 @@ class TypingIndicatorsResponse < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) - @enabled = attributes[:enabled] || attributes['enabled'] || nil + @enabled = attributes[:enabled] || attributes['enabled'] end # Override field mappings for JSON serialization diff --git a/lib/getstream_ruby/generated/models/update_app_request.rb b/lib/getstream_ruby/generated/models/update_app_request.rb index 401341c..bbb8e6c 100644 --- a/lib/getstream_ruby/generated/models/update_app_request.rb +++ b/lib/getstream_ruby/generated/models/update_app_request.rb @@ -15,6 +15,9 @@ class UpdateAppRequest < GetStream::BaseModel # @!attribute auto_translation_enabled # @return [Boolean] attr_accessor :auto_translation_enabled + # @!attribute before_message_send_hook_attempt_timeout_ms + # @return [Integer] + attr_accessor :before_message_send_hook_attempt_timeout_ms # @!attribute before_message_send_hook_url # @return [String] attr_accessor :before_message_send_hook_url @@ -63,6 +66,9 @@ class UpdateAppRequest < GetStream::BaseModel # @!attribute moderation_enabled # @return [Boolean] attr_accessor :moderation_enabled + # @!attribute moderation_onboarding_complete + # @return [Boolean] + attr_accessor :moderation_onboarding_complete # @!attribute moderation_s3_image_access_role_arn # @return [String] attr_accessor :moderation_s3_image_access_role_arn @@ -105,6 +111,9 @@ class UpdateAppRequest < GetStream::BaseModel # @!attribute user_response_time_enabled # @return [Boolean] attr_accessor :user_response_time_enabled + # @!attribute video_primary_use_case + # @return [String] + attr_accessor :video_primary_use_case # @!attribute webhook_url # @return [String] attr_accessor :webhook_url @@ -168,6 +177,7 @@ def initialize(attributes = {}) super(attributes) @async_url_enrich_enabled = attributes[:async_url_enrich_enabled] || attributes['async_url_enrich_enabled'] || nil @auto_translation_enabled = attributes[:auto_translation_enabled] || attributes['auto_translation_enabled'] || nil + @before_message_send_hook_attempt_timeout_ms = attributes[:before_message_send_hook_attempt_timeout_ms] || attributes['before_message_send_hook_attempt_timeout_ms'] || nil @before_message_send_hook_url = attributes[:before_message_send_hook_url] || attributes['before_message_send_hook_url'] || nil @cdn_expiration_seconds = attributes[:cdn_expiration_seconds] || attributes['cdn_expiration_seconds'] || nil @channel_hide_members_only = attributes[:channel_hide_members_only] || attributes['channel_hide_members_only'] || nil @@ -184,6 +194,7 @@ def initialize(attributes = {}) @migrate_permissions_to_v2 = attributes[:migrate_permissions_to_v2] || attributes['migrate_permissions_to_v2'] || nil @moderation_analytics_enabled = attributes[:moderation_analytics_enabled] || attributes['moderation_analytics_enabled'] || nil @moderation_enabled = attributes[:moderation_enabled] || attributes['moderation_enabled'] || nil + @moderation_onboarding_complete = attributes[:moderation_onboarding_complete] || attributes['moderation_onboarding_complete'] || nil @moderation_s3_image_access_role_arn = attributes[:moderation_s3_image_access_role_arn] || attributes['moderation_s3_image_access_role_arn'] || nil @moderation_webhook_url = attributes[:moderation_webhook_url] || attributes['moderation_webhook_url'] || nil @multi_tenant_enabled = attributes[:multi_tenant_enabled] || attributes['multi_tenant_enabled'] || nil @@ -198,6 +209,7 @@ def initialize(attributes = {}) @sqs_secret = attributes[:sqs_secret] || attributes['sqs_secret'] || nil @sqs_url = attributes[:sqs_url] || attributes['sqs_url'] || nil @user_response_time_enabled = attributes[:user_response_time_enabled] || attributes['user_response_time_enabled'] || nil + @video_primary_use_case = attributes[:video_primary_use_case] || attributes['video_primary_use_case'] || nil @webhook_url = attributes[:webhook_url] || attributes['webhook_url'] || nil @allowed_flag_reasons = attributes[:allowed_flag_reasons] || attributes['allowed_flag_reasons'] || nil @event_hooks = attributes[:event_hooks] || attributes['event_hooks'] || nil @@ -224,6 +236,7 @@ def self.json_field_mappings { async_url_enrich_enabled: 'async_url_enrich_enabled', auto_translation_enabled: 'auto_translation_enabled', + before_message_send_hook_attempt_timeout_ms: 'before_message_send_hook_attempt_timeout_ms', before_message_send_hook_url: 'before_message_send_hook_url', cdn_expiration_seconds: 'cdn_expiration_seconds', channel_hide_members_only: 'channel_hide_members_only', @@ -240,6 +253,7 @@ def self.json_field_mappings migrate_permissions_to_v2: 'migrate_permissions_to_v2', moderation_analytics_enabled: 'moderation_analytics_enabled', moderation_enabled: 'moderation_enabled', + moderation_onboarding_complete: 'moderation_onboarding_complete', moderation_s3_image_access_role_arn: 'moderation_s3_image_access_role_arn', moderation_webhook_url: 'moderation_webhook_url', multi_tenant_enabled: 'multi_tenant_enabled', @@ -254,6 +268,7 @@ def self.json_field_mappings sqs_secret: 'sqs_secret', sqs_url: 'sqs_url', user_response_time_enabled: 'user_response_time_enabled', + video_primary_use_case: 'video_primary_use_case', webhook_url: 'webhook_url', allowed_flag_reasons: 'allowed_flag_reasons', event_hooks: 'event_hooks', diff --git a/lib/getstream_ruby/generated/models/update_block_list_request.rb b/lib/getstream_ruby/generated/models/update_block_list_request.rb index 03040a2..cf91e97 100644 --- a/lib/getstream_ruby/generated/models/update_block_list_request.rb +++ b/lib/getstream_ruby/generated/models/update_block_list_request.rb @@ -9,12 +9,18 @@ module Models class UpdateBlockListRequest < GetStream::BaseModel # Model attributes + # @!attribute is_confusable_folding_enabled + # @return [Boolean] + attr_accessor :is_confusable_folding_enabled # @!attribute is_leet_check_enabled # @return [Boolean] attr_accessor :is_leet_check_enabled # @!attribute is_plural_check_enabled # @return [Boolean] attr_accessor :is_plural_check_enabled + # @!attribute is_substring_matching_enabled + # @return [Boolean] + attr_accessor :is_substring_matching_enabled # @!attribute team # @return [String] attr_accessor :team @@ -25,8 +31,10 @@ class UpdateBlockListRequest < GetStream::BaseModel # Initialize with attributes def initialize(attributes = {}) super(attributes) + @is_confusable_folding_enabled = attributes[:is_confusable_folding_enabled] || attributes['is_confusable_folding_enabled'] || nil @is_leet_check_enabled = attributes[:is_leet_check_enabled] || attributes['is_leet_check_enabled'] || nil @is_plural_check_enabled = attributes[:is_plural_check_enabled] || attributes['is_plural_check_enabled'] || nil + @is_substring_matching_enabled = attributes[:is_substring_matching_enabled] || attributes['is_substring_matching_enabled'] || nil @team = attributes[:team] || attributes['team'] || nil @words = attributes[:words] || attributes['words'] || nil end @@ -34,8 +42,10 @@ def initialize(attributes = {}) # Override field mappings for JSON serialization def self.json_field_mappings { + is_confusable_folding_enabled: 'is_confusable_folding_enabled', is_leet_check_enabled: 'is_leet_check_enabled', is_plural_check_enabled: 'is_plural_check_enabled', + is_substring_matching_enabled: 'is_substring_matching_enabled', team: 'team', words: 'words' } diff --git a/lib/getstream_ruby/generated/models/update_follow_request.rb b/lib/getstream_ruby/generated/models/update_follow_request.rb index c96994c..cb80613 100644 --- a/lib/getstream_ruby/generated/models/update_follow_request.rb +++ b/lib/getstream_ruby/generated/models/update_follow_request.rb @@ -26,7 +26,7 @@ class UpdateFollowRequest < GetStream::BaseModel # @return [Boolean] Whether to create a notification activity for this follow attr_accessor :create_notification_activity # @!attribute create_users - # @return [Boolean] If true, auto-creates users referenced by the source and target FIDs when they don't already exist. Server-side only. Defaults to false. For FollowBatch/GetOrCreateFollows, use the top-level create_users field; per-item follows[i].create_users is rejected. + # @return [Boolean] If true, auto-creates users referenced by the source and target FIDs when they don't already exist. Server-side only. Defaults to false. Use directly on single follow endpoints (Follow, GetOrCreateFollow). On batch endpoints (FollowBatch, GetOrCreateFollows), use the top-level create_users field; per-item follows[i].create_users is rejected. attr_accessor :create_users # @!attribute enrich_own_fields # @return [Boolean] If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_followings, own_capabilities, own_membership). Defaults to false for performance. diff --git a/lib/getstream_ruby/generated/models/update_segment_request.rb b/lib/getstream_ruby/generated/models/update_segment_request.rb new file mode 100644 index 0000000..d2c17b7 --- /dev/null +++ b/lib/getstream_ruby/generated/models/update_segment_request.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class UpdateSegmentRequest < GetStream::BaseModel + + # Model attributes + # @!attribute description + # @return [String] The description of the segment (max 256 characters) + attr_accessor :description + # @!attribute name + # @return [String] The name of the segment (max 128 characters) + attr_accessor :name + # @!attribute filter + # @return [Object] Filter to apply to the query + attr_accessor :filter + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @description = attributes[:description] || attributes['description'] || nil + @name = attributes[:name] || attributes['name'] || nil + @filter = attributes[:filter] || attributes['filter'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + description: 'description', + name: 'name', + filter: 'filter' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/update_segment_response.rb b/lib/getstream_ruby/generated/models/update_segment_response.rb new file mode 100644 index 0000000..1b7dc81 --- /dev/null +++ b/lib/getstream_ruby/generated/models/update_segment_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class UpdateSegmentResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] Duration of the request in milliseconds + attr_accessor :duration + # @!attribute segment + # @return [SegmentResponse] + attr_accessor :segment + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @segment = attributes[:segment] || attributes['segment'] + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + segment: 'segment' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/upsert_config_request.rb b/lib/getstream_ruby/generated/models/upsert_config_request.rb index 5bd5409..3e54f24 100644 --- a/lib/getstream_ruby/generated/models/upsert_config_request.rb +++ b/lib/getstream_ruby/generated/models/upsert_config_request.rb @@ -48,6 +48,9 @@ class UpsertConfigRequest < GetStream::BaseModel # @!attribute bodyguard_config # @return [AITextConfig] attr_accessor :bodyguard_config + # @!attribute flood_config + # @return [FloodConfig] + attr_accessor :flood_config # @!attribute google_vision_config # @return [GoogleVisionConfig] attr_accessor :google_vision_config @@ -83,6 +86,7 @@ def initialize(attributes = {}) @aws_rekognition_config = attributes[:aws_rekognition_config] || attributes['aws_rekognition_config'] || nil @block_list_config = attributes[:block_list_config] || attributes['block_list_config'] || nil @bodyguard_config = attributes[:bodyguard_config] || attributes['bodyguard_config'] || nil + @flood_config = attributes[:flood_config] || attributes['flood_config'] || nil @google_vision_config = attributes[:google_vision_config] || attributes['google_vision_config'] || nil @llm_config = attributes[:llm_config] || attributes['llm_config'] || nil @rule_builder_config = attributes[:rule_builder_config] || attributes['rule_builder_config'] || nil @@ -107,6 +111,7 @@ def self.json_field_mappings aws_rekognition_config: 'aws_rekognition_config', block_list_config: 'block_list_config', bodyguard_config: 'bodyguard_config', + flood_config: 'flood_config', google_vision_config: 'google_vision_config', llm_config: 'llm_config', rule_builder_config: 'rule_builder_config', diff --git a/lib/getstream_ruby/generated/models/upsert_setup_session_request.rb b/lib/getstream_ruby/generated/models/upsert_setup_session_request.rb new file mode 100644 index 0000000..cdd4597 --- /dev/null +++ b/lib/getstream_ruby/generated/models/upsert_setup_session_request.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class UpsertSetupSessionRequest < GetStream::BaseModel + + # Model attributes + # @!attribute current_step + # @return [String] The current step of the setup wizard. One of: welcome, input, configure, live + attr_accessor :current_step + # @!attribute status + # @return [String] The status of the setup session. One of: in_progress, completed + attr_accessor :status + # @!attribute setup_data + # @return [Object] Per-step data keyed by step name (welcome, input, configure, live) + attr_accessor :setup_data + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @current_step = attributes[:current_step] || attributes['current_step'] + @status = attributes[:status] || attributes['status'] + @setup_data = attributes[:setup_data] || attributes['setup_data'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + current_step: 'current_step', + status: 'status', + setup_data: 'setup_data' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/upsert_setup_session_response.rb b/lib/getstream_ruby/generated/models/upsert_setup_session_response.rb new file mode 100644 index 0000000..fb36808 --- /dev/null +++ b/lib/getstream_ruby/generated/models/upsert_setup_session_response.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +# Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT. + +module GetStream + module Generated + module Models + # + class UpsertSetupSessionResponse < GetStream::BaseModel + + # Model attributes + # @!attribute duration + # @return [String] + attr_accessor :duration + # @!attribute setup_session + # @return [SetupSession] + attr_accessor :setup_session + + # Initialize with attributes + def initialize(attributes = {}) + super(attributes) + @duration = attributes[:duration] || attributes['duration'] + @setup_session = attributes[:setup_session] || attributes['setup_session'] || nil + end + + # Override field mappings for JSON serialization + def self.json_field_mappings + { + duration: 'duration', + setup_session: 'setup_session' + } + end + end + end + end +end diff --git a/lib/getstream_ruby/generated/models/user_banned_event.rb b/lib/getstream_ruby/generated/models/user_banned_event.rb index 96d9338..ed10d07 100644 --- a/lib/getstream_ruby/generated/models/user_banned_event.rb +++ b/lib/getstream_ruby/generated/models/user_banned_event.rb @@ -45,6 +45,9 @@ class UserBannedEvent < GetStream::BaseModel # @!attribute received_at # @return [DateTime] attr_accessor :received_at + # @!attribute review_queue_item_id + # @return [String] ID of the review queue item (flagged message) that triggered the ban, if the ban was applied from the moderation review queue + attr_accessor :review_queue_item_id # @!attribute shadow # @return [Boolean] Whether the user was shadow banned attr_accessor :shadow @@ -76,6 +79,7 @@ def initialize(attributes = {}) @expiration = attributes[:expiration] || attributes['expiration'] || nil @reason = attributes[:reason] || attributes['reason'] || nil @received_at = attributes[:received_at] || attributes['received_at'] || nil + @review_queue_item_id = attributes[:review_queue_item_id] || attributes['review_queue_item_id'] || nil @shadow = attributes[:shadow] || attributes['shadow'] || nil @team = attributes[:team] || attributes['team'] || nil @total_bans = attributes[:total_bans] || attributes['total_bans'] || nil @@ -98,6 +102,7 @@ def self.json_field_mappings expiration: 'expiration', reason: 'reason', received_at: 'received_at', + review_queue_item_id: 'review_queue_item_id', shadow: 'shadow', team: 'team', total_bans: 'total_bans', diff --git a/lib/getstream_ruby/generated/moderation_client.rb b/lib/getstream_ruby/generated/moderation_client.rb index d202486..4f794c9 100644 --- a/lib/getstream_ruby/generated/moderation_client.rb +++ b/lib/getstream_ruby/generated/moderation_client.rb @@ -127,6 +127,23 @@ def insert_action_log(insert_action_log_request) ) end + # Moderate named text fields and raw image bytes via multipart/form-data. Returns a per-field lightweight verdict. + # + # @param analyze_request [AnalyzeRequest] + # @return [Models::AnalyzeResponse] + def analyze(analyze_request) + path = '/api/v2/moderation/analyze' + # Build request body + body = analyze_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Appeal against the moderation decision # # @param appeal_request [AppealRequest] @@ -177,10 +194,27 @@ def query_appeals(query_appeals_request) ) end + # Process multiple appeals in a single request by applying the specified action to each. Supported actions: unban, restore, unblock, mark_reviewed, reject_appeal. Each appeal goes through the same path as a single submit_action call. + # + # @param bulk_action_appeals_request [BulkActionAppealsRequest] + # @return [Models::BulkActionAppealsResponse] + def bulk_action_appeals(bulk_action_appeals_request) + path = '/api/v2/moderation/appeals/bulk_action' + # Build request body + body = bulk_action_appeals_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Ban a user from a channel or the entire app # # @param ban_request [BanRequest] - # @return [Models::BanResponse] + # @return [Models::ModerationBanResponse] def ban(ban_request) path = '/api/v2/moderation/ban' # Build request body @@ -403,7 +437,7 @@ def v2_upsert_template(upsert_moderation_template_request) # Flag any type of content (messages, users, channels, activities) for moderation review. Supports custom content types and additional metadata for flagged content. # # @param flag_request [FlagRequest] - # @return [Models::FlagResponse] + # @return [Models::FlagItemResponse] def flag(flag_request) path = '/api/v2/moderation/flag' # Build request body @@ -617,6 +651,36 @@ def get_review_queue_item(_id) ) end + # Retrieve a setup session for an app + # + # @return [Models::GetSetupSessionResponse] + def get_setup_session() + path = '/api/v2/moderation/setup' + + # Make the API request + @client.make_request( + :get, + path + ) + end + + # Update a setup session for an app + # + # @param upsert_setup_session_request [UpsertSetupSessionRequest] + # @return [Models::UpsertSetupSessionResponse] + def upsert_setup_session(upsert_setup_session_request) + path = '/api/v2/moderation/setup' + # Build request body + body = upsert_setup_session_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # Take action on flagged content, such as marking content as safe, deleting content, banning users, or executing custom moderation actions. Supports various action types with configurable parameters. # # @param submit_action_request [SubmitActionRequest] diff --git a/lib/getstream_ruby/generated/video_client.rb b/lib/getstream_ruby/generated/video_client.rb index a1ac08a..8422cd6 100644 --- a/lib/getstream_ruby/generated/video_client.rb +++ b/lib/getstream_ruby/generated/video_client.rb @@ -970,6 +970,23 @@ def delete_transcription(_type, _id, session, filename) ) end + # Reports a batch of client-side telemetry events. Events are processed independently; one invalid event does not block the rest of the batch, but the request fails if any event is invalid. + # + # @param report_client_event_request [ReportClientEventRequest] + # @return [Models::ReportClientEventResponse] + def report_client_call_event(report_client_event_request) + path = '/api/v2/video/call_client_event' + # Build request body + body = report_client_event_request + + # Make the API request + @client.make_request( + :post, + path, + body: body + ) + end + # # # @param query_call_session_stats_request [QueryCallSessionStatsRequest] diff --git a/lib/getstream_ruby/generated/webhook.rb b/lib/getstream_ruby/generated/webhook.rb index 42b8cff..cf9d74c 100644 --- a/lib/getstream_ruby/generated/webhook.rb +++ b/lib/getstream_ruby/generated/webhook.rb @@ -133,8 +133,10 @@ require_relative 'models/moderation_check_completed_event' require_relative 'models/moderation_custom_action_event' require_relative 'models/moderation_flagged_event' +require_relative 'models/moderation_image_analysis_complete_event' require_relative 'models/moderation_mark_reviewed_event' require_relative 'models/moderation_rules_triggered_event' +require_relative 'models/moderation_text_analysis_complete_event' require_relative 'models/notification_feed_updated_event' require_relative 'models/notification_mark_unread_event' require_relative 'models/notification_thread_message_new_event' @@ -350,7 +352,9 @@ def initialize(type:, created_at: nil, raw: {}) EVENT_TYPE_MESSAGE_UPDATED = 'message.updated' EVENT_TYPE_MODERATION_CUSTOM_ACTION = 'moderation.custom_action' EVENT_TYPE_MODERATION_FLAGGED = 'moderation.flagged' + EVENT_TYPE_MODERATION_IMAGE_ANALYSIS_COMPLETE = 'moderation.image_analysis.complete' EVENT_TYPE_MODERATION_MARK_REVIEWED = 'moderation.mark_reviewed' + EVENT_TYPE_MODERATION_TEXT_ANALYSIS_COMPLETE = 'moderation.text_analysis.complete' EVENT_TYPE_MODERATION_CHECK_COMPLETED = 'moderation_check.completed' EVENT_TYPE_MODERATION_RULE_TRIGGERED = 'moderation_rule.triggered' EVENT_TYPE_NOTIFICATION_MARK_UNREAD = 'notification.mark_unread' @@ -701,8 +705,12 @@ def self.parse_webhook_event(raw_event) GetStream::Generated::Models::ModerationCustomActionEvent when 'moderation.flagged' GetStream::Generated::Models::ModerationFlaggedEvent + when 'moderation.image_analysis.complete' + GetStream::Generated::Models::ModerationImageAnalysisCompleteEvent when 'moderation.mark_reviewed' GetStream::Generated::Models::ModerationMarkReviewedEvent + when 'moderation.text_analysis.complete' + GetStream::Generated::Models::ModerationTextAnalysisCompleteEvent when 'moderation_check.completed' GetStream::Generated::Models::ModerationCheckCompletedEvent when 'moderation_rule.triggered' diff --git a/spec/webhook_spec.rb b/spec/webhook_spec.rb index 3719b4f..08c0ada 100644 --- a/spec/webhook_spec.rb +++ b/spec/webhook_spec.rb @@ -1045,6 +1045,13 @@ def compute_signature(body, secret) end + it 'parses moderation.image_analysis.complete' do + + event = StreamChat::Webhook.parse_webhook_event('{"type":"moderation.image_analysis.complete"}') + expect(event.class.name).to eq('GetStream::Generated::Models::ModerationImageAnalysisCompleteEvent') + + end + it 'parses moderation.mark_reviewed' do event = StreamChat::Webhook.parse_webhook_event('{"type":"moderation.mark_reviewed"}') @@ -1052,6 +1059,13 @@ def compute_signature(body, secret) end + it 'parses moderation.text_analysis.complete' do + + event = StreamChat::Webhook.parse_webhook_event('{"type":"moderation.text_analysis.complete"}') + expect(event.class.name).to eq('GetStream::Generated::Models::ModerationTextAnalysisCompleteEvent') + + end + it 'parses moderation_check.completed' do event = StreamChat::Webhook.parse_webhook_event('{"type":"moderation_check.completed"}') @@ -1283,7 +1297,7 @@ def compute_signature(body, secret) end # --------------------------------------------------------------------------- - # Helpers + composites: parse_event, gunzip_payload, decode_sqs_payload, + # Spec §6 helpers + composites: parse_event, gunzip_payload, decode_sqs_payload, # decode_sns_payload, verify_and_parse_webhook, parse_sqs, parse_sns. # ---------------------------------------------------------------------------