# 构建 Chat Channel Sample

> Build and run the Chat Channel Sample in your development environment.

**先决条件**：[导入 Chat Channel Sample](./import-chat-channel-sample.md)。

要设置环境来构建 Chat Channel Sample，请完成以下步骤：

1. 打开您的 Unity 项目。

2. 选择 **Edit > Project Settings**。选择 **Vivox** 并用应用程序的凭据更新 **Server**、**Domain**、**Token issuer** 和 **Token key** 字段。

   有关生成凭据的信息，请参阅 [Unity Package Manager Vivox 包](../developer-guide/implement-vivox-unity/unity-package-manager-vivox)。

   > **Note:**
   >
   > 如果项目绑定到 **Services** 页面，则可以将 **Environment** 菜单更改为 Automatic，从而自动从 Unity Dashboard（Unity 后台）中提取项目的凭据。

3. 将 `.../Samples/Vivox/{Version}/Chat Channel Sample/` 中的 MainScene 添加到 Build Settings 中。
