系统设置自定义字段
分页查询自定义字段列表
分页查询企业自定义字段基础信息。请求体可以为空;为空时 limit 默认 500,offset 默认 0。结果按修改时间倒序返回,并按 keywords 对字段名称做包含匹配。
请求参数
| 名称 | 类型 | 必填 | 描述 | 示例值 |
|---|---|---|---|---|
| appKey | string | 是 | 应用 AppKey | |
| time | int64 | 是 | 请求时间戳(秒) | |
| checksum | string | 是 | 请求签名校验和 | |
| checksumAlgorithm | int32 | 否 | 签名算法:0 - 默认(SHA1),1 - SHA256 |
请求体
| 名称 | 类型 | 必填 | 描述 | 示例值 |
|---|---|---|---|---|
| limit | int32 | 否 | 每页数量;请求体为空或字段缺失时默认 500 | 500 |
| offset | int32 | 否 | 查询偏移量;请求体为空或字段缺失时默认 0。 | 0 |
| keywords | string | 否 | 查询关键字,按字段名称做包含匹配。 | 客户 |
返回参数
| 名称 | 类型 | 描述 | 示例值 |
|---|---|---|---|
| code | int32 | 状态码,200 表示成功 | 200 |
| data | object | 分页数据 | {"total":1,"result":[{"id":10001,"name":"客户意向","type":1,"description":"[{\"text\":\"高意向\",\"opId\":\"high\"}]","updateTime":1739347200000,"status":0}]} |
| └total | int32 | 当前查询返回总数 | 20 |
| └result | object[] | 自定义字段基础信息列表 | [{"id":10001,"name":"客户意向","type":1,"description":"[{\"text\":\"高意向\",\"opId\":\"high\"}]","updateTime":1739347200000,"status":0}] |
| └id | int64 | 自定义字段 ID | 10001 |
| └name | string | 自定义字段名称 | 客户意向 |
| └type | int32 | 字段类型:0-文本,1-单选,2-多选,3-时间,5-新版数据,6-级联,7-附件 | 1 |
| └description | string | 字段描述。单选/多选字段通常是枚举项 JSON 数组字符串,元素包含 text 和可选 opId。 | [{"text":"高意向","opId":"high"},{"text":"低意向","opId":"low"}] |
| └updateTime | int64 | 字段更新时间,毫秒时间戳 | 1739347200000 |
| └status | int32 | 字段状态:0-正常,1-删除 | 0 |
错误码
| 状态码 | 描述 |
|---|---|
| 14001 | AppKey 不存在 |
| 14002 | checksum 校验失败 |
| 14003 | time 缺失,或请求时间戳与服务器时间误差超过 10 分钟 |
| 14500 | 服务内部异常;请求体无法解析或自定义字段读取失败 |
postEndpoint
/openapi/customfield/getCustomFieldListcurl -X POST "https://qiyukf.com/openapi/customfield/getCustomFieldList?appKey=9f1d7c2b8a6e4d3c&time=1739347200&checksum=a1b2c3d4e5f607182930abcdefabcdef&checksumAlgorithm=0" \ -H "Content-Type: application/json" \ -d '{}'{
"code": 200,
"data": {
"total": 1,
"result": [
{
"id": 10001,
"name": "客户意向",
"type": 1,
"description": "[{\"text\":\"高意向\",\"opId\":\"high\"}]",
"updateTime": 1739347200000,
"status": 0
}
]
}
}{
"code": 14001,
"message": "AppKey 不存在"
}{
"code": 14002,
"message": "checksum 校验失败"
}{
"code": 14003,
"message": "time 缺失,或请求时间戳与服务器时间误差超过 10 分钟"
}{
"code": 14500,
"message": "服务内部异常;请求体无法解析或自定义字段读取失败"
}这篇文档有帮助吗?