Fx.er

Fx.er:互联

1. getPublicEmployeesBindInfo 获取互联用户绑定情况

Fx.er.getPublicEmployeesBindInfo(<Long downstreamOuterTenantId>, <Long downstreamOuterUid>)

参数说明

参数 类型 说明
downstreamOuterTenantId Long 下游企业外部id
downstreamOuterUid Long 下游企业员工外部id

返回值类型

APIResult

返回值说明

返回的数据类型: String

Java举例

Long downstreamOuterTenantId = 300108748L;
Long downstreamOuterUid = 300384206L;
APIResult ret = Fx.er.getPublicEmployeesBindInfo(downstreamOuterTenantId, downstreamOuterUid);
if (ret.isError()) {
    log.info(ret.message());
} else {
    log.info(ret.getData());
}

Groovy举例

Long downstreamOuterTenantId = 300108748L
Long downstreamOuterUid = 300384206L
def (Boolean error, Map data, String message) = Fx.er.getPublicEmployeesBindInfo(downstreamOuterTenantId, downstreamOuterUid)
if (error) {
  log.info("error: " + error)
} else {
  log.info(data)
}

2. listWxOpenIdsByPhone 查询手机号关联的微信openId列表

Fx.er.listWxOpenIdsByPhone(<String phone>, <String wxAppId>, <Integer type>)

参数说明

参数 类型 说明
phone String 手机号
wxAppId String 微信公众号/小程序appId
type Integer appId类型(公众号=4;小程序=5)

返回值类型

APIResult

返回值说明

返回的数据类型: Map

Java举例

APIResult ret = Fx.er.listWxOpenIdsByPhone("18807849027", "wx3ce8441bd6cddce9", 4);
if (ret.isError()) {
    log.info(ret.message());
} else {
    log.info(ret.getData());
}

Groovy举例

def (Boolean error, Map data, String message) = Fx.er.listWxOpenIdsByPhone("18807849027", "wx3ce8441bd6cddce9", 4)
if (error) {
  log.info("error: " + error)
} else {
  log.info(data)
}

3. batchCreateDownstreamPublicEmployees 批量添加我方对接人

Fx.er.batchCreateDownstreamPublicEmployees(<String upstreamEa>, <List downstreamEmployeeIds>, <List outerRoleIds>)

参数说明

参数 类型 说明
upstreamEa String 上游企业账号
downstreamEmployeeIds List 下游企业员工ID
outerRoleIds List 外部角色

返回值类型

APIResult

返回值说明

List

Java举例

String upstreamEa = "82322";
List downstreamEmployeeIds = Lists.newArrayList(1125);
List outerRoleIds = Lists.newArrayList("00000000000000000000000000000021");
def ret = Fx.er.batchCreateDownstreamPublicEmployees(upstreamEa, downstreamEmployeeIds, outerRoleIds).result() as List;

Groovy举例

String upstreamEa = "82322"
List downstreamEmployeeIds = [1125]
List outerRoleIds = ['00000000000000000000000000000021']
def ret = Fx.er.batchCreateDownstreamPublicEmployees(upstreamEa, downstreamEmployeeIds, outerRoleIds).result() as List

2024-09-15
0 1
Baidu
map