×

注意!页面内容来自https://developer.work.weixin.qq.com/document/path/101039,本站不储存任何内容,为了更好的阅读体验进行在线解析,若有广告出现,请及时反馈。若您觉得侵犯了您的利益,请通知我们进行删除,然后访问 原网页

<>body { margin: 0; -webkit-font-smoothing: antialiased; font-family: system-ui-apple-systemSegoe UIRobotoUbuntuCantarellNoto Sanssans-serifBlinkMacSystemFontHelveticaPingFang SCSCHeitiMicrosoft YaHeisans-serifApple Color EmojiSegoe UI EmojiSegoe UI SymbolNoto Color Emoji; } .ep-root { --ep-layout-biztop-height: 65px; } @media screen and (max-width: 1220px) { .assistant_header { display: none; } .ep-root { --ep-layout-biztop-height: 0px; } } .head_stage { position: fixed; top: 0; left: 0; right: 0; border-bottom: 1px solid var(--ww_base_gray_007); z-index: 50; user-select: none; background: var(--ww_base_white); } .head_cnt { padding: 16px 30px; margin: 0 auto; display: flex; align-items: center; white-space: nowrap; justify-content: space-between; position: relative; } .head_link { position: absolute; left: 0; bottom: 0; top: 0; width: 120px; z-index: 1; } .head_logo { display: block; width: 120px; height: 30px; } .head_title { margin-right: 14px; font-size: 21px; color: #0082EF; text-decoration: none; font-: normal; font-weight: 500; line-height: 100%; letter-spacing: 0.315px; line-height: 34px; position: relative; margin-left: 15px; padding-left: 16px; } .head_title:hover { text-decoration: none; } .head_title::before { content: " "; display: inline-block; position: absolute; left: 0; top: 9px; width: 1px; height: 16px; background-color: #0082f0; } .head_left { display: flex; align-items: center; } .head_right { display: flex; justify-content: flex-end; } .head_cnt_nav { transition: all 0.15s; display: flex; margin: 0 auto; align-items: center; white-space: nowrap; top: 65px; z-index: 60; margin-right: 50px; background: var(--ww_base_white); } .head_cnt_nav .nav_item { font-size: 16px; color: var(--ww_base_gray_100); margin-left: 16px; align-items: center; justify-content: center; display: flex; width: 60px; height: 100%; cursor: pointer; &[active] { position: relative; color: var(--ww_accent_blue); } } .head_cnt_nav .nav_item_active { position: absolute; width: 40px; height: 2px; background: var(--ww_accent_blue); left: 10px; bottom: -14px; } .head_actions { flex: 1; display: flex; align-items: center; justify-content: flex-end; position: relative; } .head_actions .head_actions_icon { margin-right: 16px; cursor: pointer; } .head_login { width: 90px; height: 30px; box-sizing: border-box; font-weight: 400; font-size: 15px; line-height: 30px; text-align: center; color: var(--ww_accent_blue); border: 1px solid var(--ww_accent_blue); border-radius: 2px; cursor: pointer; } .search { height: 34px; margin-right: 16px; position: relative; z-index: 2; } .search .search-placeholder { height: 34px; align-items: center; justify-content: center; display: flex; } .search .search-icon { display: inline-block; background-image: url(https://wwcdn.weixin.qq.com/node/wework/images/202201061753.bd4d6ef977.svg); background-size: 20px 20px; background-position: center center; background-repeat: no-repeat; cursor: pointer; width: 20px; height: 34px; }
企业内部开发
基础
连接微信
办公
会议
会议统计管理
企业内部开发
服务端API
消息接收与发送
智能机器人
概述
概述
最后更新:2025/08/18

目录

  • API设置
  • 接收回调与被动回复
  • 示例代码
  • API设置

    若智能机器人开启API模式,当用户跟智能机器人交互时,企业微信会向智能机器人API设置中的URL的回调地址推送相关消息跟事件。

    配置URL时,需要验证url有效性

     

    接收回调与被动回复

    当用户跟智能机器人交互时,企业微信会向智能机器人的回调URL上推送相关消息或者事件,开发者可根据接收的消息或者事件被动回复消息。具体流程如下:

    企业微信截图

     

    接收消息与被动回复消息都需加密,加密方式参考回调和回复的加解密方案

    示例代码

    我们以python为例,提供了一份示例代码,以供开发者参考(包含python2与python3两个版本):点击下载

    上一篇消息推送配置说明
    下一篇接收消息
      本节内容
    服务端API
    基础
    连接微信
    办公
    会议
    会议统计管理
    客户端API
    小程序
    基础
    连接微信
    办公
    JS-SDK
    基础
    连接微信
    办公
    消息推送(原“群机器人”)
    更新日志
    联系我们