同一个外部联系人,不同调用方(企业/第三方服务商)获取到的ExternalUserId是不同的?
你好,我的身份是"企业微信开发服务商",开发了一个网页版应用,并已成功上线; 现有A,B,C三家企业“从服务商网站发起”授权安装了我的应用,我拿到了3家“授权企业的access_token”,根据企业成员的userId调用“获取客户列表”接口,接口地址:https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=ACCESS_TOKEN&userid=USERID 场景一: A企业下A1,A2员工分别添加同一个名为“大明”的“企微外部联系人”; https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=xxxx&userid=a1 {
"code": 200,
"msg": "ok",
"data": {
"errcode": 0,
"errmsg": "ok",
"external_userid": [
"wowhy-CwAAm9LfghQsi_khkt5A0AaTOA",
"wmwhy-CwAA8_oOv6qC0ZO_Zmm6GWYZ2A"//大明
]
}
}
https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=xxxx&userid=a2 {
"code": 200,
"msg": "ok",
"data": {
"errcode": 0,
"errmsg": "ok",
"external_userid": [
"wowhy-CwAApJjrEwmd6RbWwH1f_D6mxA",
"wmwhy-CwAA8_oOv6qC0ZO_Zmm6GWYZ2A"//大明
]
}
}
结论:同一家企业,不同成员,添加同一个外部联系人,external_userid相同; 场景二: A,B,C三家授权企业,分别有成员A1,B1,C1,添加了同一个名为“大明”的“企微外部联系人”; 授权A企业: https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=xaaaaax&userid=a1 {
"code": 200,
"msg": "ok",
"data": {
"errcode": 0,
"errmsg": "ok",
"external_userid": [
"wowhy-CwAAvoCcjoox-4v8vsNwHWycXg",
"wowhy-CwAAPvdVt9oenuLmBfM61SVGCA",
"wowhy-CwAAvux8tHWtJ1yfdEqJLFp7Dg",
"wmwhy-CwAArKEIvGMvAUC7vmejpyjYdw",
"wmwhy-CwAA177eQLeBnPBNfeFEaplaJw",
"wmwhy-CwAAodNubE6Tv2eZulfWiR0E5g"//大明
]
}
}
授权B企业: https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=xbbbbbx&userid=b1 {
"code": 200,
"msg": "ok",
"data": {
"errcode": 0,
"errmsg": "ok",
"external_userid": [
"wmwhy-CwAA177eQLeBnPBNfeFEaplaJw",
"wmwhy-CwAAodNubE6Tv2eZulfWiR0E5g"//大明
]
}
}
授权C企业: https://qyapi.weixin.qq.com/cgi-bin/externalcontact/list?access_token=xccccccx&userid=c1 {
"code": 200,
"msg": "ok",
"data": {
"errcode": 0,
"errmsg": "ok",
"external_userid": [
"wmwhy-CwAA8_oOv6qC0ZO_Zmm6GWYZ2A",
"wmwhy-CwAAodNubE6Tv2eZulfWiR0E5g"//大明
]
}
}
结论:不同企业,不同成员,添加同一个外部联系人,external_userid相同; 引用官网:关于ExternalUserIdExternalUserId是企业微信外部联系人的标识,但需要开发者(尤其是第三方开发者)注意的是,对于同一个外部联系人,不同调用方(企业/第三方服务商)获取到的ExternalUserId是不同的。 我通过调用接口发现“不同企业,同一个外部联系人,external_userid是相同的”。 请问是我以上2个场景的“结论的错误的”,还是我引用官网的理解有误呢? 谢谢!