From 128c28706c166997926adb10132fa20c9a7a9bf6 Mon Sep 17 00:00:00 2001 From: Maumau123098 Date: Wed, 10 Sep 2025 21:16:39 -0500 Subject: [PATCH] Delete docs/ios-core directory --- docs/ios-core/chat/_category_.json | 5 - docs/ios-core/chat/introduction.mdx | 25 -- .../ios-core/chat/receiving-chat-messages.mdx | 57 ----- docs/ios-core/chat/sending-a-chat-message.mdx | 46 ---- docs/ios-core/livestream/_category_.json | 5 - .../livestream/dyte-livestream-listener.mdx | 113 --------- .../livestream/dyte-livestream-object.mdx | 73 ------ docs/ios-core/livestream/introduction.mdx | 12 - docs/ios-core/local-user/_category_.json | 5 - docs/ios-core/local-user/events.mdx | 134 ---------- docs/ios-core/local-user/introduction.mdx | 114 --------- .../local-user/manage-media-devices.mdx | 29 --- .../local-user/manage-permissions.mdx | 32 --- docs/ios-core/participants/_category_.json | 5 - docs/ios-core/participants/events.mdx | 123 --------- docs/ios-core/participants/introduction.mdx | 139 ---------- .../participants/participant-object.mdx | 103 -------- docs/ios-core/plugins.mdx | 61 ----- docs/ios-core/polls/_category_.json | 5 - docs/ios-core/polls/creating-a-poll.mdx | 30 --- docs/ios-core/polls/introduction.mdx | 40 --- docs/ios-core/polls/voting-on-a-poll.mdx | 25 -- docs/ios-core/quickstart.mdx | 239 ------------------ docs/ios-core/recording.mdx | 80 ------ docs/ios-core/release-notes.mdx | 10 - docs/ios-core/room/_category_.json | 5 - docs/ios-core/room/room-connection-events.mdx | 102 -------- docs/ios-core/room/room-metadata.mdx | 26 -- docs/ios-core/waitlist-events.mdx | 38 --- docs/ios-core/webinar/_category_.json | 5 - docs/ios-core/webinar/introduction.mdx | 38 --- docs/ios-core/webinar/stage-management.mdx | 105 -------- 32 files changed, 1829 deletions(-) delete mode 100644 docs/ios-core/chat/_category_.json delete mode 100644 docs/ios-core/chat/introduction.mdx delete mode 100644 docs/ios-core/chat/receiving-chat-messages.mdx delete mode 100644 docs/ios-core/chat/sending-a-chat-message.mdx delete mode 100644 docs/ios-core/livestream/_category_.json delete mode 100644 docs/ios-core/livestream/dyte-livestream-listener.mdx delete mode 100644 docs/ios-core/livestream/dyte-livestream-object.mdx delete mode 100644 docs/ios-core/livestream/introduction.mdx delete mode 100644 docs/ios-core/local-user/_category_.json delete mode 100644 docs/ios-core/local-user/events.mdx delete mode 100644 docs/ios-core/local-user/introduction.mdx delete mode 100644 docs/ios-core/local-user/manage-media-devices.mdx delete mode 100644 docs/ios-core/local-user/manage-permissions.mdx delete mode 100644 docs/ios-core/participants/_category_.json delete mode 100644 docs/ios-core/participants/events.mdx delete mode 100644 docs/ios-core/participants/introduction.mdx delete mode 100644 docs/ios-core/participants/participant-object.mdx delete mode 100644 docs/ios-core/plugins.mdx delete mode 100644 docs/ios-core/polls/_category_.json delete mode 100644 docs/ios-core/polls/creating-a-poll.mdx delete mode 100644 docs/ios-core/polls/introduction.mdx delete mode 100644 docs/ios-core/polls/voting-on-a-poll.mdx delete mode 100644 docs/ios-core/quickstart.mdx delete mode 100644 docs/ios-core/recording.mdx delete mode 100644 docs/ios-core/release-notes.mdx delete mode 100644 docs/ios-core/room/_category_.json delete mode 100644 docs/ios-core/room/room-connection-events.mdx delete mode 100644 docs/ios-core/room/room-metadata.mdx delete mode 100644 docs/ios-core/waitlist-events.mdx delete mode 100644 docs/ios-core/webinar/_category_.json delete mode 100644 docs/ios-core/webinar/introduction.mdx delete mode 100644 docs/ios-core/webinar/stage-management.mdx diff --git a/docs/ios-core/chat/_category_.json b/docs/ios-core/chat/_category_.json deleted file mode 100644 index e96d76d691..0000000000 --- a/docs/ios-core/chat/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 6, - "label": "Chat", - "collapsible": true -} diff --git a/docs/ios-core/chat/introduction.mdx b/docs/ios-core/chat/introduction.mdx deleted file mode 100644 index 64e94c26a8..0000000000 --- a/docs/ios-core/chat/introduction.mdx +++ /dev/null @@ -1,25 +0,0 @@ ---- -title: Introducing chat -description: Send and receive chat messages in a meeting. -sidebar_position: 1 -tags: [mobile-core, chat] ---- - -# Introducing chat - -The meeting chat object is stored in `meeting.chat`, which has methods for -sending and receiving messages. There are 3 types of messages that can be sent -in chat - text messages, images, and files. - -The `meeting.chat.messages` array contains all the messages that have been sent -in the chat. This is an array of objects, where each object is of type -`DyteChatMessage`. - -We support three types of chat messages, they are as follows - -- Text Message -- Image Message -- File Message - -All above objects are of type `DyteChatMessage` along with their own class -variables. diff --git a/docs/ios-core/chat/receiving-chat-messages.mdx b/docs/ios-core/chat/receiving-chat-messages.mdx deleted file mode 100644 index 38713566d1..0000000000 --- a/docs/ios-core/chat/receiving-chat-messages.mdx +++ /dev/null @@ -1,57 +0,0 @@ ---- -title: Receiving chat messages -description: Receive chat messages that has been sent in a meeting. -sidebar_position: 3 -tags: [mobile-core, chat] ---- - -# Receiving chat messages - -To be able to receive chat messages you need to implement a method -`onChatUpdates()` method from callback `DyteChatEventsListener`. You can -subscribe to this events by calling -`meeting.addMeetingEventsListener(dyteChatEventsListener)` - -```swift - extension MeetingViewModel: DyteChatEventsListener { - func onChatUpdates(messages: [DyteChatMessage]) { - // any update in chat messages - } - - func onNewChatMessage(message: DyteChatMessage) { - // updates for new chat messages only - } - } -``` - -Here, the `message` is of type `Message`, as defined in -[introduction](./introduction). `messages` is a list of all chat messages in the -meeting, which is the same as `meeting.chat.messages`. - -When a chat message is received, the `meeting.chat.messages` list is also -updated. - -DyteChatMessage has different implementations of it, thus you will need to cast and use appropriate type as follows: - -```swift - func onNewChatMessage(message: DyteChatMessage) { - if let msg = message { - switch msg.type { - case .text: - if let textMsg = msg as? DyteTextMessage { - //print("onNewChatMessage: Text : \(textMsg)") - } - case .file: - if let fileMsg = msg as? DyteFileMessage { - //print("onNewChatMessage: File : \(fileMsg.name)") - } - case .image: - if let imgMsg = msg as? DyteImageMessage { - //print("onNewChatMessage: Image : \(imgMsg.link)") - } - - default: - print("Error! Message type unknown!") - } - } -``` diff --git a/docs/ios-core/chat/sending-a-chat-message.mdx b/docs/ios-core/chat/sending-a-chat-message.mdx deleted file mode 100644 index 9a43b957db..0000000000 --- a/docs/ios-core/chat/sending-a-chat-message.mdx +++ /dev/null @@ -1,46 +0,0 @@ ---- -title: Sending a chat message -description: Send a chat message in a meeting. -sidebar_position: 2 -tags: [mobile-core, chat] ---- - -# Sending a chat message - -As mentioned in [introduction](./introduction), there are 3 types of chat -messages - text messages, images, and files. There is a method in `meeting.chat` -to send a message of each type. - -## Send a text message - -To send a text message, the `meeting.chat.sendTextMessage()` method can be used. -This accepts a string `message` and sends it to the room. - -```swift -let message = "Is this the real life?" -meeting.chat.sendTextMessage(message: message) -``` - -## Send an image - -You can send an image with the help of `meeting.chat.sendImageMessage()` and -sends it to the participants in the meeting. - -```swift -let filePath = "file_path_of_image" -let fileName = "file_name" -meeting.chat.sendImageMessage(filePath: filePath, fileName: fileName) -``` - -## Send a file - -Sending a file is quite similar to sending an image. The only difference is that -when you send an image, a preview will be shown in the meeting chat, which is -not the case for sending files. That being said, an image can be sent as a file -too using `meeting.chat.sendFileMessage()`. - -```swift -let filePath = "file_path_of_image" -let fileName = "file_name" -meeting.chat.sendFileMessage(filePath: filePath, fileName: fileName) -``` diff --git a/docs/ios-core/livestream/_category_.json b/docs/ios-core/livestream/_category_.json deleted file mode 100644 index d03d7d50cd..0000000000 --- a/docs/ios-core/livestream/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 7, - "label": "Livestream", - "collapsible": true -} diff --git a/docs/ios-core/livestream/dyte-livestream-listener.mdx b/docs/ios-core/livestream/dyte-livestream-listener.mdx deleted file mode 100644 index 5e2960957d..0000000000 --- a/docs/ios-core/livestream/dyte-livestream-listener.mdx +++ /dev/null @@ -1,113 +0,0 @@ ---- -title: Livestream event listeners -description: Livestream events to listen to for triggering -sidebar_position: 3 -tags: [mobile-core, livestream] ---- - -You can listen to livestream events by attaching a listener by calling `addLivestreamEventsListener` on `dyteMobileClient` object where `dyteMobileClient` is an instance of `DyteMobileClient()`. - -```swift -extension LivestreamViewController: DyteLiveStreamEventsListener { - public func onJoinRequestAccepted(peer: LiveStreamStagePeer) { - // when localUser's join request is accepted by host - } - - public func onJoinRequestRejected(peer: LiveStreamStagePeer) { - // when localUser's join request is rejected by host - } - - public func onLiveStreamEnded() { - // when livestream is ended - } - - public func onLiveStreamEnding() { - // when livestream is ending - } - - public func onLiveStreamErrored() { - // errored livestream - } - - public func onLiveStreamStarted() { - // when livestream is started - } - - public func onLiveStreamStarting() { - // when livestream is starting - } - - public func onLiveStreamStateUpdate(data: DyteLivestreamData) { - // when there is an update in state of the livestream - } - - public func onStageCountUpdated(count: Int32) { - // when stage count updates in livestream - } - - public func onStageRequestsUpdated(requests: [LiveStreamStageRequestPeer]) { - // when there are updates in stage requests - } - - public func onViewerCountUpdated(count: Int32) { - // when viewer count updates in livestream - } - -} - -meeting.addLiveStreamEventsListener(liveStreamEventsListener: self) -``` - -## Livestream events - -- ### onLiveStreamStarting - - This event is triggered when the livestream is about to start. - -- ### onLiveStreamStarted - - This event is triggered when the livestream has started. - -- ### onLiveStreamStateUpdate - - This event is triggered when the livestream state is updated. - -- ### onViewerCountUpdated - - This event is triggered when the viewer count is updated. - -- ### onLiveStreamEnding - - This event is triggered when the livestream is about to end. - -- ### onLiveStreamEnded - - This event is triggered when the livestream has ended. - -- ### onLiveStreamErrored - - This event is triggered when their is an error while starting/stopping the livestream. - -- ### onStageCountUpdated - - This event is triggered when the number of users on stage is updated. The `count` object contains the updated stage count. - -- ### onStageRequestsUpdated - - This event is triggered when the stage requests are updated. The `requests` object contains the updated list of stage requests. - -- ### onJoinRequestAccepted - - This event is triggered when a stage request is accepted. The `peer` object contains the peer whose request is accepted. - - ```swift - public func onJoinRequestAccepted(peer: LiveStreamStagePeer) {} - ``` - -- ### onJoinRequestRejected - - This event is triggered when a stage request is rejected. The `peer` object contains the peer whose request is rejected. - - ```swift - public func onJoinRequestRejected(peer: LiveStreamStagePeer) {} - ``` diff --git a/docs/ios-core/livestream/dyte-livestream-object.mdx b/docs/ios-core/livestream/dyte-livestream-object.mdx deleted file mode 100644 index 4d06e2d01f..0000000000 --- a/docs/ios-core/livestream/dyte-livestream-object.mdx +++ /dev/null @@ -1,73 +0,0 @@ ---- -title: Livestream objects & methods -description: Livestream object containing all livestream related data and methods. -sidebar_position: 2 -tags: [mobile-core, livestream] ---- - -`DyteLivestream` object obtained by `dyteMobileClient.livestream` method. The objects and methods it contains are defined below. - -## Objects - -### roomName [*String*] - -The name of the room.
- -### state [*LiveStreamState*] - -The current status of the livestream, possible values can be:
- -- `LiveStreamState.NONE` -- `LiveStreamState.STARTING` -- `LiveStreamState.STARTED` -- `LiveStreamState.STOPPING` -- `LiveStreamState.STOPPED` -- `LiveStreamState.ERRORED` - -### stage requests [*_List<DyteLiveStreamStageRequestPeer>_*] - -object accessed via `dyteMobileClient.livestream.stageRequestPeers` contains the list of requests to join the stage. Each request contains 3 properties:
- -1. `peerId`: [*String*] The peerId of the user who requested to join the stage. -2. `userId`: [*String*] The userId of the user who requested to join the stage. -3. `displayName`: [*String*] The display name of the user who requested to join the stage.

