Integration SDK
Prepare Environment
Before starting to integrate ZEGO Express SDK, please ensure the development environment meets the following requirements:
- Xcode 15.0 or above.
- macOS device with macOS 10.13 or above.
- macOS device is connected to the Internet.
Integration SDK
(Optional) Create New Project
-
Launch Xcode, click "Create a new Xcode project" in the "Welcome to Xcode" window, or select the "File > New > Project" menu.
-
In the form that appears, select the macOS platform, and select "App" under "Application".

-
Fill out the form and select various options to configure the project. After completion, click "Next".
WarningMust provide "Product Name" and "Organization Identifier", which are used to create the App's unique identifier "Bundle Identifier".

-
Select the project storage path and click "Create" to create the project.

Import SDK
Developers can achieve SDK integration through any of the following methods.
Method 1: Automatic Integration Using CocoaPods
-
Install CocoaPods. If you encounter problems during installation, please refer to CocoaPods Common Questions - Installing CocoaPods.
-
Open Terminal, navigate to the project root directory, and run the
pod initcommand to create a Podfile file. -
Open the Podfile file and add
pod 'ZegoExpressEngine-macOS'under "target". You need to replace "MyProject" with your Target name.Warning- Since the SDK is an XCFramework, CocoaPods v1.10.0 or above is required to integrate this SDK.
- Starting from version v3.2.0, the Pod name of Express Real-time Audio/Video Video SDK changed from
ZegoExpressEngine/VideotoZegoExpressEngine-macOS; the Pod name of Express Real-time Audio Audio SDK changed fromZegoExpressEngine/AudiotoZegoExpressAudio-macOS.
target 'MyProject' do use_frameworks! # Please fill in the specific SDK version number # Please check the latest SDK version from the release notes and modify x.y.z to the specific version number pod 'ZegoExpressEngine-macOS', '~> x.y.z' end -
Run the
pod repo updatecommand to update the local index to ensure the latest version of the SDK can be installed. For the latest version number, please refer to the release history in the Download Document. -
Run the
pod installcommand to install the SDK.Note- If "CDN: trunk URL couldn't be downloaded" problem occurs, please refer to CocoaPods Common Questions - Unable to connect to trunk CDN problem.
- If "Unable to find a specification for 'ZegoExpressEngine'" problem occurs, please refer to CocoaPods Common Questions - Unable to find project problem.
- If "CocoaPods could not find compatible versions for pod "ZegoExpressEngine-macOS"" problem occurs, please refer to CocoaPods Common Questions - Unable to find project problem.
Method 2: Manual Integration by Copying SDK Files
-
Please refer to the Download document to download the latest version of the SDK and extract it.
-
Manually copy the SDK dynamic library file "ZegoExpressEngine.xcframework" to your project directory.
-
Open Xcode, select the "File > Add Files to "xxx" (xxx is the project name)" menu, and add the SDK library file to the project.

-
Select the "TARGETS > General > Frameworks,Libraries,and Embedded Content" menu, add "ZegoExpressEngine.xcframework", and set "Embed" to "Embed & Sign".

Set Permissions
Set the permissions required by the application according to actual application needs.
In Xcode, select the "TARGETS > Signing & Capabilities > App Sandbox" menu and check the permissions required by the SDK.
Network - Incoming Connections (Server)Network - Outgoing Connections (Client)Hardware - CameraHardware - Audio Input

