腾讯乐享接口文档 POST https://lxapi.lexiangla.com/cgi-bin/v1/message/send
document图文消息
{
"to_user": "zhangsan|lisi",
"to_department": "1|2|3",
"to_tag": "100|200",
"msg_type": "news",
"news": {
"articles": [
{
"title": "第一条图文",
"url": "https://lexiangla.com/docs?company_from=xx",
"picture": "https://lexiangla.com/assets/565d24f2007a11f090d8aad9ac1be675",
"description": "描述"
},
{
"title": "第二条图文",
"url": "https://lexiangla.com/questions?company_from=xx",
"picture": "https://lexiangla.com/assets/565d24f2007a11f090d8aad9ac1be675"
}
]
}
}
| 参数 | 说明 |
|---|---|
| to_user | 员工账号,用“|”分割,单次推送最多1000个,可以使用“@all”表示全员推送 |
| to_department | 部门ID,用“|”分割,单次推送最多10个 |
| to_tag | 通讯录标签ID,用“|”分割,单次推送最多10个 |
| msg_type | 消息类型,暂只支持图文消息:news |
| news.articles | 若消息类型为news时,必填。支持多图文最多10条 |
| news.articles.*.title | 图文标题,必填 |
| news.articles.*.url | 点击图文打开的链接 |
| news.articles.*.picture | 图片,支持当前乐享企业的assets图片URL或公网可访问的图片URL |
| news.articles.*.description | 描述 |
document{
"data": {
"message_id": "a4bef656007b11f08240ea159cdfdc2c",
"illegal_users": [],
"illegal_departments": [],
"illegal_tags": []
},
"msg": "success",
"code": 0
}
| 参数 | 说明 |
|---|---|
| code | 0 表示正常;其他错误参考msg |
| msg | 错误信息 |
| data.message_id | 消息ID,用于查询消息推送结果 |
| data.illegal_users | 无效的用户账号 |
| data.illegal_departments | 无效的部门ID |
| data.illegal_tags | 无效的标签ID |