Skip to main content

跟进记录模块

跟进记录类型列表接口

接口地址

https://e-crm.icsoc.net/openapi/v1/followupRecord/recordTypes

请求方式

GET

响应结果

{
"code": 200,
"message": "ok",
"data": [
{
"id": 36,
"dic_name": "系统自动"
},
{
"id": 37,
"dic_name": "123123"
},
{
"id": 38,
"dic_name": "慢速记录"
},
{
"id": 39,
"dic_name": "光速记录"
}
]
}

结果说明

返回字段字段类型说明
idint类型ID
dic_namestring类型说明

新增跟进记录接口

接口地址

https://e-crm.icsoc.net/openapi/v1/followupRecord

请求方式

POST

{
"cle_id": 6470844909275561985,
"opty_id": 6471982131139821569,
"record_type": 36,
"record_content": "跟进记录"
}

参数说明

参数类型说明必选约束
cle_idint客户IDpostmen等工具可能溢出,可使用字符串方式传递
opty_idint商机ID若有值,必须是客户ID所属的商机。postmen等工具可能溢出,可使用字符串方式传递
record_typeint记录类型跟进记录类型,具体枚举值参见 跟进记录类型列表接口
record_contentstring记录内容根据联系人管理-系统字段管理设置

响应结果

{
"code": 200,
"message": "ok",
"data": {
"id": "6471994196059471873",
"_id": 6471994196059472000
}
}

结果说明

返回字段字段类型说明
idstring跟进记录ID(string类型)
_idint跟进记录ID(int类型)

跟进记录列表接口

接口地址

https://e-crm.icsoc.net/openapi/v1/followupRecord/followupRecords?page={page}&page_size={page_size}&cle_name={cle_name}&record_content_name={record_content_name}&sort={sort}&order={order}&cle_id={cle_id}

请求方式

GET

参数说明

参数类型说明必选约束
cursorstring游标,第一次查询时无需传该值,后续查询时,将上一次查询获取数据中的cursor传递过来即可,此字段用于分页查询
page_sizeint查询数据条数,默认为10
sortstring排序字段,若有值,根据字段进行排序返回,默认为create_time
orderstring排序规则,默认为降序desc枚举值:asc,desc
cle_namestring客户名称,若有值,返回符合条件的数据,匹配规则为模糊匹配
cle_idstring客户id,若有值,返回符合条件的数据,匹配规则为模糊匹配
cle_phonestring客户电话,若有值,返回符合条件的数据,匹配规则为精确匹配
create_timedatetime创建时间,若有值,返回该时间之后的数据,时间格式支持2019-01-01或者2019/01/01
record_content_namestring跟进记录内容,可选。若有值,返回符合条件的数据,匹配规则为模糊匹配

响应结果