- -### liveStreamUrl [*String*] - -List of URL which can be used to consume livestream. - -## **Host Controls Methods** - -Dyte’s stage management APIs allow hosts to receive and manage stage requests as well as leave and join the stage. - -### Accept request - -This method lets the host accept a request to join the stage. It takes the _DyteLiveStreamStageRequestPeer.id_ as an argument whose request has to be accepted. - -```swift -dyteMobileClient.livestream.acceptRequest(peer: peer.id); -``` - -### Reject request - -This method lets the host reject a request to join the stage. It takes the _DyteLiveStreamStageRequestPeer.id_ as an argument whose request has to be rejected. - -```swift -dyteMobileClient.livestream.rejectRequest(peer: peer.id); -``` - -### Accept all requests - -This method lets the host accept all the requests to join the stage. - -```swift -dyteMobileClient.livestream.acceptAll(); -``` - -### Reject all requests - -This method lets the host reject all the requests to join the stage. - -```swift -dyteMobileClient.livestream.rejectAll(); -``` diff --git a/docs/ios-core/livestream/introduction.mdx b/docs/ios-core/livestream/introduction.mdx deleted file mode 100644 index 12a6d88259..0000000000 --- a/docs/ios-core/livestream/introduction.mdx +++ /dev/null @@ -1,12 +0,0 @@ ---- -title: Introduction -description: Control livestreaming in your product. -sidebar_position: 1 -tags: [mobile-core, livestream] ---- - -# Introduction - Livestream - -This section will guide you through the process of integrating the livestreaming feature into your product. Using Dyte's live-streaming state management APIs you can easily manage stage requests, such as leave and join stage, manage permissions, kick participants and so on. - -The foundation of Dyte's livestreaming is based on a stage, which can be accessed by hosts and viewers. While hosts can directly enter the stage, viewers can request to join it. The stage is broadcasted live to all viewers. diff --git a/docs/ios-core/local-user/_category_.json b/docs/ios-core/local-user/_category_.json deleted file mode 100644 index f02d560bef..0000000000 --- a/docs/ios-core/local-user/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 3, - "label": "Local User", - "collapsible": true -} diff --git a/docs/ios-core/local-user/events.mdx b/docs/ios-core/local-user/events.mdx deleted file mode 100644 index 648edb8078..0000000000 --- a/docs/ios-core/local-user/events.mdx +++ /dev/null @@ -1,134 +0,0 @@ ---- -title: Events -description: Local user events guide. -sidebar_position: 2 -tags: [mobile-core, local-user, self] ---- - -# Local User - Events - -You can subscribe to various events on the local user by implementing -`DyteSelfEventsListener` and passing the object to -`meeting.addSelfEventsListener(dyteSelfEventsListener)`. - -### Room joined - -Triggered when the room join event completes and now the meeting is ready to -produce and consume media. - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onRoomJoined() { - //Room Joined - } -} -``` - -### Video update - -Triggered when the user starts / stops the video using `enableVideo` or -`disableVideo` - -```kotlin -extension MeetingViewModel: DyteSelfEventsListener { - func onVideoUpdate(videoEnabled: Bool) { - if (videoEnabled) { - // video is enabled, and other participants in room can see local user - } else { - // video is disabled, and other participants in room can not see local user. - } - } -} -``` - -### Audio update - -Triggered when the user starts / stops the audio using `enableAudio` or -`disableAudio` - -```swift - -extension MeetingViewModel: DyteSelfEventsListener { - func onAudioUpdate(audioEnabled: Bool) { - if (audioEnabled) { - // audio is enabled, and other participants in room can hear local user - } else { - // audio is disabled, and other participants in room can not hear local user. - } - } -} -``` - -### Room disconnected update - -Triggered when the user is disconnected due to media/network errors - -```kotlin -extension MeetingViewModel: DyteSelfEventsListener { - func onMeetingRoomDisconnected() { - //disconnected - } -} -``` - -### Proximity changed - -Triggered when there is any change in proximity. Meaning if device is near ear -piece which triggers display on/off. - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onProximityChanged(isNear: Bool) { - // isNear - // if true, display should be turned off, as user might be speaking through earpiece - // if false, display should be turned on, as user might be looking at display and listening through speaker/earphones. - } -} -``` - -### Waitlist status - -For meetings whose waiting room is enabled: - -To get status of localUser in waiting room we can use - -```swift -let waitListStatus = meeting.localUser.waitListStatus -``` - -Developers can listen to those changes in `onWaitListStatusUpdate()` callbacks - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onWaitListStatusUpdate(waitListStatus: WaitListStatus) { - - } -} -``` - -## Webinar Request - -The `onWebinarPresentRequestReceived()` callback is triggered when the local user receives a request to join the webinar, while the `onStoppedPresenting()` callback is triggered when the local user ends their presentation. - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onWebinarPresentRequestReceived() { - // Display an alert to the user here, allowing them to accept or reject the request. - } - func onStoppedPresenting() { - //Display an alert to the user indicating that they are no longer presenting. - } -} -``` - -## LocalUser removed - -Whenever local user is removed from the meeting, `onRemovedFromMeeting()` callback is triggered. - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onRemovedFromMeeting() { - // Display an alert here that user no longer in the meeting. - } -} -``` diff --git a/docs/ios-core/local-user/introduction.mdx b/docs/ios-core/local-user/introduction.mdx deleted file mode 100644 index 6a5beb25ab..0000000000 --- a/docs/ios-core/local-user/introduction.mdx +++ /dev/null @@ -1,114 +0,0 @@ ---- -title: Introduction -description: Local user setup guide. -sidebar_position: 1 -tags: [mobile-core, local-user, self] ---- - -# Introduction - Local User - -The local user has the methods and properties on the local user media controls. -Accessible via `localUser` within the `meeting` object. - -## Properties - -Here is a list of properties that `meeting.localUser` user provides: - -- `id`: The ID of the participant pertaining to local user. -- `name`: Contains Name of the local user. -- `clientSpecificId`: Identifier provided by the developer while adding the - participant. -- `permissions`: The permissions related to various capabilities within a - meeting context for the local user. -- `audioTrack`: The audio track for the local user. -- `videoTrack`: The video track for the local user. -- `screenShareTrack`: The screen share video tracks for the local user. -- `audioEnabled`: A boolean value indicating if the audio currently enabled. -- `videoEnabled`: A boolean value indicating if the video currently enabled. -- `isScreenShareParticipant`: A boolean value indicating if the participant is a - screen share participant in this meeting. - -## Change default audio / video settings - -By default as soon as you join the meeting the SDK will produce your video and -audio streams. To change this behaviour use the `audioEnabled` & `videoEnabled` -parameter - -```swift -let meetingInfo = DyteMeetingInfo( - roomName = MEETING_ROOM_NAME, - authToken = AUTH_TOKEN, - audioEnabled = false, - videoEnabled = true) -``` - -## Get local user video view - -To show localUser preview inside a view. Use `getSelfPreview()` method on -localUser. This method returns a View which can be added in any View. - -```swift -meeting.localUser.getSelfPreview() -``` - -## Turn audio/video tracks after joining the room - -If audio and video tracks are disabled during the `DyteMobileClient` -initialization process. You can setup the audio and video tracks by simply -calling `enableAudio()` and `enableVideo()` like below: - -```swift -meeting.localUser.enableAudio() -meeting.localUser.enableVideo() -``` - -## Change the name of the local user - -Change the user's name by calling `setDisplayName` method. The changed name will -reflect across all participants ONLY if the change happens before `joinRoom()` -the meeting and after `init()`. - -```swift -meeting.localUser.setDisplayName("New Name") -``` - -## Mute/Unmute microphone - -```kotlin -// Mute Audio -meeting.localUser.disableAudio() - -// Unmute Audio -meeting.localUser.enableAudio() - -// Get current status -meeting.localUser.audioEnabled -``` - -## Enable/Disable camera - -```kotlin -// Disable Video -meeting.localUser.disableVideo() - -// Enable Video -meeting.localUser.enableVideo() - -// Get current status -meeting.localUser.videoEnabled -``` - -## Switch camera between primary and secondary - -```swift -// switch camera -meeting.localUser.switchCamera() -``` - -OR - -If you want to set video device yourself: - -```swift -meeting.localUser.setVideoDevice(videoDevice: DyteVideoDevice) -``` diff --git a/docs/ios-core/local-user/manage-media-devices.mdx b/docs/ios-core/local-user/manage-media-devices.mdx deleted file mode 100644 index 29b0a5a8af..0000000000 --- a/docs/ios-core/local-user/manage-media-devices.mdx +++ /dev/null @@ -1,29 +0,0 @@ ---- -title: Manage Media Devices -description: Local user media guide to manage media permissions. -sidebar_position: 3 -tags: [web-core, local-user, localUser, localUser events] ---- - -# Manage Media Devices - -Media devices represents the hardware for the camera, microphone and speaker -devices. To get the list of media devices that are currently being used, you can -use the following methods: - -```swift -// Get all audio devices -let audioDevices = meeting.localUser.getAudioDevices(); - -// Get all video devices -let videoDevices = meeting.localUser.getVideoDevices(); -``` - -## Set device - -To set a device as an active device, you can call `setDevice` method. This takes -a `MediaDeviceInfo` object, and replaces the same `kind` device. - -```swift -meeting.localUser.setDevice(device); -``` diff --git a/docs/ios-core/local-user/manage-permissions.mdx b/docs/ios-core/local-user/manage-permissions.mdx deleted file mode 100644 index 7e72f13664..0000000000 --- a/docs/ios-core/local-user/manage-permissions.mdx +++ /dev/null @@ -1,32 +0,0 @@ ---- -title: Media Permissions -description: Local user media guide to manage media permissions. -sidebar_position: 4 -tags: [mobile-core, local-user, self, self events] ---- - -# Media Permissions - -To get media permissions (audio/video) for localUser we can do as follows - -```swift -let isCameraPermissionGranted - = meeting.localUser.isCameraPermissionGranted -let isMicrophonePermissionGranted - = meeting.localUser.isMicrophonePermissionGranted -``` - -Similarly to listen to callbacks regarding media permissions once user joins the -meeting - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onMeetingRoomJoinedWithoutCameraPermission() { - // when meeting room is joined without camera permission - } - - func onMeetingRoomJoinedWithoutMicPermission() { - // when meeting room is joined without microphone permission - } -} -``` diff --git a/docs/ios-core/participants/_category_.json b/docs/ios-core/participants/_category_.json deleted file mode 100644 index 5ec4ab7972..0000000000 --- a/docs/ios-core/participants/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 4, - "label": "Participants", - "collapsible": true -} diff --git a/docs/ios-core/participants/events.mdx b/docs/ios-core/participants/events.mdx deleted file mode 100644 index 58c329f57d..0000000000 --- a/docs/ios-core/participants/events.mdx +++ /dev/null @@ -1,123 +0,0 @@ ---- -title: Participant Events -description: Event handling for participants. -sidebar_position: 3 -tags: [mobile-core, participants, self] ---- - -You can subscribe to events for all participants by implementing -`DyteParticipantEventsListener` callback and then passing that object to -`meeting.addParticipantEventsListener(dyteParticipantEventsListener)` method. -Here are the supported methods: - -## Participant joined - -Triggers an event when any participant joins the meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onParticipantJoin(participant: DyteMeetingParticipant) { - // your code here to handle new participant - } - } -``` - -## Participant left - -Triggers an event when any participant leaves the meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onParticipantLeave(participant: DyteMeetingParticipant) { - // your code here to handle participant left from meeting - } - } -``` - -## Screenshare updates - -Triggers an event when there is any change in screenshares in a meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onScreenSharesUpdated() { - // your code here to handle screenshares from meeting - // you can use `meeting.participants.screenshares` to get latest screenshare participants - } - func onScreenShareEnded(participant: DyteMeetingParticipant) { - // your code here to handle screenshare ended - } - - func onScreenShareStarted(participant: DyteMeetingParticipant) { - // your code here to handle screenshare started - } - } -``` - -## Video update - -Trigger an event when any participant starts / stops video. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onVideoUpdate(videoEnabled: Bool, participant: DyteMeetingParticipant) { - // your code here to handle participant video toggle update - } - } -``` - -## Audio update - -Trigger an event when any participant starts / stops audio. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onAudioUpdate(audioEnabled: Bool, participant: DyteMeetingParticipant) { - // your code here to handle participant audio toggle update - } - } -``` - -## Active speaker - -Trigger an event when any is change in active speaker in the meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onActiveSpeakerChanged(participant: DyteMeetingParticipant) { - // your code here to handle active speaker - } - - func onNoActiveSpeaker() { - // your code here to handle no active speaker - } - } -``` - -## Pinned participant - -Trigger an event when any is change in pinned participant in the meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onParticipantPinned(participant: DyteMeetingParticipant) { - // your code here to show pinned participant - } - - func onParticipantUnpinned(participant: DyteMeetingParticipant) { - // your code here to remove pinned participant - } - } -``` - -## Active participants list change - -Triggers an event when any change in active participants list in the meeting. - -```swift - extension MeetingViewModel: DyteParticipantEventsListener { - func onActiveParticipantsChanged(active: [DyteMeetingParticipant]) { - // your code here to refresh active participants - } - } -``` diff --git a/docs/ios-core/participants/introduction.mdx b/docs/ios-core/participants/introduction.mdx deleted file mode 100644 index 9fcbb63b7d..0000000000 --- a/docs/ios-core/participants/introduction.mdx +++ /dev/null @@ -1,139 +0,0 @@ ---- -title: Introduction -description: Events, methods and data pertaining to meeting participants. -sidebar_position: 1 -tags: [mobile-core, participants, participant] ---- - -# Introduction - Room participants - -The data regarding all meeting participants is stored under -`meeting.participants`. Use the methods and events to consume the participants -data. - -## Room participants object. - -- `joined`: A list that contains all the participants who have joined the - meeting. -- `waitlisted`: A list that contains all the participants waiting to join the - meeting. -- `active`: A list that contains all the participants except the local user who - are supposed to be on the screen at the moment -- `pinned`: A nullable participant object. If any participant is pinned is that - participant else it is null. -- `screenshares`: A list that contains all the participants who have shared - screen in the meeting. -- `gridInfo`: This object has all data related to pages in the room. - -Each participant in each of the `joined`, `waitlisted`, `active` and -`screenshares` list is of type `DyteMeetingParticipant`. - -For example, to get all the participants who joined the meeting: - -```swift -// get all joined participants -let joinedParticipants = meeting.participants.joined; -``` - -For example, to get all the active participants in the meeting: - -```swift -// get all active participants -let joinedParticipants = meeting.participants.active; -``` - -Therefore, if you were to make a grid of participants, you'd use the `active` -list, but to display all participants in the meeting you'd use the `joined` -list. - -## Grid info for the room - -Following object can be retrieved from `meeting` object by using -`meeting.participants.gridInfo`. This object will have necessary information -regarding pageCount, next page, previos page, current page, etc. - -```swift - let pageCount: Int - let currentPageNumber: Int - let isNextPagePossible: Bool - let isPreviousPagePossible: Bool - let shouldShowPaginator: Bool - let maxVideoCountPerPage: Int -``` - -## Video update for all participants - -Triggered when the user starts / stops the video using `enableVideo` or -`disableVideo` - -```swift -extension MeetingViewModel: DyteParticipantEventsListener { - func videoUpdate(videoEnabled: Boolean, participant: DyteMeetingParticipant) { - if (videoEnabled) { - // video is enabled, and other participants in room can see local user - } else { - // video is disabled, and other participants in room can not see local user. - } - } -} -``` - -## Audio update for all participants - -Triggered when the user starts / stops the audio using `enableAudio` or -`disableAudio` - -```swift -extension MeetingViewModel: DyteParticipantEventsListener { - func audioUpdate(audioEnabled: Boolean, participant: DyteMeetingParticipant) { - if (audioEnabled) { - // audio is enabled, and other participants in room can hear local user - } else { - // audio is disabled, and other participants in room can not hear local user. - } - } -} -``` - -## Move between pages in paginated mode - -The `setPage(pageNumber: Int)` method allows you to switch between pages of -participants present in the meeting. - -```swift -// switch to 1st page -meeting.participants.setPage(1) -``` - -## Host control methods - -The `meeting.participants` object has host control methods that allow you to -disable the audio and video streams of other users in the meeting (given that -the user preset has the right permissions). - -```swift -// mute all participants -meeting.participants.disableAllAudio() - -// mute a single participant -let participantToUpdate = meeting.participants.joined.first -participantToUpdate.disableAudio() - -// disable video for all participants -meeting.participants.disableAllVideo() - -// disable video for a single participant -let participantToUpdate = meeting.participants.joined.first() -participantToUpdate.disableVideo() -``` - -To remove all participants from a meeting, you can call the `kickAll()` method. - -```swift -// remove all participants from the meeting -meeting.participants.kickAll() - -// remove a single participant -let participantToRemove = meeting.participants.joined.first() -participantToRemove.kick() -``` diff --git a/docs/ios-core/participants/participant-object.mdx b/docs/ios-core/participants/participant-object.mdx deleted file mode 100644 index 31480b03b6..0000000000 --- a/docs/ios-core/participants/participant-object.mdx +++ /dev/null @@ -1,103 +0,0 @@ ---- -title: The participant object -description: The object corresponding to a particular participant. -sidebar_position: 2 -tags: [mobile-core, participants, participant] ---- - -# The participant object - -The `participant` object consists of all the information related to a particular -participant. For instance, it contains a participants video/audio/screenshare -stream, and the participant's name. It also contains state variables that -indicate whether a participant's camera is on or off, and whether they are muted -or unmuted. - -The participant object has the following properties. - -- `id`: The `participantId` of the participant (aka `peerId`). -- `userId`: The `userId` of the participant. -- `name`: The participant's name. -- `picture`: The participant's picture (if any). -- `clientSpecificId`: An arbitrary ID that can be set to identify the - participant. -- `videoTrack`: The video track of the participant. -- `screenShareTrack`: The video and audio (if any) track of the participant's - screen share stream. -- `videoEnabled`: Set to true if the participant's camera is on. -- `audioEnabled`: Set to true if the participant is unmuted. -- `isPinned`: True if current user is pinned in the meeting room -- `presetName`: Name of the preset associated with the participant. - -## To get Video view of a given participant - -You can call `participant.getVideoView()` which will return a View which further -can used to add in any View. - -Similarly one can use `participant.getScreenShareView()` which will return a -View which further can used to add in any View. - -## Audio/Video updates for participant - -You can listen to audio/video changes for a single participant by calling -`addParticipantUpdateListener(listener: DyteParticipantUpdateListener)` on any -participant object. - -```swift -dyteParticipant.addParticipantUpdateListener(participantUpdateListener: self) - -extension MeetingViewModel: DyteParticipantUpdateListener { - func onAudioUpdate(participant: DyteMeetingParticipant, isEnabled: Bool) { - // on audio update - } - - func onVideoUpdate(participant: DyteMeetingParticipant, isEnabled: Bool) { - // on video update - } - - func onPinned(participant: DyteMeetingParticipant) { - // when participant is pinned - } - - func onUnpinned(participant: DyteMeetingParticipant) { - // when participant is un-pinned - } - - func onScreenShareStarted(participant: DyteMeetingParticipant) { - // when participant start to screenshare - } - - func onScreenShareEnded(participant: DyteMeetingParticipant) { - // when participant stops screenshare - } -} -``` - -Also make sure to remove event listener when they are no longer used. You can -remove DyteParticipantUpdateListener by calling -`removeParticipantUpdateListener(listener)` - -## Host controls methods - -If you (the local user) have the relevant permissions in the meeting, you can -disable a participant's video/audio streams, or even remove them from the -meeting. - -```swift -let participant = meeting.participants.joined.first - -// To disable a participant's video stream -participant.disableVideo() - -// To disable a participant's audio stream -participant.disableAudio() - -// To kick a participant from the meeting -participant.kick() - -// to pin a participant in a meeting -participant.pin() - -// to retrieve if current participant is already pinned in a meeting -participant.isPinned -``` diff --git a/docs/ios-core/plugins.mdx b/docs/ios-core/plugins.mdx deleted file mode 100644 index 8685dbb3d8..0000000000 --- a/docs/ios-core/plugins.mdx +++ /dev/null @@ -1,61 +0,0 @@ ---- -title: Plugins -description: Interact with plugins in a meeting. -sidebar_position: 8 -tags: [mobile-core, plugins] ---- - -# Plugins - -The meetings plugins can be accessed using `meeting.plugins`. It provides two -main objects, `all` which contains list of all Plugin objects in a -`DyteMeeting`. And `active` list which contains plugins which are enabled and -are currently being used in this meeting. - -## Playing with plugins - -Plugins are webviews which can be added in any view. To be able to get webview -from DytePlugin one needs to first acivate a plugin. To do that all we need to -do is call `plugin.active()` which will trigger a callback in -`onPluginActivated()`. Similarly to deactivate a plugin one can call -`plugin.deactivate()` and that plugin will be deactivated in the meeting. - -```swift -plugin.activate() // to activate a plugin -plugin.deactivate() // to deactivate a plugin -``` - -## Active plugin - -To check if a `plugin` is active or not in a meeting one can use - -```swift -let isActive = plugin.isActive -``` - -## Listening to plugins in a meeting - -To be able to listen to plugin events you need to implement a methods from -callback `DytePluginEventsListener`. You can subscribe to these events by calling -`meeting.addPluginEventsListener(dytePluginEventsListener: listener)` - -```swift -extension MeetingViewModel: DytePluginEventsListener { - - func onPluginActivated(plugin: DytePlugin) { - // your code to handle plugin activation - } - - func onPluginDeactivated(plugin: DytePlugin) { - // your code to handle plugin de-activation - } - - func onPluginFileRequest(plugin: DytePlugin) { - // your code to handle plugin file request - } - - func onPluginMessage(message: [String : Kotlinx_serialization_jsonJsonElement]) { - // your code to handle plugin message - } -} -``` diff --git a/docs/ios-core/polls/_category_.json b/docs/ios-core/polls/_category_.json deleted file mode 100644 index 3d3e19b415..0000000000 --- a/docs/ios-core/polls/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 7, - "label": "Polls", - "collapsible": true -} diff --git a/docs/ios-core/polls/creating-a-poll.mdx b/docs/ios-core/polls/creating-a-poll.mdx deleted file mode 100644 index a74bd94dc4..0000000000 --- a/docs/ios-core/polls/creating-a-poll.mdx +++ /dev/null @@ -1,30 +0,0 @@ ---- -title: Creating a poll -description: Create polls in a meeting. -sidebar_position: 2 -tags: [mobile-core, polls, create] ---- - -# Creating a poll - -A new poll can be created using the `create` method from the -[`meeting.polls`](./introduction) object. The `meeting.polls.create()` method -accepts the following params. - -| Param | Type | Default Value | Required | Description | -| --------- | -------- | ------------- | -------- | ------------------------------------------ | -| question | string | - | yes | The question that is to be voted for. | -| options | string[] | - | yes | The options of the poll. | -| anonymous | boolean | - | no | If true, the poll votes are anonymous. | -| hideVotes | boolean | - | no | If true, the votes on the poll are hidden. | - -The following snippet creates a poll where votes are anonymous. - -```swift -meeting.polls.create( - question: "Are you an early bird or a night owl?", - options: ["Early bird", "Night owl"], - anonymous: true, - hideVotes: false -) -``` diff --git a/docs/ios-core/polls/introduction.mdx b/docs/ios-core/polls/introduction.mdx deleted file mode 100644 index 020243c676..0000000000 --- a/docs/ios-core/polls/introduction.mdx +++ /dev/null @@ -1,40 +0,0 @@ ---- -title: Introduction -description: Create, receive and interact with polls in a meeting. -sidebar_position: 1 -tags: [mobile-core, polls] ---- - -# Introduction - -The meetings polls object can be accessed using `meeting.polls`. It provides -methods to create polls, vote, and more. - -`meeting.polls.polls` returns an array of all polls created in a meeting, where -each element is an object of type `DytePollMessage`. - -The type `DytePollMessage` is the main class for any poll in Dyte. It also -contains list of `DytePollOption` which are options for a given poll. And every -`DytePollOption` has list of votes inside of it. Votes are objects of class -`DytePollVote` which internally has id and name of the vote. - -One can easily create, vote and view polls by listening to callbacks on -`meeting` object. - -## Listening to new polls in a meeting - -To receive new poll messages, you must implement the `onPollUpdates()` method from -the callback DytePollEventsListener. You can subscribe to this event by -using the `meeting.addMeetingEventsListener(dytePollEventsListener)` method. - -```swift - extension MeetingViewModel: DytePollEventsListener { - func onNewPoll(poll: DytePollMessage) { - // code to handle new poll - } - - func onPollUpdates(pollMessages: [DytePollMessage]) { - // code to handle polls and their vote updates - } - } -``` diff --git a/docs/ios-core/polls/voting-on-a-poll.mdx b/docs/ios-core/polls/voting-on-a-poll.mdx deleted file mode 100644 index 03a59c6a1f..0000000000 --- a/docs/ios-core/polls/voting-on-a-poll.mdx +++ /dev/null @@ -1,25 +0,0 @@ ---- -title: Voting on a poll -description: Voting on polls in a meeting. -sidebar_position: 3 -tags: [mobile-core, polls, votes] ---- - -# Voting on a poll - -The `meeting.polls.vote()` method can be used to register a vote on a poll. It -accepts the following params. - -| Param | Type | Default Value | Required | Description | -| ----- | ------ | ------------- | -------- | ------------------------------------------ | -| id | string | - | yes | The ID of the poll that is to be voted on. | -| index | number | - | yes | The index of the option. | - -The following snippet votes for the 1st option on the 1st poll created in the -meeting. - -```swift -let poll = meeting.polls.items.first -let selectedPollOption = poll.options.first -meeting.polls.vote(pollMessage: poll, pollOption: selectedPollOption) -``` diff --git a/docs/ios-core/quickstart.mdx b/docs/ios-core/quickstart.mdx deleted file mode 100644 index 6b95135a83..0000000000 --- a/docs/ios-core/quickstart.mdx +++ /dev/null @@ -1,239 +0,0 @@ ---- -title: Quickstart -description: Quickstart guide for iOS mobile core. -sidebar_position: 1 -tags: [mobile-core, quickstart] -slug: / ---- - -import { CocoaPodInstallation } from '@site/src/components/LatestInstallation'; - -# iOS Core SDK Quickstart - -This quickstart shows how to use Dyte's iOS Core SDK to add live video and audio -to your iOS applications. - -For getting started quickly, you can use our -[sample code](https://github.com/dyte-io/mobile-core-sample-ios). You can clone -and run a sample application from the -[iOS Core SDK GitHub repository](https://github.com/dyte-io/mobile-core-sample-ios). - -## Objective - -You’ll learn how to: - -- Install the Dyte SDK -- Initialize the SDK -- Configure a Dyte meeting -- Initialize the Dyte meeting -- Go live with your Dyte meeting! - -## Before Getting Started - -- Make sure you've read the - [Getting Started with Dyte](https://docs.dyte.io/getting-started) topic and - completed the steps in the - [Integrate Dyte](https://docs.dyte.io/getting-started#integrate-dyte) section. - You must complete the following steps: - - Create a [Dyte Developer Account](https://dev.dyte.io/) - - Create [Presets](https://dev.dyte.io/roles-presets) - - Create a - [Dyte Meeting](https://docs.dyte.io/api/?v=v2#/operations/create_meeting) - - [Add Participant](https://docs.dyte.io/api/?v=v2#/operations/add_participant) - to the meeting -- Install - [Xcode](https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwin55bqodH8AhUVQXwKHaR-DAsQFnoECA0QAQ&url=https%3A%2F%2Fapps.apple.com%2Fus%2Fapp%2Fxcode%2Fid497799835%3Fmt%3D12&usg=AOvVaw2fEvMbfRtGhB4SPHYB54NX) -- Ensure that Rosetta is installed with Xcode on Mac computers with Apple - silicon. -- Make sure your Mac computers are running macOS version 12.0 Monterey or - higher. - -## Step 1: Install the SDK - -import Tabs from '@theme/Tabs'; -import TabItem from '@theme/TabItem'; - -1. Set your platform to iOS 13.0 or above in your Podfile. - -```ruby -platform :ios, '13.0' -``` - -2. Add 'DyteiOSCore' to your Podfile. - - - -3. Install the client SDK from pod. - -```shell -pod install -``` - -4. Add the following entries to the info.plist file. This gives permission to - your app to access the camera and microphone, access photos, install the - required fonts and icons. - -```xml -NSBluetoothPeripheralUsageDescription -We will use your Bluetooth to access your Bluetooth headphones. -NSBluetoothAlwaysUsageDescription -We will use your Bluetooth to access your Bluetooth headphones. -NSCameraUsageDescription -For people to see you during meetings, we need access to your camera. -NSMicrophoneUsageDescription -For people to hear you during meetings, we need access to your microphone. -NSPhotoLibraryUsageDescription -For people to share, we need access to your photos. -UIBackgroundModes - - audio - voip - fetch - remote-notification - -``` - -The `UIBackgroundModes` key is used in the `Info.plist` file of an iOS app to declare the app’s supported background execution modes. This key is an array of strings that specifies the types of background tasks that the app supports. By declaring the background modes, the app can continue to run in the background and perform specific tasks even when it is not in the foreground. -It’s important to note that the use of background modes should be justified and comply with Apple’s App Store Review Guidelines. Apps that misuse background modes or unnecessarily run in the background may be rejected during the app review process. - -Sources: Apple Developer Documentation: [Declaring Your App’s Supported Background Tasks](https://developer.apple.com/documentation/bundleresources/information_property_list/uibackgroundmodes) - -## Step 2: Initialize the SDK - -1. The `DyteMobileClient` is the main class of the SDK. It is the main entry - point of the SDK. It is the only class that you need to instantiate in order - to use the SDK. To instantiate DyteMobileClient, you should use - `DyteiOSClientBuilder().build()`. - -```swift -let meeting = DyteiOSClientBuilder().build() -``` - -2. Add listeners and implement callback stubs. - -```swift -meeting.addMeetingRoomEventsListener(meetingRoomEventsListener: self) -meeting.addParticipantEventsListener(participantEventsListener: self) -meeting.addSelfEventsListener(selfEventsListener: self) -meeting.addParticipantEventsListener(participantEventsListener: self) -meeting.addChatEventsListener(chatEventsListener: self) -meeting.addPollEventsListener(pollEventsListener: self) -meeting.addRecordingEventsListener(recordingEventsListener: self) -meeting.addWaitlistEventListener(waitlistEventListener: self) -meeting.addLiveStreamEventsListener(liveStreamEventsListener: self) -``` - -## Step 3: Set the properties in the DyteMeetingInfo class - -Add `authToken` that you got from the REST API to constructor of DyteMeetingInfoV2 - [Add Participant API](https://docs.dyte.io/api#/operations/addParticipant) - -| Name | Description | -| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `authToken` | Token from [Add Participant API](https://docs.dyte.io/api?v=v2#/operations/add_participant)
(The presetName created earlier
must be passed in the body
of the Add Participant API request)
The API response contains the `authToken`. | - -```swift -let meetingInfo = DyteMeetingInfoV2(authToken: authToken, - enableAudio: true, - enableVideo: true, - baseUrl: Constants.BASE_URL) -``` - -## Step 4: Initialize the connection request - -To initialize the connection request, call the `doInit()` method obtained on -`meeting` with the `meetingInfo` argument. This will establish the connection -with the Dyte meeting server. - -```swift -meeting.doInit(dyteMeetingInfo_: meetingInfo) -``` -Note: This is the asynchronous method, You will have to attached observer (meeting.addMeetingRoomEventsListener(meetingRoomEventsListener: self) -) to know its completion state, success or failure, Listen to below callbacks of 'DyteMeetingRoomEventsListener'. - - -```swift -func onMeetingInitCompleted() { - } - -func onMeetingInitFailed(exception: KotlinException) { - } -``` - -OR - -To initialize the connection request, call the `doInit(dyteMeetingInfo: DyteMeetingInfoV2, onInitCompleted: () -> Void, onInitFailed_: () -> Void)` method -which is asynchronous and callback based. - -## Step 5: Connect to the meeting - -Now, you have established the connection with the Dyte meeting server -successfully. Once `onMeetingInitCompleted()` is triggered, next step is to join -the room. - -### Join the room - -To join the meeting room, do the following only after you received the doInit completion callbacks. - -```swift -func onMeetingInitCompleted() { - meeting.joinRoom() - } -``` - -Or - -```swift - meeting.doInit(dyteMeetingInfo: meetingInfo) { - self.meeting.joinRoom { - print("Room Joined successfully") - } onRoomJoinFailed: { - print("Room Joined failed") - } - } onInitFailed_: { - print("Meeting Initialisation got failed") - } -``` - -Join room event listeners: Once you call `joinRoom()`, you can listen to -callbacks for this action on meeting object if you have done -`meeting.addSelfEventsListener(selfEventsListener: self)`. - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onMeetingRoomJoinStarted() { - // meeting join started - } - - func onMeetingRoomJoined() { - // meeting room joined successfully - } - - func onMeetingRoomJoinFailed(exception: KotlinException) { - // error in joining meeting room. - } -} -``` - -### Leave the room - -Once the meeting is over, you can leave the meeting room. To leave the meeting -call `leaveRoom()` on `meeting` object. - -```swift -meeting.leaveRoom() -``` - -Leave room event listeners: You can listen to `leaveRoom()` callbacks by -registering obsever on meeting object as follows: - -```swift -extension MeetingViewModel: DyteSelfEventsListener { - func onMeetingRoomLeaveStarted() { - // meeting room leave started - } - - func onMeetingRoomLeft() { - // meeting room leave completed - } -} -``` diff --git a/docs/ios-core/recording.mdx b/docs/ios-core/recording.mdx deleted file mode 100644 index 14b8ab6808..0000000000 --- a/docs/ios-core/recording.mdx +++ /dev/null @@ -1,80 +0,0 @@ ---- -title: Recording -description: Control recordings in a meeting. -sidebar_position: 9 -tags: [mobile-core, recording] ---- - -# Recording - -The `meeting.recording` object can be used start and stop recordings in a -meeting. You can also get the current status of a recording using this API. - -The `meeting.recording` object has the following properties: - -- `recordingState`: Indicates the current recording state of the meeting. - -## Start a recording - -To start a recording, you can call the `start` method in the `meeting.recording` -object. The valid states are `IDLE`, `STARTING`, `RECORDING`, and `STOPPING`. - -```swift -meeting.recording.start() -``` - -## Stop a recording - -Call `meeting.recording.stop()` to stop the active recording. - -```swift -meeting.recording.stop() -``` - -## Pause a recording - -Call `meeting.recording.pause()` to pause the active recording. - -```swift -meeting.recording.pause(); -``` - -## Resume a paused recording - -Call `meeting.recording.resume()` to resume the paused recording. - -```swift -meeting.recording.resume(); -``` - -## Get active recording state - -The `meeting.recording.recordingState` property describes the current state of -the recording. The valid states are `IDLE`, `STARTING`, `RECORDING`, and -`STOPPING`. - -## Listening to recording events in a meeting - -To receive recording events, you must implement methods from `DyteRecordingEventsListener`. -You can subscribe to these events by using the `meeting.addRecordingEventsListener(dyteRecordingEventsListener: listener)` method. - -```swift -extension MeetingViewModel: DyteRecordingEventsListener { - - func onMeetingRecordingEnded() { - // your code to handle recording end - } - - func onMeetingRecordingStarted() { - // your code to handle recording start - } - - func onMeetingRecordingStateUpdated(state: DyteRecordingState) { - // your code to handle recording state update - } - - func onMeetingRecordingStopError(e: KotlinException) { - // your code to handle recording stop error - } -} -``` diff --git a/docs/ios-core/release-notes.mdx b/docs/ios-core/release-notes.mdx deleted file mode 100644 index 3ec694bb7e..0000000000 --- a/docs/ios-core/release-notes.mdx +++ /dev/null @@ -1,10 +0,0 @@ ---- -title: Release Notes -sidebar_position: 101 -sidebar_class_name: releaseSidebarHeading -tags: [mobile-core, releasenotes] ---- - -import ReleaseNotesGenerator from '@site/src/components/ReleaseNotesGenerator'; - - diff --git a/docs/ios-core/room/_category_.json b/docs/ios-core/room/_category_.json deleted file mode 100644 index 5c77ad4b75..0000000000 --- a/docs/ios-core/room/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 5, - "label": "Room", - "collapsible": true -} diff --git a/docs/ios-core/room/room-connection-events.mdx b/docs/ios-core/room/room-connection-events.mdx deleted file mode 100644 index ce49139b8a..0000000000 --- a/docs/ios-core/room/room-connection-events.mdx +++ /dev/null @@ -1,102 +0,0 @@ ---- -title: Room Connection Events -description: Room connection events guide. -sidebar_position: 2 -tags: [mobile-core, ios-core, connection events, reconnection] ---- - -# Room Connection Events - -The `meeting` object emits various events to indicate changes in the connection status of the room. When a connection is lost, -the Dyte SDK detects it and attempts to reconnect the user to the meeting room automatically. - -You can subscribe to these events by implementing the `DyteMeetingRoomEventsListener` callbacks and passing the object to -the `meeting.addMeetingRoomEventsListener(dyteMeetingRoomEventsListener)`. - -The following are the room connection events: - -### Connecting to room - -When the local user starts connecting to the meeting room during initialization, this event is triggered. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onConnectingToMeetingRoom() { - - } -} -``` - -### Connected to room - -When the local user connects to the meeting room after initialization, this event is triggered. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onConnectedToMeetingRoom() { - - } -} -``` - -### Disconnected from room - -When the local user disconnects while leaving the meeting room, this event is triggered. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onDisconnectedFromMeetingRoom() { - - } -} -``` - -### Reconnecting to room - -When the Dyte SDK detects a connection drop and attempts to reconnect to the meeting room, this event is triggered. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onReconnectingToMeetingRoom() { - - } -} -``` - -### Reconnected to room - -When the local user successfully reconnects to the meeting room, this event is triggered. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onReconnectedToMeetingRoom() { - - } -} -``` - -### Room connection failed - -When the local user fails to connect to the meeting room during initialization, this event is triggered. This might occur -because of internet connection issues. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onMeetingRoomConnectionFailed() { - - } -} -``` - -### Room reconnection failed - -When the local user fails to reconnect to the meeting room, this event is triggered. This occurs when the local user's -internet connection goes down for an extended period of time and the Dyte SDK is unable to reconnect despite multiple attempts. - -```swift -extension DyteEventSelfListner: DyteMeetingRoomEventsListener { - func onMeetingRoomReconnectionFailed() { - - } -} -``` diff --git a/docs/ios-core/room/room-metadata.mdx b/docs/ios-core/room/room-metadata.mdx deleted file mode 100644 index 68aaa12088..0000000000 --- a/docs/ios-core/room/room-metadata.mdx +++ /dev/null @@ -1,26 +0,0 @@ ---- -title: Room Metadata -description: All metadata pertaining to a meeting. -sidebar_position: 1 -tags: [mobile-core, room-metadata] ---- - -# Room Metadata - -All metadata pertaining to a meeting is stored in `meeting.meta`. This includes: - -- `roomName`: The name of the room the current participant is connected to. -- `roomType`: Indicates the meeting is a group-call or a webinar. -- `meetingTitle`: The title of the meeting. -- `meetingStartedTimestamp`: The timestamp when the meeting started. - -For example, if you want to get the name of the room the current participant is -connected to, you can do so by doing: - -```swift -let roomName = meeting.meta.roomName - -if meeting.localUser.roomJoined { - print("The local user has joined room \(roomName).") -} -``` diff --git a/docs/ios-core/waitlist-events.mdx b/docs/ios-core/waitlist-events.mdx deleted file mode 100644 index 13d9e66ff9..0000000000 --- a/docs/ios-core/waitlist-events.mdx +++ /dev/null @@ -1,38 +0,0 @@ ---- -title: Waitlist Events -description: Waitlist Events Listener -sidebar_position: 10 -tags: [mobile-core, waitlist] ---- - -### Waitlist Events Listener - -To listen for waitlisting events, implement `DyteWaitlistEventsListener` on the `meeting` object. - -```swift -meeting.addWaitlistEventListener(waitlistEventListener: self) -``` - -When registered, callbacks can be observed as follows: - -```swift - -extension MeetingViewModel: DyteWaitlistEventsListener { - - func onWaitListParticipantJoined(participant: DyteMeetingParticipant) { - // triggered when waitList peer is joined - } - - func onWaitListParticipantAccepted(participant: DyteMeetingParticipant) { - // triggered when waitListed peer is accepted by host - } - - func onWaitListParticipantRejected(participant: DyteMeetingParticipant) { - // triggered when entry of waitListed peer declined by host - } - - func onWaitListParticipantClosed(participant: DyteMeetingParticipant) { - // triggered when waitListed peer get's disconnected - } -} -``` diff --git a/docs/ios-core/webinar/_category_.json b/docs/ios-core/webinar/_category_.json deleted file mode 100644 index ad471a6505..0000000000 --- a/docs/ios-core/webinar/_category_.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "position": 8, - "label": "Webinar", - "collapsible": true -} diff --git a/docs/ios-core/webinar/introduction.mdx b/docs/ios-core/webinar/introduction.mdx deleted file mode 100644 index 1a400fa121..0000000000 --- a/docs/ios-core/webinar/introduction.mdx +++ /dev/null @@ -1,38 +0,0 @@ ---- -title: Join and Leave Stage using Dyte's Webinar Platform -description: Conduct webinar meetings with fine level of access controls. -sidebar_position: 1 -tags: [mobile-core, webinar] ---- - -# Join and Leave Stage using Dyte's Webinar Platform - -This topic provides a comprehensive guide on performing stage management and participant control within Dyte's webinar platform. - -In Dyte, the webinar object, is accessible through the `meeting.webinar` property. This provides a range of methods to efficiently manage the stage and participants during webinar sessions, such as joining and leaving the stage, as well as access control for participants. Additionally, you can also retrieve the list of viewers who have joined the webinar from the `meeting.webinar.viewers` array, and monitor participant requests to join the stage through the `meeting.webinar.requestedParticipants` array. - -## Join stage - -To join the stage in a webinar, specific permissions are required, which are managed through `Presets`. To determine if you have the necessary permissions, use the following command: - -```swift -meeting.webinar.canJoinStage() -``` - -Once you have the permissions to join the stage, you can start presenting in the webinar. There are two distinct flows for this process. - -Participants with the media preset set to "Allowed" can join the stage directly without needing the host to accept their request. However, participants with the media preset set to "Need to Request" must wait for the host to approve their request. Once the host grants permission, these participants can start producing media. - -To join the stage, use the following function: - -```swift -meeting.webinar.joinStage() -``` - -## Leave stage - -To leave the stage, use the following function: - -```swift -meeting.webinar.leaveStage() -``` diff --git a/docs/ios-core/webinar/stage-management.mdx b/docs/ios-core/webinar/stage-management.mdx deleted file mode 100644 index 9be8248b99..0000000000 --- a/docs/ios-core/webinar/stage-management.mdx +++ /dev/null @@ -1,105 +0,0 @@ ---- -title: Manage Stage in Dyte's Webinar -description: Manage the stage as per your convinience. -sidebar_position: 3 -tags: [mobile-core, webinar] ---- - -# Manage Stage in Dyte's Webinar - -In the webinar, both hosts and participants have the ability to manage the stage. This allows for seamless control and organization of the webinar session. - -## Host stage management - -In Dyte's webinar platform, hosts have the capability to request participants to join the stage. When a host sends a request to a participant, the participant will receive a callback in the `DyteWebinarEventsListener#onPresentRequestReceived()` method. The participant can then choose to accept or decline the request using specific functions. - -```swift -extension MeetingViewModel: DyteWebinarEventsListener { - ... - func onPresentRequestReceived() { - // when host requests this user to join stage. Here one should give choice to either accept the request or decline it. - } - ... -} -meeting.addWebinarEventsListener(webinarEventsListener: meetingModel) -``` - -To accept the request and join the stage, participants can utilize the following command: - -```swift -meeting.webinar.acceptRequestToPresent() -``` - -Alternatively, if participants wish to decline the request and not join the stage, use the following command: - -```swift -meeting.webinar.rejectRequestToPresent() -``` - -## Participant stage management - -Participants with the "Accept requests" setting enabled in the Preset can manage the stage in the webinar. - -### Access the list of requests - -To access the list of requests received to join the stage, you can utilize the `meeting.webinar.requestedParticipants` API. This provides you with the necessary information about the participants who have requested to join the stage. - -```swift -meeting.webinar.requestedParticipants -``` - -### Listen to the incoming requests - -Once you are in the meeting, you can register a listener in the meeting object to listen for incoming requests. - -```swift -extension MeetingViewModel: DyteWebinarEventsListener { - func onAddedToStage() { - // when this user is joined to stage - } - func onPresentRequestClosed(participant: RequestToPresentParticipant) { - // when a user who was trying to join stage leaves the call. - } - func onPresentRequestReceived() { - // when host requests this user to join stage. Here one should give choice to either accept the request or decline it. - } - func onPresentRequestAccepted(participant: RequestToPresentParticipant) { - // when a join stage request is accepted by host - } - func onPresentRequestAdded(participant: RequestToPresentParticipant) { - // when a user is requesting to join the stage - } - func onPresentRequestRejected(participant: RequestToPresentParticipant) { - // when a join stage request is denied by host - } - func onPresentRequestWithdrawn(participant: RequestToPresentParticipant) { - // when a user who was trying to join stage withdraws their request to join. - } - func onRemovedFromStage() { - // when this user is no longer on stage - } -} -meeting.addWebinarEventsListener(webinarEventsListener: meetingModel) -``` - -### Accept stage requests - -To accept a request to join the stage, call the following function, where `id` represents the unique identifier of the request. - -```swift -meeting.webinar.acceptRequest(id) -meeting.webinar.acceptAllRequest() -``` - -### Reject a request - -To reject a request, call the following function: - -```swift -meeting.webinar.rejectRequest(id) -meeting.webinar.rejectAllRequest() -``` - -:::note -It's important to note that if a participant doesn't have the permission to perform these operations, the SDK will throw an `UnsupportedOperationException` -:::