简要描述:
- 创建公海客户
请求URL:
/api/v2/common_customers
请求方式:
- POST
请求头:
- 请参考接口必读
请求参数:
请求参数说明
字段名 | 是否必填 | 描述 |
---|---|---|
common_id | true | 公海id GET api/v2/common_customers/common_settings |
customer[custom_field_template_id] | false | 业务模版id |
customer[parent_id] | false | 上级客户id. |
customer[name] | false | 客户名称 |
customer[note] | false | 备注 |
customer[status] | false | 跟进状态 值为 /api/v2/field_maps/customer 返回值 |
customer[category] | false | 客户类型 值为 /api/v2/field_maps/customer 返回值 |
customer[source] | false | 客户来源 值为 /api/v2/field_maps/customer 返回值 |
customer[industry] | false | 行业 值为 /api/v2/field_maps/customer 返回值 |
customer[staff_size] | false | 员工人数 |
customer[want_department_id] | false | 所属部门 |
customer[address_attributes][detail_address] | false | 地址详情 |
customer[address_attributes][tel] | false | 电话 |
customer[address_attributes][url] | false | 这是 [url] |
customer[address_attributes][country_id] | false | 国家id |
customer[address_attributes][province_id] | false | 省id |
customer[address_attributes][city_id] | false | 城市id |
customer[address_attributes][district_id] | false | 区域id |
customer[address_attributes][zip] | false | 邮编 |
customer[address_attributes][fax] | false | 传真 |
customer[address_attributes][qq] | false | |
customer[address_attributes][wechat] | false | 微信 |
customer[address_attributes][wangwang] | false | wangwang |
customer[address_attributes][phone] | false | 手机 |
customer[address_attributes][email] | false | 邮箱 |
customer[contacts_attributes][name] | false | 联系人姓名 |
customer[opportunities_attributes][title] | false | 商机标题 |
返回示例:
正确时返回:
{
"code": 0,
"data": {
"id": 18,
"name": "贸易公司",
"status": "7",
"status_mapped": "初访",
"note": "主营外贸销售,代理国外一线品牌",
"category": "",
"category_mapped": "",
"source": "",
"source_mapped": "",
"industry": "",
"industry_mapped": "",
"staff_size": 0,
"staff_size_display": "",
"staff_size_mapped": "",
"created_at": "2015-07-03 17:31",
"updated_at": "2015-09-24 16:48",
"is_own": true,
"attachments": "暂无附件",
"company_name": "",
"text_asset_9320d8d7": "",
"text_asset_22503a16": "",
"numeric_asset_e2955b70": 123,
"numeric_asset_8ea55cf0": 1.1,
"is_has_policy_for_assist_user": true,
"address": {
"id": 1076,
"country": {
"id": 4,
"name": "中国",
"pinyin": null
},
"province": {},
"city": {},
"district": {},
"tel": "010-64881989",
"phone": "",
"email": "zhaoning@web.com",
"qq": "18888896",
"fax": "",
"wechat": "weixinsadfasw",
"wangwang": "288888897",
"zip": "100008",
"url": "",
"detail_address": "北京市朝阳区朝阳门外大街18号丰联广场A座第9层",
"lat": 0,
"lng": 0,
"distance": "0m",
"region_info": "中国",
"off_distance": 0,
"country_id": 0,
"province_id": 0,
"city_id": 0,
"district_id": 0
},
"user": {
"id": 2,
"email": "wp@qq.com",
"created_at": "2015-06-10T11:06:45.000+08:00",
"name": "test",
"organization_id": 1,
"phone": "15921076830",
"role_id": 0,
"workflow_state": "organization_staff",
"job": "",
"tel": "",
"gender": "male",
"avatar_url": "http://192.168.10.99:3000/assets/male.jpg",
"confirmed_phone_at": ""
},
"owned_department": {
"id": 2,
"name": "销售部"
}
}
}
错误时返回:
{
"code": 100000,
"message": "device参数错误",
"error": "invalid_app_error"
}
返回参数说明:
暂无
备注:
- 更多返回错误代码请看错误码表描述
文档更新时间: 2025-04-29 14:18 作者:陈胜海