| 项目 | 说明 |
|---|---|
| URL | POST /auth/getToken |
| Content-Type | application/x-www-form-urlencoded |
| 是否需要Token | 否 |
请求参数:
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| contactPerson | String | 是 | 联系人电话 |
请求示例:
POST /auth/getToken
Content-Type: application/x-www-form-urlencoded
contactPerson=13800001111
成功响应:
{
"code": 200,
"data": "a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4"
}
失败响应:
{
"code": 10001,
"msg": "contactPerson不能为空"
}
所有接口(除 /auth/getToken 外)请求头必须携带:
| Header | 值 | 说明 |
|---|---|---|
token |
获取到的 token 字符串 | 24小时有效,不自动续期 |
Token 失效响应:
{
"code": 10021,
"msg": "TOKEN失效"
}
基础路径:/sourceFieldAuthority,所有接口统一 POST
| 项目 | 说明 |
|---|---|
| URL | POST /sourceFieldAuthority/save |
| Content-Type | application/json |
请求参数:
{
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"authorityScore": 100
}
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
| entityType | String | 是 | 实体类型:PERSON/ENTERPRISE |
| modelField | String | 是 | 模型字段名 |
| sourceTable | String | 是 | 来源表名 |
| sourceKeyField | String | 是 | 来源表主键字段名 |
| sourceField | String | 是 | 来源字段名 |
| authorityScore | Long | 是 | 优先级分:100/70/40 |
校验规则:
| 项目 | 说明 |
|---|---|
| URL | POST /sourceFieldAuthority/update |
请求参数:在新增基础上增加 uuid 字段
{
"uuid": "xxx",
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"authorityScore": 100
}
| 项目 | 说明 |
|---|---|
| URL | POST /sourceFieldAuthority/delete |
请求参数:
{
"uuid": "xxx"
}
| 项目 | 说明 |
|---|---|
| URL | POST /sourceFieldAuthority/getInfo |
请求参数:
{
"uuid": "xxx"
}
响应:
{
"code": 200,
"data": {
"uuid": "xxx",
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"authorityScore": 100,
"createUser": "张三",
"createTime": 1719000000000,
"updateUser": null,
"updateTime": null
}
}
| 项目 | 说明 |
|---|---|
| URL | POST /sourceFieldAuthority/page |
请求参数:
{
"pageNumber": 1,
"pageSize": 10,
"entityType": "PERSON",
"modelField": "phone"
}
响应:
{
"code": 200,
"data": {
"records": [],
"totalRow": 100,
"pageNumber": 1,
"pageSize": 10
}
}
基础路径:/fieldDecayConfig,接口结构与来源优先级一致
POST /fieldDecayConfig/save{
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"halfLifeDays": 90,
"decayFloor": 0.50
}
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
| halfLifeDays | Long | 是 | 半衰期天数,必须大于0 |
| decayFloor | Double | 是 | 最低时效分,0~1之间 |
POST /fieldDecayConfig/update请求参数同新增,增加 uuid 字段
POST /fieldDecayConfig/delete{
"uuid": "xxx"
}
POST /fieldDecayConfig/getInfo{
"uuid": "xxx"
}
响应:
{
"code": 200,
"data": {
"uuid": "xxx",
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"halfLifeDays": 90,
"decayFloor": 0.50,
"createUser": "张三",
"createTime": 1719000000000,
"updateUser": null,
"updateTime": null
}
}
POST /fieldDecayConfig/page{
"pageNumber": 1,
"pageSize": 10,
"entityType": "PERSON",
"modelField": "phone"
}
基础路径:/consensusConfig,接口结构与来源优先级一致
POST /consensusConfig/save{
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"alpha": 0.85
}
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
| alpha | Double | 是 | 孤证保底系数,0.80~0.95之间 |
POST /consensusConfig/update请求参数同新增,增加 uuid 字段
POST /consensusConfig/delete{
"uuid": "xxx"
}
POST /consensusConfig/getInfo{
"uuid": "xxx"
}
响应:
{
"code": 200,
"data": {
"uuid": "xxx",
"entityType": "PERSON",
"modelField": "phone",
"sourceTable": "ods_operator_user",
"sourceKeyField": "user_id",
"sourceField": "mobile",
"alpha": 0.85,
"createUser": "张三",
"createTime": 1719000000000,
"updateUser": null,
"updateTime": null
}
}
POST /consensusConfig/page{
"pageNumber": 1,
"pageSize": 10,
"entityType": "PERSON",
"modelField": "phone"
}
| 校验项 | 规则 | 提示信息 |
|---|---|---|
| 优先级分值 | authorityScore 只能为 100/70/40 | 优先级分只能为 100、70 或 40 |
| 分值唯一性 | 同一 model_field + entityType 下同分值最多1条 | 该模型字段的 {score} 分已配置 |
| 来源字段唯一性 | 同一 model_field 下来源字段组合唯一 | 该来源字段已配置,不能重复 |
| 半衰期 | halfLifeDays > 0 | 半衰期天数必须大于 0 |
| 最低时效分 | 0 < decayFloor < 1 | 最低时效分必须在 0-1 之间 |
| 孤证保底系数 | 0.80 ≤ alpha ≤ 0.95 | 孤证保底系数建议在 0.80-0.95 之间 |