{
"code": 200,
"message": "ok",
"data": {
"cursor": "WzE1NDIzNTA0NzgsImNybV9jbGllbnRzIzY0NjkwODY3ODA0NTYxNTcxODUiXQQD",
"total": 2,
"rows": [
{
"_id": 6471994196059471873,
"opty_id": 6471982131139821569,
"record_type": 36,
"cle_id": "6470844909275561985",
"record_content": "跟进记录",
"create_user_id": 90000172,
"create_time": 1543043660,
"client": {
"_id": 6470844909275561985,
"cle_name": "1112321323",
"cle_phone": "3121123123",
"cle_source": 1,
"cle_source_name": "官网注册",
"cle_type": 1,
"cle_type_name": "潜在客户",
"cle_grade": 1,
"cle_grade_name": "普通客户",
"sale_charge_user_id": 90002395,
"service_charge_user_id": 0,
"is_win_order": 2,
"is_win_order_name": "否",
"last_assign_time": 1542769648,
"last_recycle_time": 0,
"transfer_public_reason_id": 0,
"create_type": 0,
"import_task_id": 0,
"create_user_id": 90002395,
"create_time": 1542769648,
"update_user_id": 90000172,
"update_time": 1542950533,
"last_contact_user_id": 90000172,
"last_contact_time": 1542955157,
"datasource_6469093183677775873": [],
"datasource_6469093183677775873_name": "",
"datasource_6469093223150370817": [],
"datasource_6469093223150370817_name": "",
"input_6470108518023413761": "默认值测试",
"textarea_6470108592325509121": "12311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231",
"select_6470108723137462273": 2,
"select_6470108723137462273_name": "222222222222222",
"radio_6470108813340164097": 2,
"radio_6470108813340164097_name": "222222222222222",
"checkbox_6470108890934788097": [],
"checkbox_6470108890934788097_name": "",
"datetime_6470108953748684801": 1542556800,
"cascade_6470109026154954753": [],
"cascade_6470109026154954753_name": "",
"city_6470109140181303297": [],
"city_6470109140181303297_name": "",
"telephone_6470109718877814785": "132222212312312",
"email_6470109810384945153": "",
"number_6470109847739416577": 3,
"attachment_6470109901174849537": [],
"attachment_6470109999745187841": [],
"input_6470212194209611777": "",
"city_6470212275625246721": [],
"city_6470212275625246721_name": "",
"input_6470212373881012225": "",
"input_6470212433549180929": "",
"input_6470212479275483137": "",
"input_6470212529321918465": "",
"select_6470213535355092993": 0,
"select_6470213535355092993_name": "",
"input_6470213585858707457": "",
"input_6470213645757562881": "",
"select_6470215797540372481": 0,
"select_6470215797540372481_name": "",
"datasource_6470223215527706625": [
"230101"
],
"datasource_6470223215527706625_name": "武汉沌口门店",
"radio_6470475943239729153": 0,
"radio_6470475943239729153_name": "",
"radio_6470477758073126913": 0,
"radio_6470477758073126913_name": "",
"input_6470524366294859777": "",
"attachment_6470524827785740289": [],
"datasource_6470536728531943425": [],
"datasource_6470536728531943425_name": "",
"datasource_6470835680972095489": [],
"datasource_6470835680972095489_name": "",
"original_id": 0,
"cle_pinyin": "1112321323",
"sale_charge_user_name": "1214 luquan",
"sale_charge_department_id": 39,
"sale_charge_department_name": "测试分配策略",
"service_charge_user_name": "",
"service_charge_department_id": 0,
"service_charge_department_name": "",
"last_contact_user_name": "8002 8002坐席",
"last_contact_department_id": 1,
"last_contact_department_name": "公司",
"create_type_name": "手动创建",
"transfer_public_reason_name": "",
"opportunity_num": 4,
"import_task_name": "",
"im_third_id": "",
"create_role_id": 19,
"create_role_name": "鲁权测试",
"switch_times": 0,
"vcc_id": 90000000,
"create_user_name": "1214 luquan",
"create_department_id": 39,
"create_department_name": "测试分配策略",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": 0,
"select_6471310166045474817": 2,
"select_6471310166045474817_name": "222",
"id": "6470844909275561985",
"no_contact_days": 1
},
"opportunity": {
"_id": 6471982131139821569,
"opty_name": "商机1",
"cle_id": 6470844909275561985,
"opty_type": 1,
"opty_type_name": "新客户商机",
"opty_source": 1,
"opty_source_name": "官网注册",
"opty_stage": 22,
"lose_order_reason": 0,
"lose_order_remark": "",
"sale_charge_user_id": 90002395,
"create_user_id": 90000172,
"create_time": 1543040783,
"update_user_id": 90000172,
"update_time": 1543041375,
"last_contact_user_id": 90000172,
"last_contact_time": 1543043667,
"cle_name": "1112321323",
"cle_phone": "3121123123",
"opty_stage_name": "初步洽谈",
"lose_order_reason_name": "",
"sale_charge_user_name": "1214 luquan",
"sale_charge_department_id": 39,
"sale_charge_department_name": "测试分配策略",
"last_contact_user_name": "8002 8002坐席",
"last_contact_department_id": 1,
"last_contact_department_name": "公司",
"vcc_id": 90000000,
"create_user_name": "8002 8002坐席",
"create_department_id": 1,
"create_department_name": "公司",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": 0,
"id": "6471982131139821569"
},
"record_type_name": "系统自动",
"create_role_id": 1,
"create_role_name": "BOSS",
"vcc_id": 90000000,
"create_user_name": "8002 8002坐席",
"create_department_id": 1,
"create_department_name": "公司",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": "公司",
"cle_name": "1112321323",
"update_time": 1543043660,
"update_user_id": 90000172,
"record_content_name": "跟进记录",
"id": "6471994196059471873"
},
{
"_id": 6471994225851613185,
"opty_id": 6471982131139821569,
"record_type": 36,
"cle_id": "6470844909275561985",
"record_content": "跟进记录",
"create_user_id": 90000172,
"create_time": 1543043667,
"client": {
"_id": 6470844909275561985,
"cle_name": "1112321323",
"cle_phone": "3121123123",
"cle_source": 1,
"cle_source_name": "官网注册",
"cle_type": 1,
"cle_type_name": "潜在客户",
"cle_grade": 1,
"cle_grade_name": "普通客户",
"sale_charge_user_id": 90002395,
"service_charge_user_id": 0,
"is_win_order": 2,
"is_win_order_name": "否",
"last_assign_time": 1542769648,
"last_recycle_time": 0,
"transfer_public_reason_id": 0,
"create_type": 0,
"import_task_id": 0,
"create_user_id": 90002395,
"create_time": 1542769648,
"update_user_id": 90000172,
"update_time": 1542950533,
"last_contact_user_id": 90000172,
"last_contact_time": 1543043660,
"datasource_6469093183677775873": [],
"datasource_6469093183677775873_name": "",
"datasource_6469093223150370817": [],
"datasource_6469093223150370817_name": "",
"input_6470108518023413761": "默认值测试",
"textarea_6470108592325509121": "12311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231123112311231",
"select_6470108723137462273": 2,
"select_6470108723137462273_name": "222222222222222",
"radio_6470108813340164097": 2,
"radio_6470108813340164097_name": "222222222222222",
"checkbox_6470108890934788097": [],
"checkbox_6470108890934788097_name": "",
"datetime_6470108953748684801": 1542556800,
"cascade_6470109026154954753": [],
"cascade_6470109026154954753_name": "",
"city_6470109140181303297": [],
"city_6470109140181303297_name": "",
"telephone_6470109718877814785": "132222212312312",
"email_6470109810384945153": "",
"number_6470109847739416577": 3,
"attachment_6470109901174849537": [],
"attachment_6470109999745187841": [],
"input_6470212194209611777": "",
"city_6470212275625246721": [],
"city_6470212275625246721_name": "",
"input_6470212373881012225": "",
"input_6470212433549180929": "",
"input_6470212479275483137": "",
"input_6470212529321918465": "",
"select_6470213535355092993": 0,
"select_6470213535355092993_name": "",
"input_6470213585858707457": "",
"input_6470213645757562881": "",
"select_6470215797540372481": 0,
"select_6470215797540372481_name": "",
"datasource_6470223215527706625": [
"230101"
],
"datasource_6470223215527706625_name": "武汉沌口门店",
"radio_6470475943239729153": 0,
"radio_6470475943239729153_name": "",
"radio_6470477758073126913": 0,
"radio_6470477758073126913_name": "",
"input_6470524366294859777": "",
"attachment_6470524827785740289": [],
"datasource_6470536728531943425": [],
"datasource_6470536728531943425_name": "",
"datasource_6470835680972095489": [],
"datasource_6470835680972095489_name": "",
"original_id": 0,
"cle_pinyin": "1112321323",
"sale_charge_user_name": "1214 luquan",
"sale_charge_department_id": 39,
"sale_charge_department_name": "测试分配策略",
"service_charge_user_name": "",
"service_charge_department_id": 0,
"service_charge_department_name": "",
"last_contact_user_name": "8002 8002坐席",
"last_contact_department_id": 1,
"last_contact_department_name": "公司",
"create_type_name": "手动创建",
"transfer_public_reason_name": "",
"opportunity_num": 4,
"import_task_name": "",
"im_third_id": "",
"create_role_id": 19,
"create_role_name": "鲁权测试",
"switch_times": 0,
"vcc_id": 90000000,
"create_user_name": "1214 luquan",
"create_department_id": 39,
"create_department_name": "测试分配策略",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": 0,
"select_6471310166045474817": 2,
"select_6471310166045474817_name": "222",
"id": "6470844909275561985",
"no_contact_days": 0
},
"opportunity": {
"_id": 6471982131139821569,
"opty_name": "商机1",
"cle_id": 6470844909275561985,
"opty_type": 1,
"opty_type_name": "新客户商机",
"opty_source": 1,
"opty_source_name": "官网注册",
"opty_stage": 22,
"lose_order_reason": 0,
"lose_order_remark": "",
"sale_charge_user_id": 90002395,
"create_user_id": 90000172,
"create_time": 1543040783,
"update_user_id": 90000172,
"update_time": 1543041375,
"last_contact_user_id": 90000172,
"last_contact_time": 1543043667,
"cle_name": "1112321323",
"cle_phone": "3121123123",
"opty_stage_name": "初步洽谈",
"lose_order_reason_name": "",
"sale_charge_user_name": "1214 luquan",
"sale_charge_department_id": 39,
"sale_charge_department_name": "测试分配策略",
"last_contact_user_name": "8002 8002坐席",
"last_contact_department_id": 1,
"last_contact_department_name": "公司",
"vcc_id": 90000000,
"create_user_name": "8002 8002坐席",
"create_department_id": 1,
"create_department_name": "公司",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": 0,
"id": "6471982131139821569"
},
"record_type_name": "系统自动",
"create_role_id": 1,
"create_role_name": "BOSS",
"vcc_id": 90000000,
"create_user_name": "8002 8002坐席",
"create_department_id": 1,
"create_department_name": "公司",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": "公司",
"cle_name": "1112321323",
"update_time": 1543043667,
"update_user_id": 90000172,
"record_content_name": "跟进记录",
"id": "6471994225851613185"
}
]
}
}

