From 3d76ff294deb05a019c3f559acc9bd20fdc5405e Mon Sep 17 00:00:00 2001 From: GH Action CI Stream Date: Fri, 20 Oct 2023 11:34:15 +0000 Subject: [PATCH] Update video openapi Spec --- openapi/chat-openapi.yaml | 5759 ++++++++++++++----------------------- 1 file changed, 2186 insertions(+), 3573 deletions(-) diff --git a/openapi/chat-openapi.yaml b/openapi/chat-openapi.yaml index c880ae0a..623a7d74 100644 --- a/openapi/chat-openapi.yaml +++ b/openapi/chat-openapi.yaml @@ -197,7 +197,7 @@ components: type: string x-stream-index: "001.002" type: - default: custom + default: any type: string x-stream-index: "001.001" required: @@ -258,6 +258,11 @@ components: file_upload_config: $ref: '#/components/schemas/FileUploadConfig' x-stream-index: "001.025" + geofences: + items: + $ref: '#/components/schemas/GeofenceResponse' + type: array + x-stream-index: "001.037" grants: additionalProperties: items: @@ -565,6 +570,12 @@ components: access_request_enabled: type: boolean x-stream-index: "001" + default_device: + enum: + - speaker + - earpiece + type: string + x-stream-index: "006" mic_default_on: type: boolean x-stream-index: "004" @@ -583,6 +594,7 @@ components: - redundant_coding_enabled - mic_default_on - speaker_default_on + - default_device type: object AutomodDetails: properties: @@ -732,6 +744,33 @@ components: title: Block list type: object x-stream-docs-page-id: block_lists + BlockListOptions: + properties: + behavior: + enum: + - flag + - block + type: string + x-stream-index: "002" + blocklist: + type: string + x-stream-index: "001" + required: + - blocklist + - behavior + type: object + BlockListOptionsRequest: + properties: + behavior: + enum: + - flag + - block + type: string + x-stream-index: "002" + blocklist: + type: string + x-stream-index: "001" + type: object BroadcastSettings: properties: enabled: @@ -789,6 +828,9 @@ components: screensharing: $ref: '#/components/schemas/ScreensharingSettings' x-stream-index: "004" + thumbnails: + $ref: '#/components/schemas/ThumbnailsSettings' + x-stream-index: "010" transcription: $ref: '#/components/schemas/TranscriptionSettings' x-stream-index: "008" @@ -836,211 +878,6 @@ components: - CreatedAt - UpdatedAt type: object - Campaign: - properties: - attachments: - items: - $ref: '#/components/schemas/Attachment' - maximum: 10 - type: array - x-stream-index: "005.007" - channel_type: - maxLength: 64 - type: string - x-stream-index: "005.008" - completed_at: - format: date-time - type: string - x-stream-index: "006.004" - created_at: - format: date-time - type: string - x-stream-index: "007" - defaults: - additionalProperties: - type: string - maximum: 100 - type: object - x-stream-index: "005.006" - description: - maxLength: 1024 - type: string - x-stream-index: "005.002" - details: - type: string - x-stream-index: "006.011" - errored_messages: - format: int32 - type: integer - x-stream-index: "006.009" - failed_at: - format: date-time - type: string - x-stream-index: "006.005" - id: - type: string - x-stream-index: "003" - name: - maxLength: 256 - type: string - x-stream-index: "005.001" - resumed_at: - format: date-time - type: string - x-stream-index: "006.007" - scheduled_at: - format: date-time - type: string - x-stream-index: "006.003" - scheduled_for: - format: date-time - type: string - x-stream-index: "006.002" - segment_id: - type: string - x-stream-index: "005.004" - sender_id: - type: string - x-stream-index: "005.005" - sent_messages: - format: int32 - type: integer - x-stream-index: "006.008" - status: - type: string - x-stream-index: "006.001" - stopped_at: - format: date-time - type: string - x-stream-index: "006.006" - task_id: - type: string - x-stream-index: "006.010" - text: - type: string - x-stream-index: "005.003" - updated_at: - format: date-time - type: string - x-stream-index: "008" - required: - - id - - name - - description - - text - - segment_id - - sender_id - - defaults - - attachments - - channel_type - - created_at - - updated_at - type: object - CampaignDataRequest: - properties: - attachments: - items: - $ref: '#/components/schemas/AttachmentRequest' - maximum: 10 - type: array - x-stream-index: "007" - channel_type: - maxLength: 64 - type: string - x-stream-index: "008" - defaults: - additionalProperties: - type: string - maximum: 100 - type: object - x-stream-index: "006" - description: - maxLength: 1024 - type: string - x-stream-index: "002" - name: - maxLength: 256 - type: string - x-stream-index: "001" - segment_id: - type: string - x-stream-index: "004" - sender_id: - type: string - x-stream-index: "005" - text: - type: string - x-stream-index: "003" - required: - - name - - text - - segment_id - - sender_id - type: object - CampaignSort: - properties: - direction: - enum: - - asc - - desc - type: string - x-stream-index: "001" - fields: - items: - $ref: '#/components/schemas/CampaignSortField' - maximum: 5 - type: array - x-stream-index: "002" - required: - - fields - type: object - CampaignSortField: - properties: - field: - type: string - x-stream-index: "001" - value: - x-stream-index: "002" - required: - - field - - value - type: object - CampaignUpdateableFieldsRequest: - properties: - attachments: - items: - $ref: '#/components/schemas/AttachmentRequest' - maximum: 10 - type: array - x-stream-index: "007" - channel_type: - maxLength: 64 - type: string - x-stream-index: "008" - defaults: - additionalProperties: - type: string - maximum: 100 - type: object - x-stream-index: "006" - description: - maxLength: 1024 - type: string - x-stream-index: "002" - name: - maxLength: 256 - type: string - x-stream-index: "001" - segment_id: - type: string - x-stream-index: "004" - sender_id: - type: string - x-stream-index: "005" - text: - type: string - x-stream-index: "003" - type: object Channel: additionalProperties: true properties: @@ -1132,25 +969,30 @@ components: - simple - AI type: string - x-stream-index: "001.017" + x-stream-index: "001.018" automod_behavior: enum: - flag - block type: string - x-stream-index: "001.018" + x-stream-index: "001.019" automod_thresholds: $ref: '#/components/schemas/Thresholds' - x-stream-index: "001.021" + x-stream-index: "001.023" blocklist: type: string - x-stream-index: "001.019" + x-stream-index: "001.020" blocklist_behavior: enum: - flag - block type: string - x-stream-index: "001.020" + x-stream-index: "001.021" + blocklists: + items: + $ref: '#/components/schemas/BlockListOptions' + type: array + x-stream-index: "001.022" commands: description: List of commands that channel supports items: @@ -1168,14 +1010,17 @@ components: custom_events: type: boolean x-stream-index: "001.012" + mark_messages_pending: + type: boolean + x-stream-index: "001.015" max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: "001.016" + x-stream-index: "001.017" message_retention: type: string - x-stream-index: "001.015" + x-stream-index: "001.016" mutes: type: boolean x-stream-index: "001.009" @@ -1231,6 +1076,7 @@ components: - custom_events - push_notifications - reminders + - mark_messages_pending - message_retention - max_message_length - automod @@ -1314,25 +1160,30 @@ components: - simple - AI type: string - x-stream-index: 001.002.017 + x-stream-index: 001.002.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 001.002.018 + x-stream-index: 001.002.019 automod_thresholds: $ref: '#/components/schemas/Thresholds' - x-stream-index: 001.002.021 + x-stream-index: 001.002.023 blocklist: type: string - x-stream-index: 001.002.019 + x-stream-index: 001.002.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 001.002.020 + x-stream-index: 001.002.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptions' + type: array + x-stream-index: 001.002.022 commands: items: $ref: '#/components/schemas/Command' @@ -1360,14 +1211,17 @@ components: description: List of grants modifiers that apply to a role key: role title: Grants + mark_messages_pending: + type: boolean + x-stream-index: 001.002.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 001.002.016 + x-stream-index: 001.002.017 message_retention: type: string - x-stream-index: 001.002.015 + x-stream-index: 001.002.016 mutes: type: boolean x-stream-index: 001.002.009 @@ -1425,6 +1279,7 @@ components: - custom_events - push_notifications - reminders + - mark_messages_pending - message_retention - max_message_length - automod @@ -1439,25 +1294,30 @@ components: - simple - AI type: string - x-stream-index: 001.002.017 + x-stream-index: 001.002.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 001.002.018 + x-stream-index: 001.002.019 automod_thresholds: $ref: '#/components/schemas/ThresholdsRequest' - x-stream-index: 001.002.021 + x-stream-index: 001.002.023 blocklist: type: string - x-stream-index: 001.002.019 + x-stream-index: 001.002.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 001.002.020 + x-stream-index: 001.002.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptionsRequest' + type: array + x-stream-index: 001.002.022 commands: items: $ref: '#/components/schemas/CommandRequest' @@ -1485,14 +1345,17 @@ components: description: List of grants modifiers that apply to a role key: role title: Grants + mark_messages_pending: + type: boolean + x-stream-index: 001.002.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 001.002.016 + x-stream-index: 001.002.017 message_retention: type: string - x-stream-index: 001.002.015 + x-stream-index: 001.002.016 mutes: type: boolean x-stream-index: 001.002.009 @@ -2050,8 +1913,6 @@ components: config_overrides: $ref: '#/components/schemas/ChannelConfigRequest' x-stream-index: "026" - created_by: - $ref: '#/components/schemas/UserObjectRequest' disabled: type: boolean x-stream-index: "016" @@ -2555,28 +2416,33 @@ components: - simple - AI type: string - x-stream-index: 003.002.017 + x-stream-index: 003.002.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 003.002.018 + x-stream-index: 003.002.019 automod_thresholds: $ref: '#/components/schemas/Thresholds' - x-stream-index: 003.002.021 + x-stream-index: 003.002.023 blocklist: type: string - x-stream-index: 003.002.019 + x-stream-index: 003.002.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 003.002.020 - commands: - description: List of commands that channel supports - items: + x-stream-index: 003.002.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptions' + type: array + x-stream-index: 003.002.022 + commands: + description: List of commands that channel supports + items: $ref: '#/components/schemas/Command' title: Commands type: array @@ -2598,14 +2464,17 @@ components: type: array type: object x-stream-index: "002" + mark_messages_pending: + type: boolean + x-stream-index: 003.002.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 003.002.016 + x-stream-index: 003.002.017 message_retention: type: string - x-stream-index: 003.002.015 + x-stream-index: 003.002.016 mutes: type: boolean x-stream-index: 003.002.009 @@ -2670,6 +2539,7 @@ components: - custom_events - push_notifications - reminders + - mark_messages_pending - message_retention - max_message_length - automod @@ -2838,6 +2708,7 @@ components: channel.updated: '#/components/schemas/ChannelUpdatedEvent' channel.visible: '#/components/schemas/ChannelVisibleEvent' custom: '#/components/schemas/AnyEvent' + flag.updated: '#/components/schemas/FlagUpdatedEvent' health.check: '#/components/schemas/HealthCheckEvent' member.added: '#/components/schemas/MemberAddedEvent' member.removed: '#/components/schemas/MemberRemovedEvent' @@ -2893,6 +2764,7 @@ components: - $ref: '#/components/schemas/ChannelUnmutedEvent' - $ref: '#/components/schemas/ChannelUpdatedEvent' - $ref: '#/components/schemas/ChannelVisibleEvent' + - $ref: '#/components/schemas/FlagUpdatedEvent' - $ref: '#/components/schemas/HealthCheckEvent' - $ref: '#/components/schemas/MemberAddedEvent' - $ref: '#/components/schemas/MemberRemovedEvent' @@ -3030,6 +2902,54 @@ components: required: - duration type: object + CheckSNSRequest: + nullable: true + properties: + sns_key: + description: AWS SNS access key + title: SNS key + type: string + x-stream-index: "002" + sns_secret: + description: AWS SNS key secret + title: SNS secret + type: string + x-stream-index: "003" + sns_topic_arn: + description: AWS SNS topic ARN + title: SNS URL + type: string + x-stream-index: "001" + type: object + CheckSNSResponse: + nullable: true + properties: + data: + additionalProperties: {} + description: Error data + title: Data + type: object + x-stream-index: "003" + duration: + type: string + x-stream-index: "004.001" + error: + description: Error text + title: Error + type: string + x-stream-index: "002" + status: + description: Validation result + enum: + - ok + - error + title: Status + type: string + x-stream-index: "001" + required: + - status + - duration + type: object CheckSQSRequest: nullable: true properties: @@ -3291,29 +3211,6 @@ components: - token - duration type: object - CreateCampaignRequest: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/CampaignDataRequest' - x-stream-index: "001" - required: - - campaign - type: object - CreateCampaignResponse: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/Campaign' - x-stream-index: "001" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - required: - - duration - type: object CreateChannelTypeRequest: nullable: true properties: @@ -3325,7 +3222,7 @@ components: - AI title: Auto moderation type: string - x-stream-index: "015" + x-stream-index: "016" automod_behavior: description: Sets behavior of automatic moderation enum: @@ -3333,12 +3230,12 @@ components: - block title: Auto moderation behavior type: string - x-stream-index: "016" + x-stream-index: "017" blocklist: description: Name of the blocklist to use title: Blocklist type: string - x-stream-index: "020" + x-stream-index: "021" blocklist_behavior: description: Sets behavior of blocklist enum: @@ -3346,14 +3243,19 @@ components: - block title: Blocklist behavior type: string - x-stream-index: "021" + x-stream-index: "022" + blocklists: + additionalProperties: + $ref: '#/components/schemas/BlockListOptionsRequest' + type: object + x-stream-index: "023" commands: description: List of commands that channel supports items: type: string title: Commands type: array - x-stream-index: "017" + x-stream-index: "018" connect_events: description: Connect events support title: Connect events @@ -3370,18 +3272,23 @@ components: type: string type: array type: object - x-stream-index: "019" + x-stream-index: "020" + mark_messages_pending: + description: Marks messages as pending by default + title: Mark messages pending + type: boolean + x-stream-index: "013" max_message_length: description: Number of maximum message characters format: int32 title: Maximum message length type: integer - x-stream-index: "014" + x-stream-index: "015" message_retention: description: Number of days to keep messages. 'infinite' disables retention title: Message retention type: string - x-stream-index: "013" + x-stream-index: "014" mutes: description: Enables mutes title: Mutes @@ -3398,7 +3305,7 @@ components: $ref: '#/components/schemas/PolicyRequest' title: Permissions type: array - x-stream-index: "018" + x-stream-index: "019" push_notifications: description: Enables push notifications title: Push notifications @@ -3452,25 +3359,30 @@ components: - simple - AI type: string - x-stream-index: 001.001.017 + x-stream-index: 001.001.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 001.001.018 + x-stream-index: 001.001.019 automod_thresholds: $ref: '#/components/schemas/Thresholds' - x-stream-index: 001.001.021 + x-stream-index: 001.001.023 blocklist: type: string - x-stream-index: 001.001.019 + x-stream-index: 001.001.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 001.001.020 + x-stream-index: 001.001.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptions' + type: array + x-stream-index: 001.001.022 commands: items: type: string @@ -3496,14 +3408,17 @@ components: type: array type: object x-stream-index: "003" + mark_messages_pending: + type: boolean + x-stream-index: 001.001.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 001.001.016 + x-stream-index: 001.001.017 message_retention: type: string - x-stream-index: 001.001.015 + x-stream-index: 001.001.016 mutes: type: boolean x-stream-index: 001.001.009 @@ -3564,6 +3479,7 @@ components: - custom_events - push_notifications - reminders + - mark_messages_pending - message_retention - max_message_length - automod @@ -3734,29 +3650,6 @@ components: - duration - role type: object - CreateSegmentRequest: - nullable: true - properties: - segment: - $ref: '#/components/schemas/SegmentDataRequest' - x-stream-index: "001" - required: - - segment - type: object - CreateSegmentResponse: - nullable: true - properties: - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - segment: - $ref: '#/components/schemas/Segment' - x-stream-index: "001" - required: - - duration - type: object DeactivateUserRequest: nullable: true properties: @@ -3831,17 +3724,6 @@ components: - task_id - duration type: object - DeleteCampaignResponse: - nullable: true - properties: - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "001.001" - required: - - duration - type: object DeleteChannelResponse: nullable: true properties: @@ -3920,17 +3802,6 @@ components: - name - duration type: object - DeleteSegmentResponse: - nullable: true - properties: - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "001.001" - required: - - duration - type: object DeleteUserResponse: nullable: true properties: @@ -4796,11 +4667,6 @@ components: title: Target Message ID type: string x-stream-index: "001" - target_user_id: - description: ID of the user when reporting a user - title: Target User ID - type: string - x-stream-index: "002" user: $ref: '#/components/schemas/UserObjectRequest' x-stream-index: "003.002" @@ -4822,6 +4688,58 @@ components: required: - duration type: object + FlagUpdatedEvent: + properties: + CreatedBy: + $ref: '#/components/schemas/UserObject' + x-stream-index: "004" + created_at: + format: date-time + type: string + x-stream-index: "003.002" + message: + $ref: '#/components/schemas/Message' + x-stream-index: "001.001" + thread_participants: + items: + $ref: '#/components/schemas/UserObject' + type: array + x-stream-index: "001.002" + type: + default: flag.updated + type: string + x-stream-index: "003.001" + user: + $ref: '#/components/schemas/UserObject' + x-stream-index: "002.001" + required: + - type + - created_at + title: FlagUpdatedEvent + type: object + x-stream-event-client-type: true + x-stream-is-event: true + x-stream-ws-base-event-name: ChatEvent + GeofenceResponse: + nullable: true + properties: + country_codes: + items: + type: string + type: array + x-stream-index: "004" + description: + type: string + x-stream-index: "003" + name: + type: string + x-stream-index: "001" + type: + type: string + x-stream-index: "002" + required: + - name + type: object GeofenceSettings: properties: names: @@ -5286,6 +5204,9 @@ components: enabled: type: boolean x-stream-index: "002" + layout: + $ref: '#/components/schemas/LayoutSettings' + x-stream-index: "004" quality_tracks: items: type: string @@ -5718,6 +5639,32 @@ components: type: number x-stream-index: "001" type: object + LayoutSettings: + properties: + external_app_url: + type: string + x-stream-index: "003" + external_css_url: + type: string + x-stream-index: "004" + name: + enum: + - spotlight + - grid + - single-participant + - mobile + - custom + type: string + x-stream-index: "001" + options: + additionalProperties: {} + type: object + x-stream-index: "002" + required: + - name + - external_app_url + - external_css_url + type: object LimitInfo: properties: limit: @@ -6094,7 +6041,7 @@ components: title: Before Message Send Failed type: boolean x-stream-docs-page-id: before_message_send_webhook - x-stream-index: "042" + x-stream-index: "043" cid: description: Channel unique identifier in : format title: Channel CID @@ -6118,6 +6065,10 @@ components: title: Deleted at type: string x-stream-index: "030" + deleted_reply_count: + format: int32 + type: integer + x-stream-index: "021" html: description: Contains HTML markup of the message. Can only be set when using server-side API @@ -6132,7 +6083,7 @@ components: title: Internationalization info type: object x-stream-docs-page-id: translation - x-stream-index: "040" + x-stream-index: "041" id: description: Message ID is unique string identifier of the message title: ID @@ -6146,7 +6097,7 @@ components: description: Contains image moderation information title: Image moderation labels type: object - x-stream-index: "036" + x-stream-index: "037" latest_reactions: description: List of 10 latest reactions to this message items: @@ -6160,7 +6111,7 @@ components: $ref: '#/components/schemas/UserObject' title: Mentioned Users type: array - x-stream-index: "039" + x-stream-index: "040" mml: description: Should be empty if `text` is provided. Can only be set when using server-side API @@ -6187,26 +6138,26 @@ components: title: Pin expiration date type: string x-stream-docs-page-id: pinned_messages - x-stream-index: "047" + x-stream-index: "048" pinned: description: Whether message is pinned or not title: Pinned type: boolean x-stream-docs-page-id: pinned_messages - x-stream-index: "043" + x-stream-index: "044" pinned_at: description: Date when message got pinned format: date-time title: Pinned at type: string x-stream-docs-page-id: pinned_messages - x-stream-index: "044" + x-stream-index: "045" pinned_by: $ref: '#/components/schemas/UserObject' description: Contains user who pinned the message title: Pinned by x-stream-docs-page-id: pinned_messages - x-stream-index: "046" + x-stream-index: "047" quoted_message: $ref: '#/components/schemas/Message' description: Contains quoted message @@ -6247,7 +6198,7 @@ components: title: Shadowed type: boolean x-stream-docs-page-id: moderation#shadow-ban - x-stream-index: "032" + x-stream-index: "033" show_in_channel: description: Whether thread reply should be shown in the channel as well title: Show in channel @@ -6258,7 +6209,7 @@ components: description: Whether message is silent or not title: Silent type: boolean - x-stream-index: "041" + x-stream-index: "042" text: description: Text of the message. Should be empty if `mml` is provided title: Text @@ -6296,10 +6247,6 @@ components: description: Sender of the message. Required when using server-side API title: User object x-stream-index: "010" - visible_reply_count: - format: int32 - type: integer - x-stream-index: "021" required: - id - text @@ -6311,7 +6258,7 @@ components: - reaction_counts - reaction_scores - reply_count - - visible_reply_count + - deleted_reply_count - cid - created_at - updated_at @@ -6820,7 +6767,7 @@ components: title: Before Message Send Failed type: boolean x-stream-docs-page-id: before_message_send_webhook - x-stream-index: "042" + x-stream-index: "043" cid: description: Channel unique identifier in : format title: Channel CID @@ -6844,6 +6791,10 @@ components: title: Deleted at type: string x-stream-index: "030" + deleted_reply_count: + format: int32 + type: integer + x-stream-index: "021" html: description: Contains HTML markup of the message. Can only be set when using server-side API @@ -6858,7 +6809,7 @@ components: title: Internationalization info type: object x-stream-docs-page-id: translation - x-stream-index: "040" + x-stream-index: "041" id: description: Message ID is unique string identifier of the message title: ID @@ -6872,7 +6823,7 @@ components: description: Contains image moderation information title: Image moderation labels type: object - x-stream-index: "036" + x-stream-index: "037" latest_reactions: description: List of 10 latest reactions to this message items: @@ -6886,7 +6837,7 @@ components: $ref: '#/components/schemas/UserObjectRequest' title: Mentioned Users type: array - x-stream-index: "039" + x-stream-index: "040" mml: description: Should be empty if `text` is provided. Can only be set when using server-side API @@ -6913,26 +6864,26 @@ components: title: Pin expiration date type: string x-stream-docs-page-id: pinned_messages - x-stream-index: "047" + x-stream-index: "048" pinned: description: Whether message is pinned or not title: Pinned type: boolean x-stream-docs-page-id: pinned_messages - x-stream-index: "043" + x-stream-index: "044" pinned_at: description: Date when message got pinned format: date-time title: Pinned at type: string x-stream-docs-page-id: pinned_messages - x-stream-index: "044" + x-stream-index: "045" pinned_by: $ref: '#/components/schemas/UserObjectRequest' description: Contains user who pinned the message title: Pinned by x-stream-docs-page-id: pinned_messages - x-stream-index: "046" + x-stream-index: "047" quoted_message: $ref: '#/components/schemas/MessageRequest_1' description: Contains quoted message @@ -6973,7 +6924,7 @@ components: title: Shadowed type: boolean x-stream-docs-page-id: moderation#shadow-ban - x-stream-index: "032" + x-stream-index: "033" show_in_channel: description: Whether thread reply should be shown in the channel as well title: Show in channel @@ -6984,7 +6935,7 @@ components: description: Whether message is silent or not title: Silent type: boolean - x-stream-index: "041" + x-stream-index: "042" text: description: Text of the message. Should be empty if `mml` is provided title: Text @@ -7022,10 +6973,6 @@ components: description: Sender of the message. Required when using server-side API title: User object x-stream-index: "010" - visible_reply_count: - format: int32 - type: integer - x-stream-index: "021" required: - text - mml @@ -7212,7 +7159,6 @@ components: type: string x-stream-index: "004.001" required: - - channel_cid - channel_cids type: object MuteChannelResponse: @@ -7265,7 +7211,6 @@ components: type: string x-stream-index: "004.001" required: - - target_id - target_ids type: object MuteUserResponse: @@ -8597,6 +8542,9 @@ components: format: date-time type: string x-stream-index: "003.007" + exclude_expired_bans: + type: boolean + x-stream-index: "006" filter_conditions: additionalProperties: {} type: object @@ -8621,12 +8569,12 @@ components: $ref: '#/components/schemas/UserObject' description: '**Server-side only**. User object which server acts upon' title: User - x-stream-index: "006.002" + x-stream-index: "007.002" user_id: description: '**Server-side only**. User ID which server acts upon' title: User ID type: string - x-stream-index: "006.001" + x-stream-index: "007.001" required: - filter_conditions type: object @@ -8647,59 +8595,6 @@ components: - bans - duration type: object - QueryCampaignsRequest: - properties: - filter_conditions: - additionalProperties: {} - type: object - x-stream-index: "001" - limit: - format: int32 - maximum: 20 - minimum: 1 - type: integer - x-stream-index: "002.002" - sort: - $ref: '#/components/schemas/CampaignSort' - x-stream-index: "002.001" - required: - - filter_conditions - type: object - QueryCampaignsResponse: - nullable: true - properties: - campaigns: - items: - $ref: '#/components/schemas/Campaign' - type: array - x-stream-index: "001" - channels: - additionalProperties: - $ref: '#/components/schemas/Channel' - type: object - x-stream-index: "004" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "005.001" - segments: - additionalProperties: - $ref: '#/components/schemas/Segment' - type: object - x-stream-index: "002" - users: - additionalProperties: - $ref: '#/components/schemas/UserObject' - type: object - x-stream-index: "003" - required: - - campaigns - - segments - - users - - channels - - duration - type: object QueryChannelsRequest: nullable: true properties: @@ -8768,8 +8663,6 @@ components: title: Watch type: boolean x-stream-index: "003" - required: - - sort title: Query Channels Request type: object x-stream-docs-page-id: query_channels @@ -8799,7 +8692,6 @@ components: x-stream-index: "004" id: description: Channel ID to interact with - maxLength: 64 title: Channel ID type: string x-stream-index: "002" @@ -8873,22 +8765,25 @@ components: maximum: 300 minimum: 0 type: integer - x-stream-index: "002.003" + x-stream-index: "003.003" offset: format: int32 maximum: 10000 type: integer - x-stream-index: "002.004" + x-stream-index: "003.004" + show_deleted_messages: + type: boolean + x-stream-index: "002" user: $ref: '#/components/schemas/UserObject' description: '**Server-side only**. User object which server acts upon' title: User - x-stream-index: "003.002" + x-stream-index: "004.002" user_id: description: '**Server-side only**. User ID which server acts upon' title: User ID type: string - x-stream-index: "003.001" + x-stream-index: "004.001" type: object QueryMessageFlagsResponse: nullable: true @@ -8907,100 +8802,6 @@ components: - flags - duration type: object - QueryRecipientsRequest: - properties: - filter_conditions: - additionalProperties: {} - type: object - x-stream-index: "001" - limit: - format: int32 - maximum: 20 - minimum: 1 - type: integer - x-stream-index: "002.002" - sort: - $ref: '#/components/schemas/CampaignSort' - x-stream-index: "002.001" - required: - - filter_conditions - type: object - QueryRecipientsResponse: - nullable: true - properties: - campaigns: - additionalProperties: - $ref: '#/components/schemas/Campaign' - type: object - x-stream-index: "001" - channels: - additionalProperties: - $ref: '#/components/schemas/Channel' - type: object - x-stream-index: "004" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "006.001" - recipients: - items: - $ref: '#/components/schemas/Recipient' - type: array - x-stream-index: "005" - segments: - additionalProperties: - $ref: '#/components/schemas/Segment' - type: object - x-stream-index: "002" - users: - additionalProperties: - $ref: '#/components/schemas/UserObject' - type: object - x-stream-index: "003" - required: - - campaigns - - segments - - users - - channels - - recipients - - duration - type: object - QuerySegmentsRequest: - properties: - filter_conditions: - additionalProperties: {} - type: object - x-stream-index: "001" - limit: - format: int32 - maximum: 20 - minimum: 1 - type: integer - x-stream-index: "002.002" - sort: - $ref: '#/components/schemas/CampaignSort' - x-stream-index: "002.001" - required: - - filter_conditions - type: object - QuerySegmentsResponse: - nullable: true - properties: - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - segments: - items: - $ref: '#/components/schemas/Segment' - type: array - x-stream-index: "001" - required: - - segments - - duration - type: object QueryUsersRequest: properties: client_id: @@ -9060,7 +8861,6 @@ components: x-stream-index: "005.001" required: - filter_conditions - - sort type: object Reaction: additionalProperties: true @@ -9425,65 +9225,18 @@ components: - last_read - unread_messages type: object - Recipient: - nullable: true - properties: - campaign_id: - type: string - x-stream-index: "004" - channel_cid: - type: string - x-stream-index: "005" - created_at: - format: date-time - type: string - x-stream-index: "010" - details: - type: string - x-stream-index: "009" - message_id: - type: string - x-stream-index: "007" - receiver_id: - type: string - x-stream-index: "006" - status: - type: string - x-stream-index: "008" - updated_at: - format: date-time - type: string - x-stream-index: "011" - required: - - campaign_id - - channel_cid - - receiver_id - - message_id - - status - - details - - created_at - - updated_at - type: object RecordSettings: properties: audio_only: type: boolean x-stream-index: "001" + layout: + $ref: '#/components/schemas/LayoutSettings' + x-stream-index: "004" mode: - enum: - - available - - disabled - - auto-on type: string x-stream-index: "002" quality: - enum: - - audio-only - - 360p - - 480p - - 720p - - 1080p - - 1440p type: string x-stream-index: "003" required: @@ -9515,22 +9268,6 @@ components: required: - user_ids type: object - ResumeCampaignRequest: - type: object - ResumeCampaignResponse: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/Campaign' - x-stream-index: "001" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - required: - - duration - type: object RingSettings: properties: auto_cancel_timeout_ms: @@ -9584,29 +9321,6 @@ components: - created_at - updated_at type: object - ScheduleCampaignRequest: - nullable: true - properties: - scheduled_for: - format: int64 - minimum: 0 - type: integer - x-stream-index: "001" - type: object - ScheduleCampaignResponse: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/Campaign' - x-stream-index: "001" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - required: - - duration - type: object ScreensharingSettings: properties: access_request_enabled: @@ -9720,7 +9434,7 @@ components: x-stream-index: "001.011" before_message_send_failed: type: boolean - x-stream-index: "001.042" + x-stream-index: "001.043" channel: $ref: '#/components/schemas/ChannelResponse' description: Channel object @@ -9740,6 +9454,10 @@ components: format: date-time type: string x-stream-index: "001.030" + deleted_reply_count: + format: int32 + type: integer + x-stream-index: "001.021" html: type: string x-stream-index: "001.007" @@ -9747,7 +9465,7 @@ components: additionalProperties: type: string type: object - x-stream-index: "001.040" + x-stream-index: "001.041" id: type: string x-stream-index: "001.002" @@ -9757,7 +9475,7 @@ components: type: string type: array type: object - x-stream-index: "001.036" + x-stream-index: "001.037" latest_reactions: items: $ref: '#/components/schemas/Reaction' @@ -9767,7 +9485,7 @@ components: items: $ref: '#/components/schemas/UserObject' type: array - x-stream-index: "001.039" + x-stream-index: "001.040" mml: type: string x-stream-index: "001.005" @@ -9782,17 +9500,17 @@ components: pin_expires: format: date-time type: string - x-stream-index: "001.047" + x-stream-index: "001.048" pinned: type: boolean - x-stream-index: "001.043" + x-stream-index: "001.044" pinned_at: format: date-time type: string - x-stream-index: "001.044" + x-stream-index: "001.045" pinned_by: $ref: '#/components/schemas/UserObject' - x-stream-index: "001.046" + x-stream-index: "001.047" quoted_message: $ref: '#/components/schemas/Message' x-stream-index: "001.023" @@ -9817,13 +9535,13 @@ components: x-stream-index: "001.020" shadowed: type: boolean - x-stream-index: "001.032" + x-stream-index: "001.033" show_in_channel: type: boolean x-stream-index: "001.019" silent: type: boolean - x-stream-index: "001.041" + x-stream-index: "001.042" text: type: string x-stream-index: "001.004" @@ -9842,10 +9560,6 @@ components: user: $ref: '#/components/schemas/UserObject' x-stream-index: "001.010" - visible_reply_count: - format: int32 - type: integer - x-stream-index: "001.021" required: - id - text @@ -9857,7 +9571,7 @@ components: - reaction_counts - reaction_scores - reply_count - - visible_reply_count + - deleted_reply_count - cid - created_at - updated_at @@ -9896,137 +9610,41 @@ components: - warning_description - warning_code type: object - Segment: + SendEventRequest: + nullable: true + properties: + event: + $ref: '#/components/schemas/EventRequest' + x-stream-index: "001" + required: + - event + type: object + SendMessageRequest: + description: Contains all information needed to send new message + nullable: true properties: - created_at: - format: date-time - type: string - x-stream-index: "005" - description: - maxLength: 256 - type: string - x-stream-index: "010.002" - filter: - additionalProperties: {} - type: object - x-stream-index: 010.003.002 - id: - type: string - x-stream-index: "003" - in_use: + force_moderation: + description: Enable moderation on server-side requests + title: Force moderation type: boolean - x-stream-index: "009" - name: - maxLength: 128 - type: string - x-stream-index: "010.001" - size: - format: int32 - type: integer - x-stream-index: "008" - status: - type: string - x-stream-index: "007" - type: - enum: - - user - - channel - type: string - x-stream-index: 010.003.001 - updated_at: - format: date-time - type: string x-stream-index: "006" - required: - - id - - created_at - - updated_at - - status - - size - - in_use - - name - - description - - type - - filter - type: object - SegmentDataRequest: - properties: - description: - maxLength: 256 - type: string - x-stream-index: "002" - filter: - additionalProperties: {} - type: object - x-stream-index: "003.002" - name: - maxLength: 128 - type: string - x-stream-index: "001" - type: - enum: - - user - - channel - type: string - x-stream-index: "003.001" - required: - - name - - type - - filter - type: object - SegmentUpdateableFieldsRequest: - properties: - description: - maxLength: 256 - type: string - x-stream-index: "002" - filter: - additionalProperties: {} - type: object - x-stream-index: "004" - name: - maxLength: 128 - type: string - x-stream-index: "001" - type: - enum: - - user - - channel - type: string - x-stream-index: "003" - type: object - SendEventRequest: - nullable: true - properties: - event: - $ref: '#/components/schemas/EventRequest' - x-stream-index: "001" - required: - - event - type: object - SendMessageRequest: - description: Contains all information needed to send new message - nullable: true - properties: - force_moderation: - description: Enable moderation on server-side requests - title: Force moderation - type: boolean - x-stream-index: "005" is_pending_message: - description: Make the message a pending message. This message will not be - viewable to others until it is committed. - title: Is pending message type: boolean x-stream-index: "004" keep_channel_hidden: description: Keeps the channel hidden for the sender title: Keep channel hidden type: boolean - x-stream-index: "006" + x-stream-index: "007" message: $ref: '#/components/schemas/MessageRequest' x-stream-index: "001.001" + pending: + description: Make the message a pending message. This message will not be + viewable to others until it is committed. + title: Pending + type: boolean + x-stream-index: "005" pending_message_metadata: additionalProperties: type: string @@ -10103,10 +9721,14 @@ components: nullable: true properties: direction: + description: Direction of sorting, -1 for descending, 1 for ascending format: int32 + title: Direction type: integer x-stream-index: "002" field: + description: Name of field to sort by + title: Field type: string x-stream-index: "001" type: object @@ -10114,30 +9736,17 @@ components: nullable: true properties: direction: + description: Direction of sorting, -1 for descending, 1 for ascending format: int32 + title: Direction type: integer x-stream-index: "002" field: + description: Name of field to sort by + title: Field type: string x-stream-index: "001" type: object - StopCampaignRequest: - nullable: true - type: object - StopCampaignResponse: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/Campaign' - x-stream-index: "001" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - required: - - duration - type: object StopWatchingResponse: nullable: true properties: @@ -10243,43 +9852,6 @@ components: - height - bitrate type: object - TestCampaignRequest: - nullable: true - properties: - users: - items: - type: string - maximum: 10 - minimum: 1 - type: array - x-stream-index: "002" - required: - - users - type: object - TestCampaignResponse: - nullable: true - properties: - details: - type: string - x-stream-index: "002" - duration: - type: string - x-stream-index: "004.001" - results: - additionalProperties: - type: string - description: Result of the test per user - title: Results - type: object - x-stream-index: "003" - status: - type: string - x-stream-index: "001" - required: - - status - - duration - title: Test campaign response - type: object Thresholds: description: Sets thresholds for AI moderation properties: @@ -10320,6 +9892,14 @@ components: x-stream-index: "003" title: Auto moderation thresholds type: object + ThumbnailsSettings: + properties: + enabled: + type: boolean + x-stream-index: "001" + required: + - enabled + type: object TranscriptionSettings: properties: closed_caption_mode: @@ -10399,7 +9979,7 @@ components: - vi title: Language type: string - x-stream-index: "001" + x-stream-index: "002" required: - language type: object @@ -10589,13 +10169,13 @@ components: properties: agora_options: $ref: '#/components/schemas/ConfigRequest' - x-stream-index: "001.033" + x-stream-index: "001.036" apn_config: $ref: '#/components/schemas/APNConfigRequest' x-stream-index: "001.003" async_moderation_config: $ref: '#/components/schemas/AsyncModerationConfigurationRequest' - x-stream-index: "001.035" + x-stream-index: "001.038" async_url_enrich_enabled: type: boolean x-stream-index: "001.016" @@ -10610,10 +10190,10 @@ components: maximum: 1209600 minimum: 14400 type: integer - x-stream-index: "001.031" + x-stream-index: "001.034" channel_hide_members_only: type: boolean - x-stream-index: "001.027" + x-stream-index: "001.030" custom_action_handler_url: type: string x-stream-index: "001.018" @@ -10632,7 +10212,7 @@ components: x-stream-index: "001.019" file_upload_config: $ref: '#/components/schemas/FileUploadConfigRequest' - x-stream-index: "001.024" + x-stream-index: "001.027" firebase_config: $ref: '#/components/schemas/FirebaseConfigRequest' x-stream-index: "001.004" @@ -10642,10 +10222,10 @@ components: type: string type: array type: object - x-stream-index: "001.028" + x-stream-index: "001.031" hms_options: $ref: '#/components/schemas/ConfigRequest' - x-stream-index: "001.034" + x-stream-index: "001.037" huawei_config: $ref: '#/components/schemas/HuaweiConfigRequest' x-stream-index: "001.005" @@ -10664,10 +10244,10 @@ components: x-stream-index: "001.012" image_upload_config: $ref: '#/components/schemas/FileUploadConfigRequest' - x-stream-index: "001.023" + x-stream-index: "001.026" migrate_permissions_to_v2: type: boolean - x-stream-index: "001.029" + x-stream-index: "001.032" multi_tenant_enabled: type: boolean x-stream-index: "001.011" @@ -10685,11 +10265,20 @@ components: maximum: 86400 minimum: 60 type: integer - x-stream-index: "001.030" + x-stream-index: "001.033" revoke_tokens_issued_before: format: date-time + type: string + x-stream-index: "001.028" + sns_key: + type: string + x-stream-index: "001.024" + sns_secret: type: string x-stream-index: "001.025" + sns_topic_arn: + type: string + x-stream-index: "001.023" sqs_key: type: string x-stream-index: "001.021" @@ -10709,12 +10298,12 @@ components: - agora - hms type: string - x-stream-index: "001.032" + x-stream-index: "001.035" webhook_events: items: type: string type: array - x-stream-index: "001.026" + x-stream-index: "001.029" webhook_url: type: string x-stream-index: "001.008" @@ -10735,29 +10324,6 @@ components: type: array x-stream-index: "002" type: object - UpdateCampaignRequest: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/CampaignUpdateableFieldsRequest' - x-stream-index: "001" - required: - - campaign - type: object - UpdateCampaignResponse: - nullable: true - properties: - campaign: - $ref: '#/components/schemas/Campaign' - x-stream-index: "001" - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - required: - - duration - type: object UpdateChannelPartialRequest: nullable: true properties: @@ -10937,25 +10503,30 @@ components: - simple - AI type: string - x-stream-index: 007.001.017 + x-stream-index: 007.001.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 007.001.018 + x-stream-index: 007.001.019 automod_thresholds: $ref: '#/components/schemas/ThresholdsRequest' - x-stream-index: 007.001.021 + x-stream-index: 007.001.023 blocklist: type: string - x-stream-index: 007.001.019 + x-stream-index: 007.001.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 007.001.020 + x-stream-index: 007.001.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptionsRequest' + type: array + x-stream-index: 007.001.022 commands: description: List of commands that channel supports items: @@ -10976,14 +10547,17 @@ components: type: array type: object x-stream-index: "004" + mark_messages_pending: + type: boolean + x-stream-index: 007.001.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 007.001.016 + x-stream-index: 007.001.017 message_retention: type: string - x-stream-index: 007.001.015 + x-stream-index: 007.001.016 mutes: type: boolean x-stream-index: 007.001.009 @@ -11034,25 +10608,30 @@ components: - simple - AI type: string - x-stream-index: 003.001.017 + x-stream-index: 003.001.018 automod_behavior: enum: - flag - block type: string - x-stream-index: 003.001.018 + x-stream-index: 003.001.019 automod_thresholds: $ref: '#/components/schemas/Thresholds' - x-stream-index: 003.001.021 + x-stream-index: 003.001.023 blocklist: type: string - x-stream-index: 003.001.019 + x-stream-index: 003.001.020 blocklist_behavior: enum: - flag - block type: string - x-stream-index: 003.001.020 + x-stream-index: 003.001.021 + blocklists: + items: + $ref: '#/components/schemas/BlockListOptions' + type: array + x-stream-index: 003.001.022 commands: items: type: string @@ -11078,14 +10657,17 @@ components: type: array type: object x-stream-index: "002" + mark_messages_pending: + type: boolean + x-stream-index: 003.001.015 max_message_length: format: int32 maximum: 20000 type: integer - x-stream-index: 003.001.016 + x-stream-index: 003.001.017 message_retention: type: string - x-stream-index: 003.001.015 + x-stream-index: 003.001.016 mutes: type: boolean x-stream-index: 003.001.009 @@ -11148,6 +10730,7 @@ components: - custom_events - push_notifications - reminders + - mark_messages_pending - message_retention - max_message_length - automod @@ -11216,7 +10799,7 @@ components: description: Do not try to enrich the links within message title: Skip Enrich URL type: boolean - x-stream-index: "004" + x-stream-index: "005" unset: description: Array of field names to unset items: @@ -11250,34 +10833,11 @@ components: description: Do not try to enrich the links within message title: Skip Enrich URL type: boolean - x-stream-index: "002" + x-stream-index: "003" required: - message title: Update Message Request type: object - UpdateSegmentRequest: - nullable: true - properties: - segment: - $ref: '#/components/schemas/SegmentUpdateableFieldsRequest' - x-stream-index: "001" - required: - - segment - type: object - UpdateSegmentResponse: - nullable: true - properties: - duration: - description: Duration of the request in human-readable format - title: Duration - type: string - x-stream-index: "002.001" - segment: - $ref: '#/components/schemas/Segment' - x-stream-index: "001" - required: - - duration - type: object UpdateUserPartialRequest: nullable: true properties: @@ -12241,7 +11801,7 @@ externalDocs: url: https://getstream.io/chat/docs/ info: title: Stream Chat API - version: v84.1.1-3-g76840f817 + version: v89.9.2 openapi: 3.0.3 paths: /app: @@ -12430,17 +11990,15 @@ paths: Deletes previously created application blocklist operationId: DeleteBlockList parameters: - - content: - application/json: - schema: - description: Block list name - title: Name - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + description: Block list name + title: Name + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -12484,17 +12042,15 @@ paths: Returns block list by given name operationId: GetBlockList parameters: - - content: - application/json: - schema: - description: Block list name - title: Name - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + description: Block list name + title: Name + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -12538,15 +12094,13 @@ paths: Updates contents of the block list operationId: UpdateBlockList parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" requestBody: content: application/json: @@ -12591,7 +12145,7 @@ paths: - Moderation x-stream-docs-page-id: block_lists x-stream-server-side: true - /calls/: + /calls/{call_id}: post: description: | Retrieves the token to join a call @@ -12599,7 +12153,15 @@ paths: Required permissions: - JoinCall - ReadChannel - operationId: GetCallToken__1 + operationId: GetCallToken + parameters: + - in: path + name: call_id + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" requestBody: content: application/json: @@ -12638,43 +12200,44 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get Call Token () + summary: Get Call Token x-stream-docs-page-id: video x-stream-permissions: JoinCall: To request the call token ReadChannel: To read the channel - /calls/{call_id}: + /channels: post: description: | - Retrieves the token to join a call + Query channels with filter query Required permissions: - - JoinCall - ReadChannel - operationId: GetCallToken_call_id_0 + operationId: QueryChannels parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: call_id - required: true + - in: query + name: client_id + schema: + type: string + x-stream-index: "011.002" + - in: query + name: connection_id + schema: + type: string + x-stream-index: "011.003" requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetCallTokenRequest' + $ref: '#/components/schemas/QueryChannelsRequest' + description: Query Channels Request required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/GetCallTokenResponse' - description: Successful response + $ref: '#/components/schemas/ChannelsResponse' + description: Channels list "400": content: application/json: @@ -12700,30 +12263,53 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get Call Token (call_id) - x-stream-docs-page-id: video + summary: Query channels + tags: + - Channels + x-stream-docs-page-id: query_channels x-stream-permissions: - JoinCall: To request the call token - ReadChannel: To read the channel - /campaigns: - get: + ReadChannel: To access channels that were requested + /channels/{type}/{id}: + delete: description: | - Query campaigns - operationId: QueryCampaigns + Deletes channel + + Sends events: + - channel.deleted + + Required permissions: + - DeleteChannel + operationId: DeleteChannel parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QueryCampaignsRequest' - x-stream-index: "001" - in: query - name: payload + - in: path + name: type + required: true + schema: + description: Channel type to interact with + title: Channel type + type: string + writeOnly: true + x-stream-index: "001.001" + - in: path + name: id + required: true + schema: + description: Channel ID to interact with + title: Channel ID + type: string + writeOnly: true + x-stream-index: "001.002" + - in: query + name: hard_delete + schema: + type: boolean + x-stream-index: "002" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/QueryCampaignsResponse' + $ref: '#/components/schemas/DeleteChannelResponse' description: Successful response "400": content: @@ -12750,27 +12336,58 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query campaigns + summary: Delete channel tags: - - Campaigns - x-stream-docs-page-id: campaigns - x-stream-server-side: true - post: + - Channels + x-stream-docs-page-id: channel_delete + x-stream-events: + channel.deleted: When channel is deleted + x-stream-events-v2: + channel.deleted: + description: When channel is deleted + schema: + ref: '#/components/schemas/ChannelDeletedEvent' + x-stream-permissions: + DeleteChannel: To delete a channel + patch: description: | - Creates a new campaign - operationId: CreateCampaign + Updates certain fields of the channel + + Sends events: + - channel.updated + + Required permissions: + - UpdateChannel + - UpdateChannelCooldown + - UpdateChannelFrozen + operationId: UpdateChannelPartial + parameters: + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.001" + - in: path + name: id + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.002" requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateCampaignRequest' + $ref: '#/components/schemas/UpdateChannelPartialRequest' required: true responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/CreateCampaignResponse' + $ref: '#/components/schemas/UpdateChannelPartialResponse' description: Successful response "400": content: @@ -12797,41 +12414,68 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Create campaign + summary: Partially update channel tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /campaigns/{id}: - delete: + - Channels + x-stream-docs-page-id: channel_update#partial-update + x-stream-events: + channel.updated: When channel is updated + x-stream-events-v2: + channel.updated: + description: When channel is updated + schema: + ref: '#/components/schemas/ChannelUpdatedEvent' + x-stream-permissions: + UpdateChannel: To update channel data + UpdateChannelCooldown: To update channel cooldown (slowmode) + UpdateChannelFrozen: To freeze or unfreeze a channel + post: description: | - Delete a campaign - operationId: DeleteCampaign + Change channel data + + Sends events: + - channel.updated + - member.added + - member.removed + - member.updated + - message.new + + Required permissions: + - AddOwnChannelMembership + - RemoveOwnChannelMembership + - UpdateChannel + - UpdateChannelCooldown + - UpdateChannelFrozen + - UpdateChannelMembers + operationId: UpdateChannel parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: 013.002.001 + - in: path name: id required: true - - content: + schema: + type: string + writeOnly: true + x-stream-index: 013.002.002 + requestBody: + content: application/json: schema: - type: boolean - writeOnly: true - x-stream-index: "001" - in: query - name: recipients + $ref: '#/components/schemas/UpdateChannelRequest' + description: Channel update request + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/DeleteCampaignResponse' + $ref: '#/components/schemas/UpdateChannelResponse' description: Successful response "400": content: @@ -12858,38 +12502,80 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete campaign + summary: Update channel tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - put: + - Channels + x-stream-docs-page-id: channel_update + x-stream-events: + channel.updated: When channel is successfully updated + member.added: When new channel member is added + member.removed: When new channel member is removed + member.updated: When new channel member is updated + message.new: When system `message` is set + x-stream-events-v2: + channel.updated: + description: When channel is successfully updated + schema: + ref: '#/components/schemas/ChannelUpdatedEvent' + member.added: + description: When new channel member is added + schema: + ref: '#/components/schemas/MemberAddedEvent' + member.removed: + description: When new channel member is removed + schema: + ref: '#/components/schemas/MemberRemovedEvent' + member.updated: + description: When new channel member is updated + schema: + ref: '#/components/schemas/MemberUpdatedEvent' + message.new: + description: When system `message` is set + schema: + ref: '#/components/schemas/MessageNewEvent' + x-stream-permissions: + AddOwnChannelMembership: To add own channel membership (join a channel) + RemoveOwnChannelMembership: To remove own channel membership (leave a channel) + UpdateChannel: To update channel data + UpdateChannelCooldown: To update channel cooldown (slowmode) + UpdateChannelFrozen: To freeze or unfreeze a channel + UpdateChannelMembers: To add, remove or modify channel members + /channels/{type}/{id}/call: + post: description: | - Update an existing campaign - operationId: UpdateCampaign + Creates a call + + Required permissions: + - CreateCall + - ReadChannel + operationId: CreateCall parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "002" requestBody: content: application/json: schema: - $ref: '#/components/schemas/UpdateCampaignRequest' + $ref: '#/components/schemas/CreateCallRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/UpdateCampaignResponse' + $ref: '#/components/schemas/CreateCallResponse' description: Successful response "400": content: @@ -12916,92 +12602,53 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Update campaign - tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /campaigns/{id}/resume: - patch: - description: | - Resume a stopped campaign - operationId: ResumeCampaign - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path - name: id - required: true - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/ResumeCampaignResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Resume campaign - tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /campaigns/{id}/schedule: - patch: + summary: Create a call + x-stream-docs-page-id: video + x-stream-permissions: + CreateCall: To create a call + ReadChannel: To read the channel + /channels/{type}/{id}/event: + post: description: | - Schedule a campaign - operationId: ScheduleCampaign + Sends event to the channel + + Sends events: + - any + + Required permissions: + - SendCustomEvent + operationId: SendEvent parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path + - in: path + name: type + required: true + schema: + description: Channel type to interact with + title: Channel type + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true + schema: + description: Channel ID to interact with + title: Channel ID + type: string + writeOnly: true + x-stream-index: "002.002" requestBody: content: application/json: schema: - $ref: '#/components/schemas/ScheduleCampaignRequest' + $ref: '#/components/schemas/SendEventRequest' required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/ScheduleCampaignResponse' + $ref: '#/components/schemas/EventResponse' description: Successful response "400": content: @@ -13028,33 +12675,60 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Schedule campaign + summary: Send event tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /campaigns/{id}/stop: - patch: + - Events + x-stream-docs-page-id: event_object + x-stream-events: + any: Any event could be sent through this endpoint + x-stream-events-v2: + any: + description: Any event could be sent through this endpoint + schema: + ref: '#/components/schemas/AnyEvent' + x-stream-permissions: + SendCustomEvent: To send custom events + /channels/{type}/{id}/file: + delete: description: | - Stop a running campaign - operationId: StopCampaign + Deletes previously uploaded file + + Required permissions: + - DeleteAttachment + operationId: DeleteFile parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path + - in: path + name: type + required: true + schema: + description: The type of file + title: Type + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true + schema: + description: File ID + title: ID + type: string + writeOnly: true + x-stream-index: "002.002" + - in: query + name: url + schema: + description: File URL to delete + title: URL + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/StopCampaignResponse' + $ref: '#/components/schemas/FileDeleteResponse' description: Successful response "400": content: @@ -13081,40 +12755,48 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Stop campaign + summary: Delete file tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /campaigns/{id}/test: + - Messages + - Files + x-stream-docs-page-id: file_uploads + x-stream-permissions: + DeleteAttachment: To delete a file post: description: | - Test a campaign - operationId: TestCampaign + Uploads file + + Required permissions: + - UploadAttachment + operationId: UploadFile parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.002" requestBody: content: - application/json: + multipart/form-data: schema: - $ref: '#/components/schemas/TestCampaignRequest' + $ref: '#/components/schemas/FileUploadRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/TestCampaignResponse' - description: Test campaign response + $ref: '#/components/schemas/FileUploadResponse' + description: Successful response "400": content: application/json: @@ -13140,49 +12822,52 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Test campaign + summary: Upload file tags: - - Campaigns - x-stream-beta: true - x-stream-docs-page-id: campaigns - x-stream-server-side: true - /channels: + - Messages + - Files + x-stream-docs-page-id: file_uploads + x-stream-permissions: + UploadAttachment: To upload a file + /channels/{type}/{id}/hide: post: description: | - Query channels with filter query + Marks channel as hidden for current user + + Sends events: + - channel.hidden Required permissions: - ReadChannel - operationId: QueryChannels + operationId: HideChannel parameters: - - content: - application/json: - schema: - type: string - x-stream-index: "011.002" - in: query - name: client_id - - content: - application/json: - schema: - type: string - x-stream-index: "011.003" - in: query - name: connection_id + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path + name: id + required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.002" requestBody: content: application/json: schema: - $ref: '#/components/schemas/QueryChannelsRequest' - description: Query Channels Request + $ref: '#/components/schemas/HideChannelRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/ChannelsResponse' - description: Channels list + $ref: '#/components/schemas/HideChannelResponse' + description: Successful response "400": content: application/json: @@ -13208,59 +12893,60 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query channels + summary: Hide channel tags: - Channels - x-stream-docs-page-id: query_channels + x-stream-docs-page-id: channel_delete#hiding-a-channel + x-stream-events: + channel.hidden: When channel is hidden + x-stream-events-v2: + channel.hidden: + description: When channel is hidden + schema: + ref: '#/components/schemas/ChannelHiddenEvent' x-stream-permissions: - ReadChannel: To access channels that were requested - /channels/{type}/{id}: + ReadChannel: To hide specified channel + /channels/{type}/{id}/image: delete: description: | - Deletes channel - - Sends events: - - channel.deleted + Deletes previously uploaded image Required permissions: - - DeleteChannel - operationId: DeleteChannel + - DeleteAttachment + operationId: DeleteImage parameters: - - content: - application/json: - schema: - description: Channel type to interact with - title: Channel type - type: string - writeOnly: true - x-stream-index: "001.001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - description: Channel ID to interact with - title: Channel ID - type: string - writeOnly: true - x-stream-index: "001.002" - in: path + schema: + description: The type of file + title: Type + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true - - content: - application/json: - schema: - type: boolean - x-stream-index: "002" - in: query - name: hard_delete + schema: + description: File ID + title: ID + type: string + writeOnly: true + x-stream-index: "002.002" + - in: query + name: url + schema: + description: File URL to delete + title: URL + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/DeleteChannelResponse' + $ref: '#/components/schemas/FileDeleteResponse' description: Successful response "400": content: @@ -13287,62 +12973,47 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete channel + summary: Delete image tags: - - Channels - x-stream-docs-page-id: channel_delete - x-stream-events: - channel.deleted: When channel is deleted - x-stream-events-v2: - channel.deleted: - description: When channel is deleted - schema: - ref: '#/components/schemas/ChannelDeletedEvent' - x-stream-permissions: - DeleteChannel: To delete a channel - patch: + - Messages + - Files + x-stream-docs-page-id: file_uploads + x-stream-permissions: + DeleteAttachment: To delete an image + post: description: | - Updates certain fields of the channel - - Sends events: - - channel.updated + Uploads image Required permissions: - - UpdateChannel - - UpdateChannelCooldown - - UpdateChannelFrozen - operationId: UpdateChannelPartial + - UploadAttachment + operationId: UploadImage parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.002" - in: path + schema: + type: string + writeOnly: true + x-stream-index: 001.001.001 + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: 001.001.002 requestBody: content: - application/json: + multipart/form-data: schema: - $ref: '#/components/schemas/UpdateChannelPartialRequest' + $ref: '#/components/schemas/ImageUploadRequest' required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/UpdateChannelPartialResponse' + $ref: '#/components/schemas/ImageUploadResponse' description: Successful response "400": content: @@ -13369,72 +13040,58 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Partially update channel + summary: Upload image tags: - - Channels - x-stream-docs-page-id: channel_update#partial-update - x-stream-events: - channel.updated: When channel is updated - x-stream-events-v2: - channel.updated: - description: When channel is updated - schema: - ref: '#/components/schemas/ChannelUpdatedEvent' + - Messages + - Files + x-stream-docs-page-id: file_uploads x-stream-permissions: - UpdateChannel: To update channel data - UpdateChannelCooldown: To update channel cooldown (slowmode) - UpdateChannelFrozen: To freeze or unfreeze a channel + UploadAttachment: To upload an image + /channels/{type}/{id}/message: post: description: | - Change channel data + Sends new message to the specified channel Sends events: - - channel.updated - - member.added - - member.removed - - member.updated - message.new + - message.updated Required permissions: - - AddOwnChannelMembership - - RemoveOwnChannelMembership - - UpdateChannel - - UpdateChannelCooldown - - UpdateChannelFrozen - - UpdateChannelMembers - operationId: UpdateChannel + - AddLinks + - CreateMessage + - PinMessage + - SkipChannelCooldown + - SkipMessageModeration + - UseFrozenChannel + operationId: SendMessage parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: 013.002.001 - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: 013.002.002 - in: path + schema: + type: string + writeOnly: true + x-stream-index: "008.001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "008.002" requestBody: content: application/json: schema: - $ref: '#/components/schemas/UpdateChannelRequest' - description: Channel update request + $ref: '#/components/schemas/SendMessageRequest' + description: Send Message Request required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/UpdateChannelResponse' + $ref: '#/components/schemas/MessageWithPendingMetadataResponse' description: Successful response "400": content: @@ -13461,84 +13118,71 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Update channel + summary: Send new message tags: - - Channels - x-stream-docs-page-id: channel_update + - Messages + x-stream-docs-page-id: send_message x-stream-events: - channel.updated: When channel is successfully updated - member.added: When new channel member is added - member.removed: When new channel member is removed - member.updated: When new channel member is updated - message.new: When system `message` is set + message.new: When the message was successfully sent + message.updated: Parent message gets this event in case the message had been + sent to a thread x-stream-events-v2: - channel.updated: - description: When channel is successfully updated - schema: - ref: '#/components/schemas/ChannelUpdatedEvent' - member.added: - description: When new channel member is added - schema: - ref: '#/components/schemas/MemberAddedEvent' - member.removed: - description: When new channel member is removed - schema: - ref: '#/components/schemas/MemberRemovedEvent' - member.updated: - description: When new channel member is updated - schema: - ref: '#/components/schemas/MemberUpdatedEvent' message.new: - description: When system `message` is set + description: When the message was successfully sent schema: ref: '#/components/schemas/MessageNewEvent' + message.updated: + description: Parent message gets this event in case the message had been + sent to a thread + schema: + ref: '#/components/schemas/MessageUpdatedEvent' x-stream-permissions: - AddOwnChannelMembership: To add own channel membership (join a channel) - RemoveOwnChannelMembership: To remove own channel membership (leave a channel) - UpdateChannel: To update channel data - UpdateChannelCooldown: To update channel cooldown (slowmode) - UpdateChannelFrozen: To freeze or unfreeze a channel - UpdateChannelMembers: To add, remove or modify channel members - /channels/{type}/{id}/call: - post: + AddLinks: To send message with URLs + CreateMessage: To send a message + PinMessage: To send pinned message + SkipChannelCooldown: To bypass channel slow mode + SkipMessageModeration: To bypass automatic message moderation + UseFrozenChannel: To send a message to frozen channel + /channels/{type}/{id}/messages: + get: description: | - Creates a call + Returns list messages found by IDs Required permissions: - - CreateCall - ReadChannel - operationId: CreateCall + operationId: GetManyMessages parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002" - in: path + schema: + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateCallRequest' - required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.002" + - in: query + name: ids + schema: + description: List of comma-separated IDs + items: + type: string + maximum: 50 + minimum: 1 + title: IDs + type: array + x-stream-index: "001" responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/CreateCallResponse' + $ref: '#/components/schemas/GetManyMessagesResponse' description: Successful response "400": content: @@ -13565,57 +13209,65 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Create a call - x-stream-docs-page-id: video + summary: Get many messages + tags: + - Messages x-stream-permissions: - CreateCall: To create a call - ReadChannel: To read the channel - /channels/{type}/{id}/event: + ReadChannel: To read specified messages + /channels/{type}/{id}/query: post: description: | - Sends event to the channel + This method creates a channel or returns an existing one with matching attributes Sends events: - - any - - Required permissions: - - SendCustomEvent - operationId: SendEvent + - channel.created + - member.added + - member.removed + - member.updated + - user.watching.start + operationId: GetOrCreateChannel parameters: - - content: - application/json: - schema: - description: Channel type to interact with - title: Channel type - type: string - writeOnly: true - x-stream-index: "002.001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - description: Channel ID to interact with - title: Channel ID - type: string - writeOnly: true - x-stream-index: "002.002" - in: path + schema: + description: Channel type + maxLength: 64 + title: Type + type: string + writeOnly: true + x-stream-index: "002" + - in: path name: id required: true + schema: + description: Channel ID (maximum length of 64 characters) + title: ID + type: string + writeOnly: true + x-stream-index: "003" + - in: query + name: client_id + schema: + type: string + x-stream-index: "001.002" + - in: query + name: connection_id + schema: + type: string + x-stream-index: "001.003" requestBody: content: application/json: schema: - $ref: '#/components/schemas/SendEventRequest' + $ref: '#/components/schemas/ChannelGetOrCreateRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/EventResponse' + $ref: '#/components/schemas/ChannelStateResponse' description: Successful response "400": content: @@ -13642,44 +13294,75 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Send event + summary: Get or create channel tags: - - Events - x-stream-docs-page-id: event_object + - Channels + x-stream-docs-page-id: watch_channel x-stream-events: - any: Any event could be sent through this endpoint + channel.created: If channel is created + member.added: If member is added + member.removed: If member is removed + member.updated: If member is updated + user.watching.start: 'If `watch: true`' x-stream-events-v2: - any: - description: Any event could be sent through this endpoint + channel.created: + description: If channel is created schema: - ref: '#/components/schemas/AnyEvent' - x-stream-permissions: - SendCustomEvent: To send custom events - /channels/{type}/{id}/file: - delete: + ref: '#/components/schemas/ChannelCreatedEvent' + member.added: + description: If member is added + schema: + ref: '#/components/schemas/MemberAddedEvent' + member.removed: + description: If member is removed + schema: + ref: '#/components/schemas/MemberRemovedEvent' + member.updated: + description: If member is updated + schema: + ref: '#/components/schemas/MemberUpdatedEvent' + user.watching.start: + description: 'If `watch: true`' + schema: + ref: '#/components/schemas/UserWatchingStartEvent' + /channels/{type}/{id}/read: + post: description: | - Deletes previously uploaded file + Marks channel as read up to the specific message + + Sends events: + - message.read Required permissions: - - DeleteAttachment - operationId: DeleteFile + - ReadChannel + operationId: MarkRead parameters: - - content: + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path + name: id + required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.002" + requestBody: + content: application/json: schema: - description: File URL to delete - title: URL - type: string - writeOnly: true - x-stream-index: "001" - in: query - name: url + $ref: '#/components/schemas/MarkReadRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/FileDeleteResponse' + $ref: '#/components/schemas/MarkReadResponse' description: Successful response "400": content: @@ -13706,51 +13389,54 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete file + summary: Mark read tags: + - Channels - Messages - - Files - x-stream-docs-page-id: file_uploads + x-stream-events: + message.read: When the channel is marked as read + x-stream-events-v2: + message.read: + description: When the channel is marked as read + schema: + ref: '#/components/schemas/MessageReadEvent' x-stream-permissions: - DeleteAttachment: To delete a file + ReadChannel: To mark message read + /channels/{type}/{id}/show: post: description: | - Uploads file + Shows previously hidden channel - Required permissions: - - UploadAttachment - operationId: UploadFile + Sends events: + - channel.visible + operationId: ShowChannel parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.002" - in: path + schema: + type: string + writeOnly: true + x-stream-index: "001.001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.002" requestBody: content: - multipart/form-data: + application/json: schema: - $ref: '#/components/schemas/FileUploadRequest' + $ref: '#/components/schemas/ShowChannelRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/FileUploadResponse' + $ref: '#/components/schemas/ShowChannelResponse' description: Successful response "400": content: @@ -13777,55 +13463,62 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Upload file + summary: Show channel tags: - - Messages - - Files - x-stream-docs-page-id: file_uploads - x-stream-permissions: - UploadAttachment: To upload a file - /channels/{type}/{id}/hide: + - Channels + x-stream-docs-page-id: channel_delete#hiding-a-channel + x-stream-events: + channel.visible: When channel is shown + x-stream-events-v2: + channel.visible: + description: When channel is shown + schema: + ref: '#/components/schemas/ChannelVisibleEvent' + /channels/{type}/{id}/stop-watching: post: description: | - Marks channel as hidden for current user + Call this method to stop receiving channel events Sends events: - - channel.hidden - - Required permissions: - - ReadChannel - operationId: HideChannel + - user.watching.stop + operationId: StopWatchingChannel parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.002" - in: path + schema: + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.002" + - in: query + name: client_id + schema: + type: string + x-stream-index: "001.002" + - in: query + name: connection_id + schema: + type: string + x-stream-index: "001.003" requestBody: content: application/json: schema: - $ref: '#/components/schemas/HideChannelRequest' + $ref: '#/components/schemas/ChannelStopWatchingRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/HideChannelResponse' + $ref: '#/components/schemas/StopWatchingResponse' description: Successful response "400": content: @@ -13852,44 +13545,55 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Hide channel + summary: Stop watching channel tags: - Channels - x-stream-docs-page-id: channel_delete#hiding-a-channel x-stream-events: - channel.hidden: When channel is hidden + user.watching.stop: When successfully stopped watching x-stream-events-v2: - channel.hidden: - description: When channel is hidden + user.watching.stop: + description: When successfully stopped watching schema: - ref: '#/components/schemas/ChannelHiddenEvent' - x-stream-permissions: - ReadChannel: To hide specified channel - /channels/{type}/{id}/image: - delete: + ref: '#/components/schemas/UserWatchingStopEvent' + /channels/{type}/{id}/truncate: + post: description: | - Deletes previously uploaded image + Truncates channel + + Sends events: + - channel.truncated Required permissions: - - DeleteAttachment - operationId: DeleteImage + - DeleteChannel + - TruncateChannel + operationId: TruncateChannel parameters: - - content: + - in: path + name: type + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.001" + - in: path + name: id + required: true + schema: + type: string + writeOnly: true + x-stream-index: "001.002" + requestBody: + content: application/json: schema: - description: File URL to delete - title: URL - type: string - writeOnly: true - x-stream-index: "001" - in: query - name: url + $ref: '#/components/schemas/TruncateChannelRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/FileDeleteResponse' + $ref: '#/components/schemas/TruncateChannelResponse' description: Successful response "400": content: @@ -13916,51 +13620,56 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete image + summary: Truncate channel tags: - - Messages - - Files - x-stream-docs-page-id: file_uploads + - Channels + x-stream-docs-page-id: truncate_channel + x-stream-events: + channel.truncated: When channel is truncated + x-stream-events-v2: + channel.truncated: + description: When channel is truncated + schema: + ref: '#/components/schemas/ChannelTruncatedEvent' x-stream-permissions: - DeleteAttachment: To delete an image + DeleteChannel: To truncate a channel if TruncateChannel is not allowed or + hard_delete is requested + TruncateChannel: To truncate a channel if DeleteChannel is not allowed + /channels/{type}/{id}/unread: post: description: | - Uploads image + Marks channel as unread from a specific message Required permissions: - - UploadAttachment - operationId: UploadImage + - ReadChannel + operationId: MarkUnread parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: 001.001.001 - in: path + - in: path name: type required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: 001.001.002 - in: path + schema: + type: string + writeOnly: true + x-stream-index: "002.001" + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "002.002" requestBody: content: - multipart/form-data: + application/json: schema: - $ref: '#/components/schemas/ImageUploadRequest' + $ref: '#/components/schemas/MarkUnreadRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/ImageUploadResponse' + $ref: '#/components/schemas/Response' description: Successful response "400": content: @@ -13987,823 +13696,16 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Upload image + summary: Mark unread tags: + - Channels - Messages - - Files - x-stream-docs-page-id: file_uploads x-stream-permissions: - UploadAttachment: To upload an image - /channels/{type}/{id}/message: + ReadChannel: To mark messages unread + /channels/delete: post: description: | - Sends new message to the specified channel - - Sends events: - - message.new - - message.updated - - Required permissions: - - AddLinks - - CreateMessage - - PinMessage - - SkipChannelCooldown - - SkipMessageModeration - - UseFrozenChannel - operationId: SendMessage - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "007.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "007.002" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/SendMessageRequest' - description: Send Message Request - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/MessageWithPendingMetadataResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Send new message - tags: - - Messages - x-stream-docs-page-id: send_message - x-stream-events: - message.new: When the message was successfully sent - message.updated: Parent message gets this event in case the message had been - sent to a thread - x-stream-events-v2: - message.new: - description: When the message was successfully sent - schema: - ref: '#/components/schemas/MessageNewEvent' - message.updated: - description: Parent message gets this event in case the message had been - sent to a thread - schema: - ref: '#/components/schemas/MessageUpdatedEvent' - x-stream-permissions: - AddLinks: To send message with URLs - CreateMessage: To send a message - PinMessage: To send pinned message - SkipChannelCooldown: To bypass channel slow mode - SkipMessageModeration: To bypass automatic message moderation - UseFrozenChannel: To send a message to frozen channel - /channels/{type}/{id}/messages: - get: - description: | - Returns list messages found by IDs - - Required permissions: - - ReadChannel - operationId: GetManyMessages - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.002" - in: path - name: id - required: true - - content: - application/json: - schema: - description: List of comma-separated IDs - items: - type: string - maximum: 50 - minimum: 1 - title: IDs - type: array - x-stream-index: "001" - in: query - name: ids - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/GetManyMessagesResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Get many messages - tags: - - Messages - x-stream-permissions: - ReadChannel: To read specified messages - /channels/{type}/{id}/query: - post: - description: | - This method creates a channel or returns an existing one with matching attributes - - Sends events: - - channel.created - - member.added - - member.removed - - member.updated - - user.watching.start - operationId: GetOrCreateChannel_type_id_0 - parameters: - - content: - application/json: - schema: - description: Channel type - maxLength: 64 - title: Type - type: string - writeOnly: true - x-stream-index: "002" - in: path - name: type - required: true - - content: - application/json: - schema: - description: Channel ID - maxLength: 64 - title: ID - type: string - writeOnly: true - x-stream-index: "003" - in: path - name: id - required: true - - content: - application/json: - schema: - type: string - x-stream-index: "001.002" - in: query - name: client_id - - content: - application/json: - schema: - type: string - x-stream-index: "001.003" - in: query - name: connection_id - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ChannelGetOrCreateRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/ChannelStateResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Get or create channel (type, id) - tags: - - Channels - x-stream-docs-page-id: watch_channel - x-stream-events: - channel.created: If channel is created - member.added: If member is added - member.removed: If member is removed - member.updated: If member is updated - user.watching.start: 'If `watch: true`' - x-stream-events-v2: - channel.created: - description: If channel is created - schema: - ref: '#/components/schemas/ChannelCreatedEvent' - member.added: - description: If member is added - schema: - ref: '#/components/schemas/MemberAddedEvent' - member.removed: - description: If member is removed - schema: - ref: '#/components/schemas/MemberRemovedEvent' - member.updated: - description: If member is updated - schema: - ref: '#/components/schemas/MemberUpdatedEvent' - user.watching.start: - description: 'If `watch: true`' - schema: - ref: '#/components/schemas/UserWatchingStartEvent' - /channels/{type}/{id}/read: - post: - description: | - Marks channel as read up to the specific message - - Sends events: - - message.read - - Required permissions: - - ReadChannel - operationId: MarkRead - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.002" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/MarkReadRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/MarkReadResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Mark read - tags: - - Channels - - Messages - x-stream-events: - message.read: When the channel is marked as read - x-stream-events-v2: - message.read: - description: When the channel is marked as read - schema: - ref: '#/components/schemas/MessageReadEvent' - x-stream-permissions: - ReadChannel: To mark message read - /channels/{type}/{id}/show: - post: - description: | - Shows previously hidden channel - - Sends events: - - channel.visible - operationId: ShowChannel - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.002" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ShowChannelRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/ShowChannelResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Show channel - tags: - - Channels - x-stream-docs-page-id: channel_delete#hiding-a-channel - x-stream-events: - channel.visible: When channel is shown - x-stream-events-v2: - channel.visible: - description: When channel is shown - schema: - ref: '#/components/schemas/ChannelVisibleEvent' - /channels/{type}/{id}/stop-watching: - post: - description: | - Call this method to stop receiving channel events - - Sends events: - - user.watching.stop - operationId: StopWatchingChannel - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.002" - in: path - name: id - required: true - - content: - application/json: - schema: - type: string - x-stream-index: "001.002" - in: query - name: client_id - - content: - application/json: - schema: - type: string - x-stream-index: "001.003" - in: query - name: connection_id - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ChannelStopWatchingRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/StopWatchingResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Stop watching channel - tags: - - Channels - x-stream-events: - user.watching.stop: When successfully stopped watching - x-stream-events-v2: - user.watching.stop: - description: When successfully stopped watching - schema: - ref: '#/components/schemas/UserWatchingStopEvent' - /channels/{type}/{id}/truncate: - post: - description: | - Truncates channel - - Sends events: - - channel.truncated - - Required permissions: - - DeleteChannel - - TruncateChannel - operationId: TruncateChannel - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.002" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/TruncateChannelRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/TruncateChannelResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Truncate channel - tags: - - Channels - x-stream-docs-page-id: truncate_channel - x-stream-events: - channel.truncated: When channel is truncated - x-stream-events-v2: - channel.truncated: - description: When channel is truncated - schema: - ref: '#/components/schemas/ChannelTruncatedEvent' - x-stream-permissions: - DeleteChannel: To truncate a channel if TruncateChannel is not allowed or - hard_delete is requested - TruncateChannel: To truncate a channel if DeleteChannel is not allowed - /channels/{type}/{id}/unread: - post: - description: | - Marks channel as unread from a specific message - - Required permissions: - - ReadChannel - operationId: MarkUnread - parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "002.002" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/MarkUnreadRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/Response' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Mark unread - tags: - - Channels - - Messages - x-stream-permissions: - ReadChannel: To mark messages unread - /channels/{type}/query: - post: - description: | - This method creates a channel or returns an existing one with matching attributes - - Sends events: - - channel.created - - member.added - - member.removed - - member.updated - - user.watching.start - operationId: GetOrCreateChannel_type_1 - parameters: - - content: - application/json: - schema: - description: Channel type - maxLength: 64 - title: Type - type: string - writeOnly: true - x-stream-index: "002" - in: path - name: type - required: true - - content: - application/json: - schema: - type: string - x-stream-index: "001.002" - in: query - name: client_id - - content: - application/json: - schema: - type: string - x-stream-index: "001.003" - in: query - name: connection_id - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ChannelGetOrCreateRequest' - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/ChannelStateResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Get or create channel (type) - tags: - - Channels - x-stream-docs-page-id: watch_channel - x-stream-events: - channel.created: If channel is created - member.added: If member is added - member.removed: If member is removed - member.updated: If member is updated - user.watching.start: 'If `watch: true`' - x-stream-events-v2: - channel.created: - description: If channel is created - schema: - ref: '#/components/schemas/ChannelCreatedEvent' - member.added: - description: If member is added - schema: - ref: '#/components/schemas/MemberAddedEvent' - member.removed: - description: If member is removed - schema: - ref: '#/components/schemas/MemberRemovedEvent' - member.updated: - description: If member is updated - schema: - ref: '#/components/schemas/MemberUpdatedEvent' - user.watching.start: - description: 'If `watch: true`' - schema: - ref: '#/components/schemas/UserWatchingStartEvent' - /channels/delete: - post: - description: | - Allows to delete several channels at once asynchronously + Allows to delete several channels at once asynchronously Sends events: - channel.deleted @@ -15022,17 +13924,15 @@ paths: Deletes channel type operationId: DeleteChannelType parameters: - - content: - application/json: - schema: - description: Channel type name - title: Name - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + description: Channel type name + title: Name + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -15076,17 +13976,15 @@ paths: Gets channel type operationId: GetChannelType parameters: - - content: - application/json: - schema: - description: Channel type name - title: Name - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + description: Channel type name + title: Name + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -15130,15 +14028,13 @@ paths: Updates channel type operationId: UpdateChannelType parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" requestBody: content: application/json: @@ -15232,6 +14128,55 @@ paths: - Testing x-stream-docs-page-id: push_test x-stream-server-side: true + /check_sns: + post: + description: | + Validates Amazon SNS configuration + operationId: CheckSNS + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CheckSNSRequest' + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/CheckSNSResponse' + description: Successful response + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/APIError' + description: Bad request + "429": + content: + application/json: + schema: + $ref: '#/components/schemas/APIError' + description: Too many requests + headers: + X-RateLimit-Limit: + description: The number of allowed requests in the current period + schema: + type: integer + X-RateLimit-Remaining: + description: The number of remaining requests in the current period + schema: + type: integer + X-RateLimit-Reset: + description: Timestamp when number of requests will be reset + schema: + type: integer + summary: Check SNS + tags: + - Settings + - Testing + x-stream-docs-page-id: sns + x-stream-server-side: true /check_sqs: post: description: | @@ -15377,14 +14322,12 @@ paths: Deletes custom chat command operationId: DeleteCommand parameters: - - content: - application/json: - schema: - type: string - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + type: string + x-stream-index: "001" responses: "200": content: @@ -15427,14 +14370,12 @@ paths: Returns custom command by its name operationId: GetCommand parameters: - - content: - application/json: - schema: - type: string - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + type: string + x-stream-index: "001" responses: "200": content: @@ -15477,17 +14418,15 @@ paths: Updates custom chat command operationId: UpdateCommand parameters: - - content: - application/json: - schema: - description: Unique command name - title: Name - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: name required: true + schema: + description: Unique command name + title: Name + type: string + writeOnly: true + x-stream-index: "001" requestBody: content: application/json: @@ -15591,26 +14530,22 @@ paths: Deletes one device operationId: DeleteDevice parameters: - - content: - application/json: - schema: - description: Device ID to delete - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: query + - in: query name: id - - content: - application/json: - schema: - description: '**Server-side only**. User ID which server acts upon' - title: User ID - type: string - writeOnly: true - x-stream-index: "002.001" - in: query + schema: + description: Device ID to delete + title: ID + type: string + writeOnly: true + x-stream-index: "001" + - in: query name: user_id + schema: + description: '**Server-side only**. User ID which server acts upon' + title: User ID + type: string + writeOnly: true + x-stream-index: "002.001" responses: "200": content: @@ -15652,16 +14587,14 @@ paths: Returns all available devices operationId: ListDevices parameters: - - content: - application/json: - schema: - description: '**Server-side only**. User ID which server acts upon' - title: User ID - type: string - writeOnly: true - x-stream-index: "001.001" - in: query + - in: query name: user_id + schema: + description: '**Server-side only**. User ID which server acts upon' + title: User ID + type: string + writeOnly: true + x-stream-index: "001.001" responses: "200": content: @@ -15743,7 +14676,7 @@ paths: post: description: | Exports user profile, reactions and messages for list of given users - operationId: ExportUser + operationId: ExportUsers requestBody: content: application/json: @@ -15842,17 +14775,15 @@ paths: operationId: GetExportChannelsStatus parameters: - - content: - application/json: - schema: - description: Task ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true + schema: + description: Task ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -16083,15 +15014,13 @@ paths: Gets an import operationId: GetImport parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -16146,268 +15075,14 @@ paths: x-stream-index: "001" in: query name: json - - content: - application/json: - schema: - maxLength: 36 - type: string - writeOnly: true - x-stream-index: "002" - in: query + - in: query name: connection_id - responses: - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Long Poll (Transport) - tags: - - Users - x-stream-docs-page-id: init_and_users - x-stream-events: - user.updated: When user is created or updated - x-stream-events-v2: - user.updated: - description: When user is created or updated - schema: - ref: '#/components/schemas/UserUpdatedEvent' - /members: - get: - description: | - Find and filter channel members - - Required permissions: - - ReadChannel - operationId: QueryMembers - parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QueryMembersRequest' - x-stream-index: "001" - in: query - name: payload - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/MembersResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Query members - tags: - - Channels - x-stream-docs-page-id: query_members - x-stream-permissions: - ReadChannel: To read members of specified channel - /messages/{id}: - delete: - description: | - Deletes message - - Sends events: - - message.deleted - - Required permissions: - - DeleteMessage - operationId: DeleteMessage - parameters: - - content: - application/json: - schema: - description: Message ID to delete - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: id - required: true - - content: - application/json: - schema: - description: Delete all message reactions and replies as well - title: Hard - type: boolean - writeOnly: true - x-stream-index: "002" - in: query - name: hard - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/MessageResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Delete message - tags: - - Messages - x-stream-docs-page-id: send_message#delete-a-message - x-stream-events: - message.deleted: When message is deleted - x-stream-events-v2: - message.deleted: - description: When message is deleted - schema: - ref: '#/components/schemas/MessageDeletedEvent' - x-stream-permissions: - DeleteMessage: To delete a message - get: - description: | - Returns message by ID - - Required permissions: - - ReadChannel - operationId: GetMessage - parameters: - - content: - application/json: - schema: - description: Message ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: id - required: true - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/MessageWithPendingMetadataResponse' - description: Successful response - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Get message - tags: - - Messages - x-stream-docs-page-id: send_message#get-a-message - x-stream-permissions: - ReadChannel: To read specified message - post: - description: | - Updates message with new data - - Sends events: - - message.updated - - Required permissions: - - AddLinks - - PinMessage - - SkipMessageModeration - - UpdateMessage - operationId: UpdateMessage - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateMessageRequest' - description: Update Message Request - required: true - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/MessageResponse' - description: Successful response + schema: + maxLength: 36 + type: string + writeOnly: true + x-stream-index: "002" + responses: "400": content: application/json: @@ -16433,47 +15108,39 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Update message + summary: Long Poll (Transport) tags: - - Messages - x-stream-docs-page-id: send_message#update-a-message + - Users + x-stream-docs-page-id: init_and_users x-stream-events: - message.updated: When message is updated + user.updated: When user is created or updated x-stream-events-v2: - message.updated: - description: When message is updated + user.updated: + description: When user is created or updated schema: - ref: '#/components/schemas/MessageUpdatedEvent' - x-stream-permissions: - AddLinks: To add URLs to a message - PinMessage: To pin a message - SkipMessageModeration: To bypass automatic message moderation - UpdateMessage: To update message text or other data - put: + ref: '#/components/schemas/UserUpdatedEvent' + /members: + get: description: | - Updates certain fields of the message - - Sends events: - - message.updated + Find and filter channel members Required permissions: - - AddLinks - - PinMessage - - SkipMessageModeration - - UpdateMessage - operationId: UpdateMessagePartial - requestBody: - content: + - ReadChannel + operationId: QueryMembers + parameters: + - content: application/json: schema: - $ref: '#/components/schemas/UpdateMessagePartialRequest' - required: true + $ref: '#/components/schemas/QueryMembersRequest' + x-stream-index: "001" + in: query + name: payload responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/MessageResponse' + $ref: '#/components/schemas/MembersResponse' description: Successful response "400": content: @@ -16500,53 +15167,49 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Partially message update + summary: Query members tags: - - Messages - x-stream-docs-page-id: send_message#partial-update - x-stream-events: - message.updated: When message is updated - x-stream-events-v2: - message.updated: - description: When message is updated - schema: - ref: '#/components/schemas/MessageUpdatedEvent' + - Channels + x-stream-docs-page-id: query_members x-stream-permissions: - AddLinks: To add URLs to a message - PinMessage: To pin a message - SkipMessageModeration: To bypass automatic message moderation - UpdateMessage: To update message text or other data - /messages/{id}/action: - post: + ReadChannel: To read members of specified channel + /messages/{id}: + delete: description: | - Executes message command action with given parameters + Deletes message Sends events: - - message.new + - message.deleted Required permissions: - - RunMessageAction - operationId: RunMessageAction + - DeleteMessage + operationId: DeleteMessage parameters: - - content: - application/json: - schema: - description: Message ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/MessageActionRequest' - required: true + schema: + description: Message ID to delete + title: ID + type: string + writeOnly: true + x-stream-index: "001" + - in: query + name: hard + schema: + description: Delete all message reactions and replies as well + title: Hard + type: boolean + writeOnly: true + x-stream-index: "002" + - in: query + name: created_by + schema: + type: string + writeOnly: true + x-stream-index: "003" responses: - "201": + "200": content: application/json: schema: @@ -16577,43 +15240,42 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Run message command action + summary: Delete message tags: - Messages + x-stream-docs-page-id: send_message#delete-a-message x-stream-events: - message.new: When messages became visible after command execution + message.deleted: When message is deleted x-stream-events-v2: - message.new: - description: When messages became visible after command execution + message.deleted: + description: When message is deleted schema: - ref: '#/components/schemas/MessageNewEvent' + ref: '#/components/schemas/MessageDeletedEvent' x-stream-permissions: - RunMessageAction: To execute action on specified message - /messages/{id}/commit: - post: + DeleteMessage: To delete a message + get: description: | - Commits a pending message, which will make it visible in the channel + Returns message by ID - Sends events: - - message.new - - message.updated - operationId: CommitMessage + Required permissions: + - ReadChannel + operationId: GetMessage parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/MessageResponse' + $ref: '#/components/schemas/MessageWithPendingMetadataResponse' description: Successful response "400": content: @@ -16640,59 +15302,48 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Commit message - x-stream-events: - message.new: When the message was successfully sent - message.updated: Parent message gets this event in case the message had been - sent to a thread - x-stream-events-v2: - message.new: - description: When the message was successfully sent - schema: - ref: '#/components/schemas/MessageNewEvent' - message.updated: - description: Parent message gets this event in case the message had been - sent to a thread - schema: - ref: '#/components/schemas/MessageUpdatedEvent' - x-stream-server-side: true - /messages/{id}/reaction: + summary: Get message + tags: + - Messages + x-stream-docs-page-id: send_message#get-a-message + x-stream-permissions: + ReadChannel: To read specified message post: description: | - Sends reaction to specified message + Updates message with new data Sends events: - - reaction.new - - reaction.updated + - message.updated Required permissions: - - CreateReaction - - UseFrozenChannel - operationId: SendReaction + - AddLinks + - PinMessage + - SkipMessageModeration + - UpdateMessage + operationId: UpdateMessage parameters: - - content: - application/json: - schema: - description: Message ID to send reaction for - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "002.001" requestBody: content: application/json: schema: - $ref: '#/components/schemas/SendReactionRequest' + $ref: '#/components/schemas/UpdateMessageRequest' + description: Update Message Request required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/ReactionResponse' + $ref: '#/components/schemas/MessageResponse' description: Successful response "400": content: @@ -16719,76 +15370,57 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Send reaction + summary: Update message tags: - Messages - - Reactions - x-stream-docs-page-id: send_reaction + x-stream-docs-page-id: send_message#update-a-message x-stream-events: - reaction.new: When new reaction is created - reaction.updated: When reaction is updated + message.updated: When message is updated x-stream-events-v2: - reaction.new: - description: When new reaction is created - schema: - ref: '#/components/schemas/ReactionNewEvent' - reaction.updated: - description: When reaction is updated + message.updated: + description: When message is updated schema: - ref: '#/components/schemas/ReactionUpdatedEvent' + ref: '#/components/schemas/MessageUpdatedEvent' x-stream-permissions: - CreateReaction: To send a reaction - UseFrozenChannel: To send a message to frozen channel - /messages/{id}/reaction/{type}: - delete: + AddLinks: To add URLs to a message + PinMessage: To pin a message + SkipMessageModeration: To bypass automatic message moderation + UpdateMessage: To update message text or other data + put: description: | - Removes user reaction from the message + Updates certain fields of the message Sends events: - - reaction.deleted + - message.updated Required permissions: - - DeleteReaction - operationId: DeleteReaction + - AddLinks + - PinMessage + - SkipMessageModeration + - UpdateMessage + operationId: UpdateMessagePartial parameters: - - content: - application/json: - schema: - description: Message ID to remove reaction from - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true - - content: - application/json: - schema: - description: Reaction type to remove - title: Type - type: string - writeOnly: true - x-stream-index: "002" - in: path - name: type - required: true - - content: - application/json: - schema: - description: '**Server-side only**. User ID which server acts upon' - title: User ID - type: string - writeOnly: true - x-stream-index: "003" - in: query - name: user_id + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "003.001" + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateMessagePartialRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/ReactionRemovalResponse' + $ref: '#/components/schemas/MessageResponse' description: Successful response "400": content: @@ -16815,68 +15447,55 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete reaction + summary: Partially message update tags: - Messages - - Reactions - x-stream-docs-page-id: send_reaction + x-stream-docs-page-id: send_message#partial-update x-stream-events: - reaction.deleted: When reaction is deleted + message.updated: When message is updated x-stream-events-v2: - reaction.deleted: - description: When reaction is deleted + message.updated: + description: When message is updated schema: - ref: '#/components/schemas/ReactionDeletedEvent' + ref: '#/components/schemas/MessageUpdatedEvent' x-stream-permissions: - DeleteReaction: To delete a reaction - /messages/{id}/reactions: - get: + AddLinks: To add URLs to a message + PinMessage: To pin a message + SkipMessageModeration: To bypass automatic message moderation + UpdateMessage: To update message text or other data + /messages/{id}/action: + post: description: | - Returns list of reactions of specific message + Executes message command action with given parameters + + Sends events: + - message.new Required permissions: - - ReadChannel - operationId: GetReactions + - RunMessageAction + operationId: RunMessageAction parameters: - - content: - application/json: - schema: - description: Message ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true - - content: - application/json: - schema: - description: Number of records to return - format: int32 - title: Limit - type: integer - writeOnly: true - x-stream-index: "002" - in: query - name: limit - - content: + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" + requestBody: + content: application/json: schema: - description: Number of records to offset - format: int32 - title: Offset - type: integer - writeOnly: true - x-stream-index: "003" - in: query - name: offset + $ref: '#/components/schemas/MessageActionRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/GetReactionsResponse' + $ref: '#/components/schemas/MessageResponse' description: Successful response "400": content: @@ -16903,30 +15522,35 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get reactions + summary: Run message command action tags: - Messages - - Reactions - x-stream-docs-page-id: send_reaction + x-stream-events: + message.new: When messages became visible after command execution + x-stream-events-v2: + message.new: + description: When messages became visible after command execution + schema: + ref: '#/components/schemas/MessageNewEvent' x-stream-permissions: - ReadChannel: To read specified reactions - /messages/{id}/translate: + RunMessageAction: To execute action on specified message + /messages/{id}/commit: post: description: | - Translates message to a given language using automated translation software + Commits a pending message, which will make it visible in the channel Sends events: + - message.new - message.updated - - Required permissions: - - ReadChannel - operationId: TranslateMessage - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/TranslateMessageRequest' + operationId: CommitMessage + parameters: + - in: path + name: id required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" responses: "201": content: @@ -16959,120 +15583,57 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Translate message - tags: - - Messages - x-stream-docs-page-id: translation + summary: Commit message x-stream-events: - message.updated: When event is updated with translation data + message.new: When the message was successfully sent + message.updated: Parent message gets this event in case the message had been + sent to a thread x-stream-events-v2: + message.new: + description: When the message was successfully sent + schema: + ref: '#/components/schemas/MessageNewEvent' message.updated: - description: When event is updated with translation data + description: Parent message gets this event in case the message had been + sent to a thread schema: ref: '#/components/schemas/MessageUpdatedEvent' - x-stream-permissions: - ReadChannel: To access channel of specified message - /messages/{parent_id}/replies: - get: + x-stream-server-side: true + /messages/{id}/reaction: + post: description: | - Returns replies (thread) of the message + Sends reaction to specified message + + Sends events: + - reaction.new + - reaction.updated Required permissions: - - ReadChannel - operationId: GetReplies + - CreateReaction + - UseFrozenChannel + operationId: SendReaction parameters: - - content: - application/json: - schema: - description: ID of a message which replies to return - title: Parent ID - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: parent_id + - in: path + name: id required: true - - content: - application/json: - schema: - type: string - x-stream-index: 002.001.003 - in: query - name: id_gte - - content: - application/json: - schema: - type: string - x-stream-index: 002.001.004 - in: query - name: id_gt - - content: - application/json: - schema: - type: string - x-stream-index: 002.001.005 - in: query - name: id_lte - - content: - application/json: - schema: - type: string - x-stream-index: 002.001.006 - in: query - name: id_lt - - content: - application/json: - schema: - format: date-time - type: string - x-stream-index: 002.001.007 - in: query - name: created_at_after_or_equal - - content: - application/json: - schema: - format: date-time - type: string - x-stream-index: 002.001.008 - in: query - name: created_at_after - - content: - application/json: - schema: - format: date-time - type: string - x-stream-index: 002.001.009 - in: query - name: created_at_before_or_equal - - content: - application/json: - schema: - format: date-time - type: string - x-stream-index: 002.001.010 - in: query - name: created_at_before - - content: - application/json: - schema: - type: string - x-stream-index: 002.001.011 - in: query - name: id_around - - content: + schema: + description: Message ID to send reaction for + title: ID + type: string + writeOnly: true + x-stream-index: "001" + requestBody: + content: application/json: schema: - format: date-time - type: string - x-stream-index: 002.001.012 - in: query - name: created_at_around + $ref: '#/components/schemas/SendReactionRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/GetRepliesResponse' + $ref: '#/components/schemas/ReactionResponse' description: Successful response "400": content: @@ -17099,52 +15660,70 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get replies + summary: Send reaction tags: - Messages - x-stream-docs-page-id: threads + - Reactions + x-stream-docs-page-id: send_reaction + x-stream-events: + reaction.new: When new reaction is created + reaction.updated: When reaction is updated + x-stream-events-v2: + reaction.new: + description: When new reaction is created + schema: + ref: '#/components/schemas/ReactionNewEvent' + reaction.updated: + description: When reaction is updated + schema: + ref: '#/components/schemas/ReactionUpdatedEvent' x-stream-permissions: - ReadChannel: To read replies of specified message - /moderation/ban: + CreateReaction: To send a reaction + UseFrozenChannel: To send a message to frozen channel + /messages/{id}/reaction/{type}: delete: description: | - Removes previously applied ban + Removes user reaction from the message Sends events: - - user.unbanned + - reaction.deleted Required permissions: - - BanChannelMember - - BanUser - operationId: Unban - parameters: - - content: - application/json: - schema: - type: string - x-stream-index: "001" - in: query - name: target_user_id - - content: - application/json: - schema: - type: string - x-stream-index: "002" - in: query - name: type - - content: - application/json: - schema: - type: string - x-stream-index: "003" - in: query + - DeleteReaction + operationId: DeleteReaction + parameters: + - in: path name: id + required: true + schema: + description: Message ID to remove reaction from + title: ID + type: string + writeOnly: true + x-stream-index: "001" + - in: path + name: type + required: true + schema: + description: Reaction type to remove + title: Type + type: string + writeOnly: true + x-stream-index: "002" + - in: query + name: user_id + schema: + description: '**Server-side only**. User ID which server acts upon' + title: User ID + type: string + writeOnly: true + x-stream-index: "003" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/Response' + $ref: '#/components/schemas/ReactionRemovalResponse' description: Successful response "400": content: @@ -17171,44 +15750,62 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Unban user + summary: Delete reaction tags: - - Users - - Moderation - x-stream-docs-page-id: moderation#ban + - Messages + - Reactions + x-stream-docs-page-id: send_reaction x-stream-events: - user.unbanned: When user is unbanned + reaction.deleted: When reaction is deleted x-stream-events-v2: - user.unbanned: - description: When user is unbanned + reaction.deleted: + description: When reaction is deleted schema: - ref: '#/components/schemas/UserUnbannedEvent' + ref: '#/components/schemas/ReactionDeletedEvent' x-stream-permissions: - BanChannelMember: To unban channel member - BanUser: To unban a user - post: + DeleteReaction: To delete a reaction + /messages/{id}/reactions: + get: description: | - Restricts user activity either in specific channel or globally - - Sends events: - - user.banned + Returns list of reactions of specific message Required permissions: - - BanChannelMember - - BanUser - operationId: Ban - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/BanRequest' + - ReadChannel + operationId: GetReactions + parameters: + - in: path + name: id required: true + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" + - in: query + name: limit + schema: + description: Number of records to return + format: int32 + title: Limit + type: integer + writeOnly: true + x-stream-index: "002" + - in: query + name: offset + schema: + description: Number of records to offset + format: int32 + title: Offset + type: integer + writeOnly: true + x-stream-index: "003" responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/Response' + $ref: '#/components/schemas/GetReactionsResponse' description: Successful response "400": content: @@ -17235,46 +15832,46 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Ban user + summary: Get reactions tags: - - Users - - Moderation - x-stream-docs-page-id: moderation#ban - x-stream-events: - user.banned: When user is banned - x-stream-events-v2: - user.banned: - description: When user is banned - schema: - ref: '#/components/schemas/UserBannedEvent' + - Messages + - Reactions + x-stream-docs-page-id: send_reaction x-stream-permissions: - BanChannelMember: To ban channel member - BanUser: To ban a user - /moderation/flag: + ReadChannel: To read specified reactions + /messages/{id}/translate: post: description: | - Reports message or user for review by moderators + Translates message to a given language using automated translation software Sends events: - - message.flagged - - user.flagged + - message.updated Required permissions: - - FlagMessage - - FlagUser - operationId: Flag + - ReadChannel + operationId: TranslateMessage + parameters: + - in: path + name: id + required: true + schema: + description: Message ID + title: ID + type: string + writeOnly: true + x-stream-index: "001.001" requestBody: content: application/json: schema: - $ref: '#/components/schemas/FlagRequest' + $ref: '#/components/schemas/TranslateMessageRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/FlagResponse' + $ref: '#/components/schemas/MessageResponse' description: Successful response "400": content: @@ -17301,49 +15898,98 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Flag + summary: Translate message tags: - - Moderation - Messages - - Users - x-stream-docs-page-id: moderation#flag + x-stream-docs-page-id: translation x-stream-events: - message.flagged: When message is flagged - user.flagged: When user is flagged + message.updated: When event is updated with translation data x-stream-events-v2: - message.flagged: - description: When message is flagged - schema: - ref: '#/components/schemas/MessageFlaggedEvent' - user.flagged: - description: When user is flagged + message.updated: + description: When event is updated with translation data schema: - ref: '#/components/schemas/UserFlaggedEvent' + ref: '#/components/schemas/MessageUpdatedEvent' x-stream-permissions: - FlagMessage: To flag a message - FlagUser: To flag a user - /moderation/flags/message: + ReadChannel: To access channel of specified message + /messages/{parent_id}/replies: get: description: | - Find and filter message flags + Returns replies (thread) of the message Required permissions: - - ReadMessageFlags - operationId: QueryMessageFlags + - ReadChannel + operationId: GetReplies parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QueryMessageFlagsRequest' - x-stream-index: "001" - in: query - name: payload + - in: path + name: parent_id + required: true + schema: + description: ID of a message which replies to return + title: Parent ID + type: string + writeOnly: true + x-stream-index: "001" + - in: query + name: id_gte + schema: + type: string + x-stream-index: 002.001.003 + - in: query + name: id_gt + schema: + type: string + x-stream-index: 002.001.004 + - in: query + name: id_lte + schema: + type: string + x-stream-index: 002.001.005 + - in: query + name: id_lt + schema: + type: string + x-stream-index: 002.001.006 + - in: query + name: created_at_after_or_equal + schema: + format: date-time + type: string + x-stream-index: 002.001.007 + - in: query + name: created_at_after + schema: + format: date-time + type: string + x-stream-index: 002.001.008 + - in: query + name: created_at_before_or_equal + schema: + format: date-time + type: string + x-stream-index: 002.001.009 + - in: query + name: created_at_before + schema: + format: date-time + type: string + x-stream-index: 002.001.010 + - in: query + name: id_around + schema: + type: string + x-stream-index: 002.001.011 + - in: query + name: created_at_around + schema: + format: date-time + type: string + x-stream-index: 002.001.012 responses: "200": content: application/json: schema: - $ref: '#/components/schemas/QueryMessageFlagsResponse' + $ref: '#/components/schemas/GetRepliesResponse' description: Successful response "400": content: @@ -17370,36 +16016,51 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query Message Flags + summary: Get replies tags: - Messages - - Moderation - x-stream-docs-page-id: moderation#query-message-flags + x-stream-docs-page-id: threads x-stream-permissions: - ReadMessageFlags: To read flagged messages - /moderation/mute: - post: + ReadChannel: To read replies of specified message + /moderation/ban: + delete: description: | - Mutes one or several users + Removes previously applied ban Sends events: - - user.muted + - user.unbanned Required permissions: - - MuteUser - operationId: MuteUser - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/MuteUserRequest' - required: true + - BanChannelMember + - BanUser + operationId: Unban + parameters: + - in: query + name: target_user_id + schema: + type: string + x-stream-index: "001" + - in: query + name: type + schema: + type: string + x-stream-index: "002" + - in: query + name: id + schema: + type: string + x-stream-index: "003" + - in: query + name: created_by + schema: + type: string + x-stream-index: "004" responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/MuteUserResponse' + $ref: '#/components/schemas/Response' description: Successful response "400": content: @@ -17426,43 +16087,44 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Mute user + summary: Unban user tags: - Users - Moderation - x-stream-docs-page-id: moderation#mutes + x-stream-docs-page-id: moderation#ban x-stream-events: - user.muted: When user is muted + user.unbanned: When user is unbanned x-stream-events-v2: - user.muted: - description: When user is muted + user.unbanned: + description: When user is unbanned schema: - ref: '#/components/schemas/UserMutedEvent' + ref: '#/components/schemas/UserUnbannedEvent' x-stream-permissions: - MuteUser: To mute a user - /moderation/mute/channel: + BanChannelMember: To unban channel member + BanUser: To unban a user post: description: | - Mutes channel for user + Restricts user activity either in specific channel or globally Sends events: - - channel.muted + - user.banned Required permissions: - - MuteChannel - operationId: MuteChannel + - BanChannelMember + - BanUser + operationId: Ban requestBody: content: application/json: schema: - $ref: '#/components/schemas/MuteChannelRequest' + $ref: '#/components/schemas/BanRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/MuteChannelResponse' + $ref: '#/components/schemas/Response' description: Successful response "400": content: @@ -17489,28 +16151,34 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Mute channel + summary: Ban user tags: - - Channels - x-stream-docs-page-id: muting_channels + - Users + - Moderation + x-stream-docs-page-id: moderation#ban x-stream-events: - channel.muted: When channel is muted + user.banned: When user is banned x-stream-events-v2: - channel.muted: - description: When channel is muted + user.banned: + description: When user is banned schema: - ref: '#/components/schemas/ChannelMutedEvent' + ref: '#/components/schemas/UserBannedEvent' x-stream-permissions: - MuteChannel: To mute a channel - /moderation/unflag: + BanChannelMember: To ban channel member + BanUser: To ban a user + /moderation/flag: post: description: | - Removes previously created user or message flag + Reports message or user for review by moderators + + Sends events: + - message.flagged + - user.flagged Required permissions: - FlagMessage - FlagUser - operationId: Unflag + operationId: Flag requestBody: content: application/json: @@ -17549,39 +16217,49 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Unflag + summary: Flag tags: - Moderation - Messages - Users - x-stream-deprecated: true x-stream-docs-page-id: moderation#flag + x-stream-events: + message.flagged: When message is flagged + user.flagged: When user is flagged + x-stream-events-v2: + message.flagged: + description: When message is flagged + schema: + ref: '#/components/schemas/MessageFlaggedEvent' + user.flagged: + description: When user is flagged + schema: + ref: '#/components/schemas/UserFlaggedEvent' x-stream-permissions: - FlagMessage: To remove message flag - FlagUser: To remove user flag - /moderation/unmute: - post: + FlagMessage: To flag a message + FlagUser: To flag a user + /moderation/flags/message: + get: description: | - Unmutes previously muted user - - Sends events: - - user.unmuted + Find and filter message flags Required permissions: - - MuteUser - operationId: UnmuteUser - requestBody: - content: + - ReadMessageFlags + operationId: QueryMessageFlags + parameters: + - content: application/json: schema: - $ref: '#/components/schemas/UnmuteUserRequest' - required: true + $ref: '#/components/schemas/QueryMessageFlagsRequest' + x-stream-index: "001" + in: query + name: payload responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/UnmuteResponse' + $ref: '#/components/schemas/QueryMessageFlagsResponse' description: Successful response "400": content: @@ -17608,43 +16286,36 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Unmute user + summary: Query Message Flags tags: - - Users + - Messages - Moderation - x-stream-docs-page-id: moderation#mutes - x-stream-events: - user.unmuted: When user is unmuted - x-stream-events-v2: - user.unmuted: - description: When user is unmuted - schema: - ref: '#/components/schemas/UserUnmutedEvent' + x-stream-docs-page-id: moderation#query-message-flags x-stream-permissions: - MuteUser: To unmute a user - /moderation/unmute/channel: + ReadMessageFlags: To read flagged messages + /moderation/mute: post: description: | - Unmutes channel for user + Mutes one or several users Sends events: - - channel.unmuted + - user.muted Required permissions: - - MuteChannel - operationId: UnmuteChannel + - MuteUser + operationId: MuteUser requestBody: content: application/json: schema: - $ref: '#/components/schemas/UnmuteChannelRequest' + $ref: '#/components/schemas/MuteUserRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/UnmuteResponse' + $ref: '#/components/schemas/MuteUserResponse' description: Successful response "400": content: @@ -17671,82 +16342,43 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Unmute channel + summary: Mute user tags: - - Channels - x-stream-docs-page-id: muting_channels + - Users + - Moderation + x-stream-docs-page-id: moderation#mutes x-stream-events: - channel.unmuted: When channel is unmuted + user.muted: When user is muted x-stream-events-v2: - channel.unmuted: - description: When channel is unmuted + user.muted: + description: When user is muted schema: - ref: '#/components/schemas/ChannelUnmutedEvent' + ref: '#/components/schemas/UserMutedEvent' x-stream-permissions: - MuteChannel: To unmute a channel - /og: - get: + MuteUser: To mute a user + /moderation/mute/channel: + post: description: | - Get an OpenGraph attachment for a link - operationId: GetOG - parameters: - - content: + Mutes channel for user + + Sends events: + - channel.muted + + Required permissions: + - MuteChannel + operationId: MuteChannel + requestBody: + content: application/json: schema: - description: URL to be scraped - title: URL - type: string - writeOnly: true - x-stream-index: "001" - in: query - name: url - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/GetOGResponse' - description: Get OG Attachment - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Bad request - "429": - content: - application/json: - schema: - $ref: '#/components/schemas/APIError' - description: Too many requests - headers: - X-RateLimit-Limit: - description: The number of allowed requests in the current period - schema: - type: integer - X-RateLimit-Remaining: - description: The number of remaining requests in the current period - schema: - type: integer - X-RateLimit-Reset: - description: Timestamp when number of requests will be reset - schema: - type: integer - summary: Get OG - tags: - - Messages - x-stream-docs-page-id: og - /permissions: - get: - description: | - Lists all available permissions - operationId: ListPermissions + $ref: '#/components/schemas/MuteChannelRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/ListPermissionsResponse' + $ref: '#/components/schemas/MuteChannelResponse' description: Successful response "400": content: @@ -17773,33 +16405,40 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: List permissions + summary: Mute channel tags: - - Permissions V2 - x-stream-server-side: true - /permissions/{id}: - get: + - Channels + x-stream-docs-page-id: muting_channels + x-stream-events: + channel.muted: When channel is muted + x-stream-events-v2: + channel.muted: + description: When channel is muted + schema: + ref: '#/components/schemas/ChannelMutedEvent' + x-stream-permissions: + MuteChannel: To mute a channel + /moderation/unflag: + post: description: | - Gets custom permission - operationId: GetPermission - parameters: - - content: + Removes previously created user or message flag + + Required permissions: + - FlagMessage + - FlagUser + operationId: Unflag + requestBody: + content: application/json: schema: - description: Permission ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: id + $ref: '#/components/schemas/FlagRequest' required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/GetCustomPermissionResponse' + $ref: '#/components/schemas/FlagResponse' description: Successful response "400": content: @@ -17826,21 +16465,39 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get permission + summary: Unflag tags: - - Permissions V2 - x-stream-server-side: true - /push_providers: - get: + - Moderation + - Messages + - Users + x-stream-deprecated: true + x-stream-docs-page-id: moderation#flag + x-stream-permissions: + FlagMessage: To remove message flag + FlagUser: To remove user flag + /moderation/unmute: + post: description: | - List details of all push providers. - operationId: ListPushProviders + Unmutes previously muted user + + Sends events: + - user.unmuted + + Required permissions: + - MuteUser + operationId: UnmuteUser + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UnmuteUserRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/ListPushProvidersResponse' + $ref: '#/components/schemas/UnmuteResponse' description: Successful response "400": content: @@ -17867,28 +16524,43 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: List push providers + summary: Unmute user tags: - - Push - - Settings - x-stream-docs-page-id: push - x-stream-server-side: true + - Users + - Moderation + x-stream-docs-page-id: moderation#mutes + x-stream-events: + user.unmuted: When user is unmuted + x-stream-events-v2: + user.unmuted: + description: When user is unmuted + schema: + ref: '#/components/schemas/UserUnmutedEvent' + x-stream-permissions: + MuteUser: To unmute a user + /moderation/unmute/channel: post: description: | - Upsert a push provider for v2 with multi bundle/package support - operationId: UpsertPushProvider + Unmutes channel for user + + Sends events: + - channel.unmuted + + Required permissions: + - MuteChannel + operationId: UnmuteChannel requestBody: content: application/json: schema: - $ref: '#/components/schemas/UpsertPushProviderRequest' + $ref: '#/components/schemas/UnmuteChannelRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/UpsertPushProviderResponse' + $ref: '#/components/schemas/UnmuteResponse' description: Successful response "400": content: @@ -17915,49 +16587,40 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Upsert a push provider + summary: Unmute channel tags: - - Server-side - x-stream-docs-page-id: push - x-stream-server-side: true - /push_providers/{type}/{name}: - delete: + - Channels + x-stream-docs-page-id: muting_channels + x-stream-events: + channel.unmuted: When channel is unmuted + x-stream-events-v2: + channel.unmuted: + description: When channel is unmuted + schema: + ref: '#/components/schemas/ChannelUnmutedEvent' + x-stream-permissions: + MuteChannel: To unmute a channel + /og: + get: description: | - Delete a push provider from v2 with multi bundle/package support. v1 isn't supported in this endpoint - operationId: DeletePushProvider + Get an OpenGraph attachment for a link + operationId: GetOG parameters: - - content: - application/json: - schema: - enum: - - apn - - firebase - - huawei - - xiaomi - type: string - writeOnly: true - x-stream-index: "001" - in: path - name: type - required: true - - content: - application/json: - schema: - maxLength: 36 - minLength: 1 - type: string - writeOnly: true - x-stream-index: "002" - in: path - name: name - required: true + - in: query + name: url + schema: + description: URL to be scraped + title: URL + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/Response' - description: Successful response + $ref: '#/components/schemas/GetOGResponse' + description: Get OG Attachment "400": content: application/json: @@ -17983,34 +16646,21 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete a push provider + summary: Get OG tags: - - Push - - Settings - x-stream-docs-page-id: push - x-stream-server-side: true - /query_banned_users: + - Messages + x-stream-docs-page-id: og + /permissions: get: description: | - Find and filter channel scoped or global user bans - - Required permissions: - - ReadChannel - operationId: QueryBannedUsers - parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QueryBannedUsersRequest' - x-stream-index: "001" - in: query - name: payload + Lists all available permissions + operationId: ListPermissions responses: "200": content: application/json: schema: - $ref: '#/components/schemas/QueryBannedUsersResponse' + $ref: '#/components/schemas/ListPermissionsResponse' description: Successful response "400": content: @@ -18037,77 +16687,32 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query Banned Users + summary: List permissions tags: - - Users - - Moderation - x-stream-docs-page-id: moderation#query-banned-users - x-stream-permissions: - ReadChannel: To read banned users of specified channels - /rate_limits: + - Permissions V2 + x-stream-server-side: true + /permissions/{id}: get: description: | - Get rate limits usage and quotas - operationId: GetRateLimits + Gets custom permission + operationId: GetPermission parameters: - - content: - application/json: - schema: - description: Whether to include server-side platform limits or not - title: Server-side - type: boolean - writeOnly: true - x-stream-index: "001" - in: query - name: server_side - - content: - application/json: - schema: - description: Whether to include Android platform limits or not - title: Android - type: boolean - writeOnly: true - x-stream-index: "002" - in: query - name: android - - content: - application/json: - schema: - description: Whether to include iOS platform limits or not - title: iOS - type: boolean - writeOnly: true - x-stream-index: "003" - in: query - name: ios - - content: - application/json: - schema: - description: Whether to include web platform limits or not - title: Web - type: boolean - writeOnly: true - x-stream-index: "004" - in: query - name: web - - content: - application/json: - schema: - description: Specific endpoints to show limits for, as a comma-separated - list of values - title: Endpoints - type: string - writeOnly: true - x-stream-index: "005" - in: query - name: endpoints + - in: path + name: id + required: true + schema: + description: Permission ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/GetRateLimitsResponse' - description: Get Rate Limits Response + $ref: '#/components/schemas/GetCustomPermissionResponse' + description: Successful response "400": content: application/json: @@ -18133,30 +16738,21 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Get rate limits + summary: Get permission tags: - - Settings - x-stream-docs-page-id: rate_limits + - Permissions V2 x-stream-server-side: true - /recipients: + /push_providers: get: description: | - Query recipients - operationId: QueryRecipients - parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QueryRecipientsRequest' - x-stream-index: "001" - in: query - name: payload + List details of all push providers. + operationId: ListPushProviders responses: "200": content: application/json: schema: - $ref: '#/components/schemas/QueryRecipientsResponse' + $ref: '#/components/schemas/ListPushProvidersResponse' description: Successful response "400": content: @@ -18183,22 +16779,28 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query recipients + summary: List push providers tags: - - Campaigns - x-stream-docs-page-id: campaigns + - Push + - Settings + x-stream-docs-page-id: push x-stream-server-side: true - /roles: - get: + post: description: | - Lists all available roles - operationId: ListRoles + Upsert a push provider for v2 with multi bundle/package support + operationId: UpsertPushProvider + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UpsertPushProviderRequest' + required: true responses: - "200": + "201": content: application/json: schema: - $ref: '#/components/schemas/ListRolesResponse' + $ref: '#/components/schemas/UpsertPushProviderResponse' description: Successful response "400": content: @@ -18225,26 +16827,44 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: List roles + summary: Upsert a push provider tags: - - Permissions V2 + - Server-side + x-stream-docs-page-id: push x-stream-server-side: true - post: + /push_providers/{type}/{name}: + delete: description: | - Creates custom role - operationId: CreateRole - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateRoleRequest' + Delete a push provider from v2 with multi bundle/package support. v1 isn't supported in this endpoint + operationId: DeletePushProvider + parameters: + - in: path + name: type + required: true + schema: + enum: + - apn + - firebase + - huawei + - xiaomi + type: string + writeOnly: true + x-stream-index: "001" + - in: path + name: name required: true + schema: + maxLength: 36 + minLength: 1 + type: string + writeOnly: true + x-stream-index: "002" responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/CreateRoleResponse' + $ref: '#/components/schemas/Response' description: Successful response "400": content: @@ -18271,33 +16891,34 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Create role + summary: Delete a push provider tags: - - Permissions V2 + - Push + - Settings + x-stream-docs-page-id: push x-stream-server-side: true - /roles/{name}: - delete: + /query_banned_users: + get: description: | - Deletes custom role - operationId: DeleteRole + Find and filter channel scoped or global user bans + + Required permissions: + - ReadChannel + operationId: QueryBannedUsers parameters: - content: application/json: schema: - description: Role name - title: Name - type: string - writeOnly: true + $ref: '#/components/schemas/QueryBannedUsersRequest' x-stream-index: "001" - in: path - name: name - required: true + in: query + name: payload responses: "200": content: application/json: schema: - $ref: '#/components/schemas/Response' + $ref: '#/components/schemas/QueryBannedUsersResponse' description: Successful response "400": content: @@ -18324,35 +16945,67 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete role + summary: Query Banned Users tags: - - Permissions V2 - x-stream-server-side: true - /search: + - Users + - Moderation + x-stream-docs-page-id: moderation#query-banned-users + x-stream-permissions: + ReadChannel: To read banned users of specified channels + /rate_limits: get: description: | - Search messages across channels - - Required permissions: - - ReadChannel - operationId: Search + Get rate limits usage and quotas + operationId: GetRateLimits parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/SearchRequest' - description: JSON object with search payload - title: Payload - x-stream-index: "001" - in: query - name: payload + - in: query + name: server_side + schema: + description: Whether to include server-side platform limits or not + title: Server-side + type: boolean + writeOnly: true + x-stream-index: "001" + - in: query + name: android + schema: + description: Whether to include Android platform limits or not + title: Android + type: boolean + writeOnly: true + x-stream-index: "002" + - in: query + name: ios + schema: + description: Whether to include iOS platform limits or not + title: iOS + type: boolean + writeOnly: true + x-stream-index: "003" + - in: query + name: web + schema: + description: Whether to include web platform limits or not + title: Web + type: boolean + writeOnly: true + x-stream-index: "004" + - in: query + name: endpoints + schema: + description: Specific endpoints to show limits for, as a comma-separated + list of values + title: Endpoints + type: string + writeOnly: true + x-stream-index: "005" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/SearchResponse' - description: Successful response + $ref: '#/components/schemas/GetRateLimitsResponse' + description: Get Rate Limits Response "400": content: application/json: @@ -18378,32 +17031,22 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Search messages + summary: Get rate limits tags: - - Channels - - Messages - x-stream-docs-page-id: search - x-stream-permissions: - ReadChannel: To read channels that were found by search - /segments: + - Settings + x-stream-docs-page-id: rate_limits + x-stream-server-side: true + /roles: get: description: | - Query segments - operationId: QuerySegments - parameters: - - content: - application/json: - schema: - $ref: '#/components/schemas/QuerySegmentsRequest' - x-stream-index: "001" - in: query - name: payload + Lists all available roles + operationId: ListRoles responses: "200": content: application/json: schema: - $ref: '#/components/schemas/QuerySegmentsResponse' + $ref: '#/components/schemas/ListRolesResponse' description: Successful response "400": content: @@ -18430,27 +17073,26 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Query segments + summary: List roles tags: - - Campaigns - x-stream-docs-page-id: campaigns + - Permissions V2 x-stream-server-side: true post: description: | - Create a segment - operationId: CreateSegment + Creates custom role + operationId: CreateRole requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateSegmentRequest' + $ref: '#/components/schemas/CreateRoleRequest' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/CreateSegmentResponse' + $ref: '#/components/schemas/CreateRoleResponse' description: Successful response "400": content: @@ -18477,32 +17119,31 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Create segment + summary: Create role tags: - - Campaigns - x-stream-docs-page-id: campaigns + - Permissions V2 x-stream-server-side: true - /segments/{id}: + /roles/{name}: delete: description: | - Delete a segment - operationId: DeleteSegment + Deletes custom role + operationId: DeleteRole parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001.001" - in: path - name: id + - in: path + name: name required: true + schema: + description: Role name + title: Name + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: application/json: schema: - $ref: '#/components/schemas/DeleteSegmentResponse' + $ref: '#/components/schemas/Response' description: Successful response "400": content: @@ -18529,37 +17170,34 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Delete segment + summary: Delete role tags: - - Campaigns - x-stream-docs-page-id: campaigns + - Permissions V2 x-stream-server-side: true - put: + /search: + get: description: | - Update an existing segment - operationId: UpdateSegment + Search messages across channels + + Required permissions: + - ReadChannel + operationId: Search parameters: - content: application/json: schema: - type: string - writeOnly: true - x-stream-index: "002.001" - in: path - name: id - required: true - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateSegmentRequest' - required: true + $ref: '#/components/schemas/SearchRequest' + description: JSON object with search payload + title: Payload + x-stream-index: "001" + in: query + name: payload responses: - "201": + "200": content: application/json: schema: - $ref: '#/components/schemas/UpdateSegmentResponse' + $ref: '#/components/schemas/SearchResponse' description: Successful response "400": content: @@ -18586,11 +17224,13 @@ paths: description: Timestamp when number of requests will be reset schema: type: integer - summary: Update segment + summary: Search messages tags: - - Campaigns - x-stream-docs-page-id: campaigns - x-stream-server-side: true + - Channels + - Messages + x-stream-docs-page-id: search + x-stream-permissions: + ReadChannel: To read channels that were found by search /sync: post: description: | @@ -18600,42 +17240,33 @@ paths: - ReadChannel operationId: Sync parameters: - - content: - application/json: - schema: - description: If set to true this will add 'inaccessible_cids' to response - type - title: With inaccessible CIDs - type: boolean - x-stream-index: "003" - in: query + - in: query name: with_inaccessible_cids - - content: - application/json: - schema: - description: If set to true this will start watching requested and newly - added channels that user has access to. If error occurred with this - option enabled and it is not an input error - channels will still - be watched. - title: Watch synced channels - type: boolean - x-stream-index: "004" - in: query + schema: + description: If set to true this will add 'inaccessible_cids' to response + type + title: With inaccessible CIDs + type: boolean + x-stream-index: "003" + - in: query name: watch - - content: - application/json: - schema: - type: string - x-stream-index: "006.002" - in: query + schema: + description: If set to true this will start watching requested and newly + added channels that user has access to. If error occurred with this option + enabled and it is not an input error - channels will still be watched. + title: Watch synced channels + type: boolean + x-stream-index: "004" + - in: query name: client_id - - content: - application/json: - schema: - type: string - x-stream-index: "006.003" - in: query + schema: + type: string + x-stream-index: "006.002" + - in: query name: connection_id + schema: + type: string + x-stream-index: "006.003" requestBody: content: application/json: @@ -18686,17 +17317,15 @@ paths: Gets status of a task operationId: GetTask parameters: - - content: - application/json: - schema: - description: Task ID - title: ID - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: id required: true + schema: + description: Task ID + title: ID + type: string + writeOnly: true + x-stream-index: "001" responses: "200": content: @@ -18917,43 +17546,35 @@ paths: - user.deleted operationId: DeleteUser parameters: - - content: - application/json: - schema: - description: ID of user to delete - title: User ID - type: string - x-stream-index: "001" - in: path + - in: path name: user_id required: true - - content: - application/json: - schema: - description: Delete user messages - title: Mark messages deleted - type: boolean - x-stream-index: "002" - in: query + schema: + description: ID of user to delete + title: User ID + type: string + x-stream-index: "001" + - in: query name: mark_messages_deleted - - content: - application/json: - schema: - description: Delete all user data (messages, reactions, etc.) - title: Hard delete - type: boolean - x-stream-index: "003" - in: query + schema: + description: Delete user messages + title: Mark messages deleted + type: boolean + x-stream-index: "002" + - in: query name: hard_delete - - content: - application/json: - schema: - description: Delete all one-to-one channels of the user - title: Delete conversations - type: boolean - x-stream-index: "004" - in: query + schema: + description: Delete all user data (messages, reactions, etc.) + title: Hard delete + type: boolean + x-stream-index: "003" + - in: query name: delete_conversation_channels + schema: + description: Delete all one-to-one channels of the user + title: Delete conversations + type: boolean + x-stream-index: "004" responses: "200": content: @@ -19020,15 +17641,13 @@ paths: - user.deactivated operationId: DeactivateUser parameters: - - content: - application/json: - schema: - title: User ID - type: string - x-stream-index: "001" - in: path + - in: path name: user_id required: true + schema: + title: User ID + type: string + x-stream-index: "001" requestBody: content: application/json: @@ -19090,15 +17709,13 @@ paths: - custom operationId: SendUserCustomEvent parameters: - - content: - application/json: - schema: - type: string - writeOnly: true - x-stream-index: "001" - in: path + - in: path name: user_id required: true + schema: + type: string + writeOnly: true + x-stream-index: "001" requestBody: content: application/json: @@ -19155,14 +17772,12 @@ paths: Exports the user's profile, reactions and messages. Raises an error if a user has more than 10k messages or reactions operationId: ExportUser parameters: - - content: - application/json: - schema: - type: string - x-stream-index: "001" - in: path + - in: path name: user_id required: true + schema: + type: string + x-stream-index: "001" responses: "200": content: @@ -19209,15 +17824,13 @@ paths: - user.reactivated operationId: ReactivateUser parameters: - - content: - application/json: - schema: - title: User ID - type: string - x-stream-index: "001" - in: path + - in: path name: user_id required: true + schema: + title: User ID + type: string + x-stream-index: "001" requestBody: content: application/json: