根据用户自定义表单接收url,把表单数据发送到用户自有系统
对接步骤
- url设置:控制台->集成管理->表单自定义提交
- 创建表单作品,
- 用户使用表单作品提交表单
- 配置的url将接收到表单提交数据
接口规范
接收接口:用户自定义的url
请求格式:POST
Content-Type:application/json
接收参数:
字段 类型 说明 id Long 作品唯一标识 corpId Long 企业id title String 内容标题 type String 作品类型 h5:h5作品 lc:长页面 form:表单 formDataId Long 表单提交数据的唯一Id,后端提交时会携带该参数 formMeta.{elementId}.type String 表头类型 formMeta.{elementId}.title String 表头名称 formMeta.{elementId}.status Integer 表头状态 formMeta.{elementId}.delFlag Boolean 表头是否删除(true:已删除 false:未删除) formMeta.{elementId}.options List 选项(根据type不同,返回值有所区别,见详细说明) formMeta.{elementId}.score String 计分组件选项信息(json字符串,根据type不同,返回值有所区别,见详细说明) ua.ua String 浏览器请求原始user-agent ua.os String 设备系统信息 ua.device String 设备信息 ua.browser String 浏览器信息 ua.ip String ip地址 dataInfo.status Integer 数据状态 dataInfo.costTime Long 表单提交耗时 dataInfo.star Integer 星级 dataInfo.delFlag Boolean 该表单数据是否删除(true:已删除 false:未删除) data.{elementId} String 表单值(elementId:对应表头formMeta.elementId) customerInfo.encodeId Srtring 用户唯一标识【易企秀】 customerInfo.type int 授权用户类型,1微信,2手机,3自定义 customerInfo.corpId String 企业唯一标识 customerInfo.nickName String 微信昵称,userType为1时 customerInfo.mobile String 手机号,userType为2时 customerInfo.sex String 微信性别,userType为1时 customerInfo.language String 微信信息,userType为1时 customerInfo.city Integer 微信信息,userType为1时 customerInfo.country String 微信信息,userType为1时 customerInfo.headImgUrl String 微信信息,userType为1时 customerInfo.unionId String 微信信息,unionId customerInfo.appIdType Integer appId类型,1、易企秀 ;非 1,非易企秀 customerInfo.thirdAppId String 微信信息,appId customerInfo.thirdOpenId String 微信信息,openId 返回参数:
正确时返回:错误时返回:
接口要求
- 前端保存
需支持跨域访问(因为数据不经过易企秀后台,由前端直接传输,会有跨域问题)
demo:
- 前端保存
- 后端保存
后端保存的数据会加密,解密方式同事件的一致
- 后端保存