结果说明

返回字段字段类型说明
cursorstring查询游标,下次查询使用
totalint总条数
rowsarray结果集 (参数说明参见跟进记录字段参考说明

跟进记录详情接口

接口地址

https://e-crm.icsoc.net/openapi/v1/followupRecord/{record_id}

请求方式

GET

参数说明

参数类型说明必选约束
record_idstring跟进记录详情ID必填

响应结果

{
"code": 200,
"message": "ok",
"data": {
"_id": 6471994196059471873,
"opty_id": 6471982131139821569,
"record_type": 36,
"cle_id": 6470844909275561985,
"record_content": "跟进记录",
"create_user_id": 90000172,
"create_time": 1543043660,
"record_type_name": "系统自动",
"create_role_id": 1,
"create_role_name": "BOSS",
"vcc_id": 90000000,
"create_user_name": "8002 8002坐席",
"create_department_id": 1,
"create_department_name": "公司",
"update_user_name": "8002 8002坐席",
"update_department_id": 1,
"update_department_name": "公司",
"cle_name": "1112321323",
"update_time": 1543043660,
"update_user_id": 90000172,
"record_content_name": "跟进记录",
"id": "6471994196059471873"
}
}

结果说明

参数类型说明
cle_idint客户ID
opty_idint商机ID
record_typeint跟进记录类型ID
record_contentstring跟进记录内容

删除跟进记录接口

支持批量删除

接口地址

https://e-crm.icsoc.net/openapi/v1/followupRecord

请求方式

DELETE

示例:

curl -X DELETE \
http://e-crm-dev-k8s.icsoc.net/api/followupRecord" \
-H "accept: application/json" \
-H "Authorization: Bearer {access-token}" \
-H "Content-Type: application/json" \
-d '{
"ids":[6454980244729479169,6454980230145884161]
}'

参数说明

参数类型说明必选约束
idsarray跟进记录ID集合

响应结果

{
"code": 200,
"message": "ok",
"data": []
}

跟进记录字段说明

参数名参数说明
_id跟进记录ID
opty_id关联的商机ID,若跟进记录时基于商机添加的,则此字段有值
record_type跟进记录类型ID,具体枚举值参考 获取跟进记录类型列表 接口
cle_id关联的客户ID
record_content跟进记录内容(原始内容,未去除html标签)
create_user_id创建人ID
create_time创建时间
client关联的客户所有信息,具体字段请参考 客户字段说明
opportunity关联的商机所有信息,具体字段请参考 商机字段说明
record_type_name跟进记录类型名称
create_role_id创建人角色ID
create_role_name创建人角色名称
vcc_id企业号
create_user_name创建人姓名(坐席工号+空格+坐席名称)
create_department_id创建人部门ID
create_department_name创建人部门名称
update_user_name更新人名称(坐席工号+空格+坐席名称)
update_department_id更新人部门ID
update_department_name更新人部门名称
cle_name客户名称
update_time更新时间
update_user_id更新人ID
record_content_name跟进记录内容(去除html标签后)
id跟进记录ID(冗余字段,类型为string)