# Connect WeCom Bot (/docs/channels/wecom)









Connect WeCom Bot [#connect-wecom-bot]

Buda supports direct conversations with employees via WeCom's **Smart Bot**. Once configured, employees can message the bot in WeCom and Buda will reply automatically.

***

Step 1: Create a Bot [#step-1-create-a-bot]

In WeCom, tap **Workbench** at the bottom, then find and open **Smart Bot**.

<img alt="Open Smart Bot" src="__img0" />

Tap **Create Bot** → **Manual Creation**. On the creation page, scroll down and click **Create in API Mode**.

<img alt="Switch to API Mode" src="__img1" />

***

Step 2: Configure the Connection [#step-2-configure-the-connection]

On the API configuration page:

1. Select **Use Long Connection** as the connection method
2. Copy the **Bot ID**
3. Click **Click to Get** to reveal and copy the **Secret**
4. Fill in the bot name, avatar, and visibility scope
5. Click **Save**

<img alt="Configure connection and copy credentials" src="__img2" />

> The Bot ID and Secret can be viewed again at any time — they are not one-time values.

***

Step 3: Add the Channel in Buda [#step-3-add-the-channel-in-buda]

1. Open **Channels** in Buda settings
2. Click **Add Channel** and select **WeCom Smart Bot**
3. Enter the **Bot ID** and **Secret**, then click **Connect**

***

Step 4: Test [#step-4-test]

Go back to WeCom, find the bot you just created, and send a message such as `Hi`.

Once Buda replies, you're all set 🎉

***

Troubleshooting [#troubleshooting]

The bot is not responding [#the-bot-is-not-responding]

| Possible cause                   | Solution                                                                              |
| -------------------------------- | ------------------------------------------------------------------------------------- |
| Incorrect Bot ID or Secret       | Copy them again from WeCom, making sure there are no extra spaces                     |
| Wrong connection method selected | Confirm that **Use Long Connection** was selected in Step 2, not **Use URL Callback** |
| Channel is disabled              | Check that the channel status in Buda shows **Active**                                |

What if the Secret is compromised? [#what-if-the-secret-is-compromised]

Regenerate the Secret in the WeCom admin console, then update it in Buda's channel settings.

***

References [#references]

* [WeCom Smart Bot Developer Docs](https://developer.work.weixin.qq.com/document/path/101463)
