概述
SViewService API 为用户介绍了云服务接口的调用方法和详细说明,帮助第三方调用云服务接口。云服务各功能模块的集成请查看云服务集成文档。
约定
- 接口名采用骆驼命名法。
- 接口参数及接口返回Json串的键名使用小写字母加下划线格式如:"modify_time"。
-
version=版本号mroot=https://service.sv3d.cn/versiondispatchroot=http://转换队列IP地址/versionconvertroot=http://分布式转换服务IP地址/version
环境配置
- 内存:16G或以上。
- 硬盘:200G或以上。
- 系统:Windows Server 2012R2或以上。
- 数据库:Mysql 5.5.28。
返回值
| 模块 | 返回码 | 描述 |
|---|---|---|
| 全局参数 | -1 | 操作失败 |
| 0 | 接口调用成功 | |
| 1 | 参数不得为空(参数为空或者参数名传错) | |
| 2 | 参数值传值错误 | |
| 3 | 文件不存在 | |
| 4 | 文件上传失败 | |
| 10001 | 返回结果异常 | |
| 10002 | 远程服务返回的数据无法解析 | |
| 10003 | 文件不存在,查询异常 | |
| 性能改进 | 1001 | 文件解压失败 |
| 1002 | 数据库保存失败 | |
| 1003 | 压缩异常 | |
| 1004 | 压缩文件不合法,可能被损坏 | |
| 1005 | 生成文件错误 | |
| 1006 | IO异常 | |
| 1007 | 无权限删除他人视图 | |
| 1008 | 无权限修改他人视图 | |
| 1009 | 文件重命名失败 | |
| 1010 | 文件读取失败 | |
| 1011 | 视图图片或视图文件不能为空 | |
| 9001 | 文件不存在 | |
| 授权服务模块 | 2003 | 您的试用申请已达上限 |
| 2004 | 无可用点数 | |
| 2006 | 许可信息不存在 | |
| 2007 | 产品名称不匹配 | |
| 2008 | 主版本号不匹配 | |
| 2009 | 令牌已过期 | |
| 2010 | 授权还没开始 | |
| 2011 | 授权已到期 | |
| 2012 | 无权限 | |
| 2013 | 认证模式不匹配 | |
| 2014 | MAC地址不匹配 | |
| 2015 | 许可文件重复上传 | |
| 2016 | 文件上传失败 | |
| 2017 | 许可不存在 | |
| 2018 | 许可已禁止使用 | |
| 2019 | 您已被禁止访问 | |
| 2020 | 许可认证失败 | |
| 2021 | 许可签名不匹配 | |
| 2022 | 令牌与客户端不匹配 | |
| 2023 | 令牌与认证产品不匹配 | |
| 2024 | 许可申请信息不存在 | |
| 2025 | 邮件发送失败 | |
| 2026 | 产品版本号格式错误 | |
| 2027 | 该产品已存在 | |
| 2028 | 该产品及版本已存在 | |
| 2029 | 仅允许导入许可文件 | |
| 2030 | 客户端许可不支持导入 | |
| 2031 | 许可ID无效 | |
| 2032 | 许可产品不匹配 | |
| 2033 | 许可ID不匹配 | |
| 2034 | 产品或该产品版本不存在 | |
| 用户服务模块 | 3001 | 用户名或密码错误 |
| 3002 | 缺少登录凭证 | |
| 3003 | 用户未登录 | |
| 3004 | 用户不存在 | |
| 3005 | 用户名已注册 | |
| 3006 | 原密码错误 | |
| 3007 | 用户名只能修改一次 | |
| 3008 | 游客账号不允许修改 | |
| 3009 | 非管理员,无权操作 | |
| 3010 | 游客账号不允许修改 | |
| 3011 | 登录凭证已失效 | |
| 文档服务模块 | 4001 | 文件/文件夹不存在 |
| 4002 | 上传文件大小超过最大允许大小 | |
| 4003 | 空间不足 | |
| 4004 | 引用文件不存在 | |
| 4005 | 请选择需要移动的文件/文件夹 | |
| 4006 | 不能将文件夹移动到自身目录下 | |
| 4007 | 不能移动到同一个文件夹下,请选择其他文件夹 | |
| 4008 | 不能将文件夹移动到子目录下 | |
| 4009 | 文件/文件夹名重复,重命名失败 | |
| 4010 | 不能将文件/文件夹移动到他人目录下 | |
| 4011 | 不能移动别人文件/文件夹 | |
| 4012 | 不能重命名别人文件/文件夹 | |
| 4013 | 请选择需要删除的文件/文件夹 | |
| 4014 | 不能解压别人文件/文件夹 | |
| 4015 | 解压失败,仅支持.zip,.rar格式 | |
| 4016 | 解压失败 | |
| 4017 | 文件夹名重复,创建失败 | |
| 4018 | 含有不存在的文件或文件夹 | |
| 4019 | 文件总大小超过最大下载限制500M | |
| 7001 | 图片或模型不得为空 | |
| 1012 | 合并/打包的文件需要放置到单独文件夹中 | |
| 1013 | 不能上传文件夹 | |
| 产品服务模块 | 5001 | 请选择图片 |
| 5002 | 产品已存在 | |
| 5003 | 产品版本号格式不正确 | |
| 5004 | 没有找到对应产品 | |
| 5005 | 无权限访问产品页 | |
| 会议服务模块 | 6001 | 会议已存在 |
| 6002 | 会议不存在 | |
| 6003 | 会议已经结束 | |
| 6004 | 引用文件不存在 | |
| 6005 | 文件上传失败 | |
| 6006 | 会议中无协同模型 | |
| 转换服务模块 | 8003 | 不支持的转换 |
| 8004 | 模型正在转换中 | |
| 8005 | 源文件已删除 | |
| 8006 | 任务已删除 | |
| 8007 | 等待中和转换中的任务不能重新转换 | |
| 8008 | 只允许置顶等待中的任务 | |
| 8009 | 日志文件不存在 | |
| 8010 | 无相同输出格式 | |
| 8012 | 结束时间早于开始时间 | |
| 8013 | 任务创建失败 | |
| 8014 | 转换服务已关闭 | |
| 8015 | 无可转换点数 | |
| 8017 | 无当前转换任务 | |
| 转换状态 | 1 | 转换中 |
| 2 | 等待中 | |
| 3 | 停止 | |
| 4 | 失败(失败时同时会返回失败原因码,具体见下方) | |
| 5 | 成功 | |
| 转换失败原因 | 4003 | 空间不足 |
| 8001 | 转换异常 | |
| 8002 | 转换超时 | |
| 8016 | 文件下载异常 | |
| 8018 | 无输出文件 | |
| 8019 | 文件保存异常 | |
| -1 | 内存不足 | |
| -2 | 打开文件失败 | |
| -4 -26 | 许可验证错误,无转换许可 | |
| -5 | 输入文件不存在 | |
| -6 | 输出路径不存在 | |
| -13 | 转换参数错误 | |
| -22 | 读取输入文件失败 | |
| -23 | 生成文件失败 | |
| -27 | 该类型格式版本不支持 | |
| -28 | 文件不存在 | |
| -30 | 未知的文件类型 | |
| -31 | 文件已损坏 | |
| -32 | 空文件 | |
| -1000 | 不支持的转换类型 | |
| -1001 | 未知错误 | |
| 转换队列 | 90001 | 服务连接失败 |
| 90002 | 没有可用服务 | |
| 90003 | 转换任务数据不存在 | |
| 90004 | 该任务不允许当前操作 | |
| 90005 | 该任务参数错误 | |
| 90006 | 当前任务不存在 | |
| 90007 | 服务已下线 | |
| 90008 | 回调成功 | |
| 90009 | 服务在线状态下不能删除 | |
| 90010 | 服务在使用状态下不能删除 | |
| 菜单权限 | 11001 | 存在子菜单,不允许删除 |
| 11002 | 菜单已分配,不允许删除 | |
| 11003 | 新增菜单失败,菜单名称已存在 | |
| 11101 | 新增角色失败,角色名称已存在 | |
| 11102 | 新增角色失败,角色代码已存在 | |
| 11103 | 修改角色失败,角色名称已存在 | |
| 11104 | 修改角色失败,角色代码已存在 | |
| 11105 | 此角色已分配,不能删除 | |
| 11106 | 管理员账号不能被禁用 | |
| 11107 | 管理员账号不能修改用户名和角色 |
接口列表
产品服务
获取产品最新版本
接口链接
mroot/product/get
接口版本
7.1
说明
获取产品最新版本
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| product | 是 | String | 产品名: "SView for iOS Enterprise", "SView for Android Enterprise-32Bit", "SView for Android Enterprise-64Bit", "SView for Windows Enterprise-32Bit", "SView for Windows Enterprise-64Bit", "SView Designer Enterprise-32Bit", "SView Designer Enterprise-64Bit", "SView Converter Enterprise-32Bit", "SView Converter Enterprise-64Bit", "SView for HTML5 Enterprise" |
| type | 是 | String | 版本类型:"0"开发版、"1"正式版 |
返回值(JSON):
成功:
{
"return":"0",
"description":"1、修复漫游复位缺陷...",
"productid": "280d00ba-27e4-4bf8-8a6d-532a0dca33bc",
"size": "15146647",
"version": "7.1",//获取的调用接口接口版本号
"productversion": "6.2.1.1"//产品版本号
}
失败:
{
"return":"1",//1或5004
"msg":"参数不得为空!"
}
备注
无
下载产品
接口链接
mroot/product/download
接口版本
7.1
说明
下载产品
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| productid | 是 | String | 产品id |
返回值(stream):
成功:
{
输出文件流
}
失败:
{
"return":"1",//1或3
"msg":"参数不得为空!"
}
备注
无
用户服务
用户登录
接口链接
mroot/user/login
接口版本
7.1
说明
客户端使用用户名跟密码登录
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| name | 是 | String | 用户名 |
| password | 是 | String | 密码 |
| deviceid | 是 | String | 设备硬件号 |
| devicetype | 是 | String | 设备类型("Windows","Web","H5",移动端传设备型号) |
| customtype | 是 | String | 客户端类型1、安卓 2、iOS 3、windows 4、H5 5、Web |
| loginip | 是 | String | 登录设备ip |
返回值(JSON):
成功:
{
"return":"0",
"onlineid":"8d2c7c6c-e7aa-49ba-83e2-ce609dd7888b",//登录凭证
"user": {
"createtime": "2019-07-26",
"id": "ec8d67c9-4682-40bb-a92d-658417982c23",
"ischangename": 0,//是否修改过用户名0未修改1修改
"level": "1",//用户类型:0管理员,1普通
"name": "abcdefg",
"nickname": "abcdefg",
"photo": "http://.../nophoto.jpg",
"type": "0",//账户类型0普通账户1企业账户
"usedspacesize": 494403864,
"userspacesize": 524288000,
"menuNum":99,
"isprohibit": 0,
"isdelete": 0
}
}
失败:
{
"return":"1",//1、3001
"msg":"参数不得为空!"
}
备注
无
查询用户信息
接口链接
mroot/user/info
接口版本
7.1
说明
查询客户信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
返回值(JSON):
成功:
{
"return":"0",
"user": {
"createtime": "2019-07-26":
"customid": "",
"id": "ec8d67c9-4682-40bb-a92d-658417982c23",
"ischangename": 0,//是否修改过用户名0未修改1修改
"level": "1",//用户类型:0管理员,1普通
"name": "abcdefg",
"nickname": "abcdefg",
"photo": "http://.../nophoto.jpg",
"type": "0",//账户类型0普通账户1企业账户
"userspacesize": 524288000,
"usedspacesize": 985032,
"isprohibit": 0,
"isdelete": 0,
"menuNum": 99
}
}
失败:
{
"return":"1",//1、3010、3011、3004
"msg":"参数不得为空!"
}
备注
无
退出登录
接口链接
mroot/user/logout
接口版本
7.1
说明
退出登录
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
返回值(JSON):
成功:
{
"return":"0",
}
失败:
{
"return":"1",//3002、3003
"msg":"参数不得为空!"
}
备注
无
修改用户信息
接口链接
mroot/user/update
接口版本
7.1
说明
修改用户信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| name | 是 | String | 修改后的用户名,未修改则传原用户名 |
| nickname | 是 | String | 修改后的昵称,未修改则传原昵称 |
返回值(JSON):
成功:
{
"return":"0",
}
失败:
{
"return":"1",//1、3010、3011、3004、3008、3005、3007
"msg":"参数不得为空!"
}
备注
无
修改用户头像
接口链接
mroot/user/updatephoto
接口版本
7.1
说明
修改用户头像,onlineid需要用get方式传参
参数:(GET)
multipart/form-data
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证,get方式传参 |
| image | 是 | 文件流 | 用户头像 |
返回值(JSON):
成功:
{
"return":"0",
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
修改密码
接口链接
mroot/user/changepass
接口版本
7.1
说明
修改密码
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| password | 是 | String | 原密码 |
| newpassword | 是 | String | 新密码 |
返回值(JSON):
成功:
{
"return":"0",
}
失败:
{
"return":"1",//1、3010、3011、3004、3008、3006
"msg":"参数不得为空!"
}
备注
无
文档服务
注:文档服务是用来管理系统文件的服务,其中包括管理用户的个人文件/文件夹,每个用户默认有500M的个人空间。
个人空间中,文件夹id="0"表示根目录
引用
接口链接
mroot/file/reference
接口版本
7.1
说明
客户端向个人空间提交文件时,首先发送此请求,如果服务器返回文件不存在,再发送真实上传模型的请求。
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| filename | 是 | String | 上传的文件名 |
| pfolderid | 是 | String | 所在文件夹id,0表示根目录 |
| md5 | 是 | String | 文件MD5 |
| filesize | 是 | String | 文件大小,字节 |
返回值(JSON):
成功:
{
"return":"0",
"userfileid":"8d2c7c6c-e7aa-49ba-83e2-ce609dd7888b",//云盘中用户文件id
"fileid":"280d00ba-27e4-4bf8-8a6d-532a0dca33bc"//用户文件对应的源文件id
}
失败:
{
"return":"1",//1、3010、3011、4001、4002、4003、4004
"msg":"参数不得为空!"
}
备注
无
上传
接口链接
mroot/file/upload
接口版本
7.1
说明
onlineid需要用get方式传参。
参数:(GET)
multipart/form-data
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| modelfile | 是 | 文件流 | 上传的文件 |
| pfolderid | 是 | String | 所在文件夹id,0表示根目录 |
返回值(JSON):
成功:
{
"return":"0",
"userfileid":"8d2c7c6c-e7aa-49ba-83e2-ce609dd7888b",//云盘中用户文件id
"fileid":"280d00ba-27e4-4bf8-8a6d-532a0dca33bc"//用户文件对应的源文件id
}
失败:
{
"return":"1",//1、3010、3011、4001、4003、7001
"msg":"参数不得为空!"
}
备注
无
获取用户文件列表
接口链接
mroot/file/userfilelist
接口版本
7.1
说明
获取某一级文件夹下的文件列表
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| folderid | 否 | String | 所在文件夹id,为空时默认根目录 |
| searchcontent | 否 | String | 搜索内容(文件/文件夹名) |
| orderby | 否 | String | 根据什么排序1、文件名2、大小3、修改日期,默认为“3” |
| ordertype | 否 | String | 排序方式1、升序2降序,默认降序 |
返回值(JSON):
成功:
{
"return":"0",
"files": [
{
"id": "303606d9-b1e7-48c7-b1e1-5f7e122cb36a",
"modifytime": "2019-07-26 11:18:14",//修改时间
"name": "bbb",//文件夹名
"type": "1"//类型0文件1文件夹
},
{
"fileid": "cac6c1be-126a-41ff-87cc-301b3090e64c",
"filesize": 40780,
"filetype": "svlx",
"id": "e5052105-d504-4302-8b60-20af7bb1080a",
"isallowedconvert": "0",//是否允许添加到格式转换0不允许1允许
"md5": "414398f6941d5252df4146f560b2fd24",
"modifytime": "2019-07-26 11:18:14",
"name": "3d_pmi.svlx",
"type": "0"//类型0文件1文件夹
"input": "SVL2.0"//文件类型
},{...}
]
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取样例模型列表
接口链接
mroot/file/samplelist
接口版本
7.1
说明
获取样例库
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| pagenum | 否 | int | 页码,默认1 |
| pageRecorders | 否 | int | 每页显示个数,默认12 |
| searchcontent | 否 | String | 模型标题 |
返回值(JSON):
成功:
{
"return":"0",
"list": [
{
"createtime": "2019-07-24 08:26:21",
"description": "3d_pmi",
"filename": "3d_pmi.svlx",
"filesize": 40780,
"id": "5650dd73-aa52-49b3-8d44-87af4a4bd325",//样例模型id
"image": "http://.../3d_pmi.png",
"md5": "414398f6941d5252df4146f560b2fd24",
"fileid": "cac6c1be-126a-41ff-87cc-301b3090e64c",
"name": "3d_pmi"
},
{...}
]
}
备注
无
移动文件/文件夹
接口链接
mroot/file/move
接口版本
7.1
说明
移动文件/文件夹
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| ids | 是 | String | 文件/文件夹id字符串,多个中间用逗号隔开 |
| targetfolderid | 是 | String | 目标文件夹id,0表示根目录 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、4001、4005、4010、4011、4007、4006、4008
"msg":"参数不得为空!"
}
备注
无
重命名文件/文件夹
接口链接
mroot/file/rename
接口版本
7.1
说明
重命名文件/文件夹
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| userfileid | 是 | String | 文件/文件夹id |
| newname | 是 | String | 新名字 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、4001、4012、4009
"msg":"参数不得为空!"
}
备注
无
删除文件/文件夹
接口链接
mroot/file/remove
接口版本
7.1
说明
删除文件/文件夹
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| ids | 是 | String | 文件/文件夹id字符串,多个中间用逗号隔开 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、4013
"msg":"参数不得为空!"
}
备注
无
解压文件
接口链接
mroot/file/unzip
接口版本
7.1
说明
解压文件,只支持.zip跟.rar格式的压缩包,且压缩包无密码
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| userfileid | 是 | String | 需要解压的用户文件id |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、4001、4003、4014、4015、4016
"msg":"参数不得为空!"
}
备注
无
创建文件夹
接口链接
mroot/file/create
接口版本
7.1
说明
创建文件夹
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| pfolderid | 是 | String | 父文件夹id,0表示根目录 |
| name | 是 | String | 文件夹名 |
返回值(JSON):
成功:
{
"return":"0",
"folderid":"8d2c7c6c-e7aa-49ba-83e2-ce609dd7888b"//新创建的文件夹id
}
失败:
{
"return":"1",//1、3010、3011、4001、4017
"msg":"参数不得为空!"
}
备注
无
获取目录
接口链接
mroot/file/catalogue
接口版本
7.1
说明
移动文件/文件夹时,获取目录结构
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| pfolderid | 是 | String | 父文件夹id,0表示根目录 |
| folders | 是 | String | 选中的文件/文件夹id字符串,多个中间用逗号隔开 |
返回值(JSON):
成功:
{
"return":"0",
"folders": [
{
"createtime": "2019-07-26 14:09:31",
"filename": "ddd",
"id": "b9fa77c5-91fb-4c74-b138-af19972a00f3",
"isdelete": 0, //0未删除1删除
"modifytime": "2019-07-26 14:09:31",
"pfileid": "0", //参数废弃
"pfolderid": "0",
"type": "1", //类型0文件1文件夹
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
},
{
"createtime": "2019-07-26 11:11:50",
"filename": "aaa",
"id": "feb8880f-43bc-41f6-84c5-9463edeedd84",
"isdelete": 0,
"modifytime": "2019-07-26 11:11:50",
"pfileid": "0",
"pfolderid": "0",
"type": "1",
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
},{....}
]
}
失败:
{
"return":"1",// 1、3002、3003
"msg":"参数不得为空!"
}
备注
无
下载个人文件
接口链接
mroot/file/downloaduserfile
接口版本
7.1
说明
支持多文件以压缩包形式下载
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| ids | 是 | String | 文件/文件夹id字符串,多个中间用逗号隔开 |
返回值(stream):
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1或3
"msg":"参数不得为空!"
}
备注
无
下载样例模型
接口链接
mroot/file/downloadsample
接口版本
7.1
说明
下载样例模型
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| modelid | 是 | String | 样例模型id |
返回值(stream):
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1或3
"msg":"参数不得为空!"
}
备注
无
下载源文件
接口链接
mroot/file/downloadsource
接口版本
7.1
说明
下载源文件,扫码下载时需要调用此接口下载文件
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| fileid | 是 | String | 源文件id |
返回值(stream):
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1或3
"msg":"参数不得为空!"
}
备注
无
获取模型PMI数据
接口链接
mroot/file/getTextMeshAll
接口版本
7.1
说明
获取模型PMI数据
参数:(输入流)
例:
[
{"pmiID":1,"comTextID":0,"ctextID":0,"text":"⌀"},
{"pmiID":1,"comTextID":0,"ctextID":1,"text":"20"}
]
返回值:
成功:
[
{"vertexs":"数组","indexes":"数组","text":"0","pmiID":1,"comTextID":"0","CTextID":1},
{"vertexs":"数组","indexes":"数组","text":"0","pmiID":1,"comTextID":"0","CTextID":1}
]
备注
无
转换服务
注:将云盘中允许转换的文件添加到转换队列进行转换,支持转换任务的停止、置顶等操作。
1:转换中 2:等待中 3:已停止 4:失败 5:转换成功
获取输入类型
接口链接
mroot/convert/config/inputs
接口版本
7.1
说明
根据用户文件类型获取输入类型,如果inputs为空则获取所有输入类型,否则取所有输入类型的并集
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| inputs | 否 | String | 需要转换的用户文件类型字符串,多个类型用逗号隔开(例:"STEP,SVL1.0,UG NX 3D") |
返回值(JSON):
成功:
{
"return":"0",
"inputs": [ //多个输入类型时结果自动取并集
{
"input": "3DXML",
"inputformat": "3DXML (*.3dxml)"
},
{
"input": "3MF",
"inputformat": "3MF (*.3mf)"
},
{
"input": "ACIS",
"inputformat": "ACIS(*.sat)"
},
{
"input": "Catia V4",
"inputformat": "Catia V4(*.model)"
},
{
"input": "Catia V5 3D",
"inputformat": "Catia V5 3D (*.CATPart;*.CATProduct)"
},
{
"input": "CGR",
"inputformat": "CGR(*.cgr)"
},
{
"input": "IGES",
"inputformat": "IGES(*.igs)"
}
]
}
失败:
{
"return":"1",//1、3010、3011
"msg":"参数不得为空!"
}
备注
无
获取输出类型
接口链接
mroot/convert/config/outputs
接口版本
7.1
说明
根据用户文件类型获取可以转换出的类型,inputs为空时默认获取所有输出类型
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| inputs | 否 | String | 需要转换的用户文件类型字符串,多个类型用逗号隔开(例:"STEP,SVL1.0,UG NX 3D") |
返回值(JSON):
成功:
{
"return":"0",
"outputs": [ //多个输入类型时结果自动取交集
{
"output": "3DXML",
"outputformat": "3DXML (*.3dxml)"
},
{
"output": "3MF",
"outputformat": "3MF (*.3mf)"
},
{
"output": "ACIS",
"outputformat": "ACIS(*.sat)"
},
{
"output": "Catia V4",
"outputformat": "Catia V4(*.model)"
},
{
"output": "Catia V5 3D",
"outputformat": "Catia V5 3D (*.CATPart;*.CATProduct)"
},
{
"output": "CGR",
"outputformat": "CGR(*.cgr)"
},
{
"output": "IGES",
"outputformat": "IGES(*.igs)"
}
]
}
失败:
{
"return":"1",//1、3010、3011、8010
"msg":"参数不得为空!"
}
备注
无
获取默认输入类型
接口链接
mroot/convert/config/defaultInput
接口版本
7.1
说明
用户默认输入类型为空时,自动获取系统默认输入类型
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
返回值(JSON):
成功:
{
"return":"0",
"input": "UG NX 3D"
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取默认输出类型
接口链接
mroot/convert/config/defaultOutput
接口版本
7.1
说明
用户默认输出类型为空时,自动获取系统默认输出类型
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
返回值(JSON):
成功:
{
"return":"0",
"output": "SVL2.0"
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取转换配置文件内容
接口链接
mroot/convert/config/get
接口版本
7.1
说明
获取顺序 根据configid获取--》获取用户默认配置--》获取系统默认配置
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| configid | 否 | String | 配置id |
| input | 否 | String | 输入类型(例:UG NX 3D) |
| output | 否 | String | 输出类型(例:SVL2.0) |
注:configid跟输入输出类型不能同时为空
返回值(JSON):
成功:
cadexchanger配置文件返回值如下:
{
"return": "0",
"input": "STEP",
"output": "CGR",
"configname": "cadexchanger",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"asm_visibility": false,//装配显隐
"body_to_nurbs": false,//将所有的集合转换成nurbs
"catiaV52DConfig": {
"filter_detail_sheets": true//是否过滤细节表到CATDrawing文件
},
"catiaV5Config": {
"write_hybrid_bodies": false,//保存混合body
"write_ref_plane_as_hidden": true,//隐藏参考平面
"write_release": 14//输出版本R14 R15 R16 R17 R18 R19
},
"choose_axis": 0,
//Should we apply an axis placement ?
//[-1] : Use Default, [0] : Use None, [1] : Open box
"choose_in_assembly_tree": 0,
//[-1] : Use Default, [0] : Use None,
//[1] : Open box
"choose_in_catalog": -1,
//Should we convert all part configuration ?
//[-1] : Convert Default, [0] : Convert All,
//[1] : Open box
"choose_layer_filter": 0,
//Should we apply a layer filter ?
//[-1] : Use Default,
//[0] : Use None, [1] : Open box
"choose_referenceset_filter": 0,
//Should we apply a referenceset ?
//[0] : Use None, [1] : Open box
"colladaConfig": {
"explode_entities": false,
"keep_dtk_tree": true,
"no_instance_node": true,
"reverse_transparency": false,
"use_vertex_color": false,
"version": 141
},
"construct_solids": true,
"courbe_lim_3d": 0,
//Which trimming curves should we setup ?
//1 : Only 2D curves
//2 : Boths 2D+3D
//3 : Only 3D curves
"draw": false,
"explose_group": true,
//Should we write a group for faces
//in same solid if KEEP_ASSEMBLY = 0 ?
//[1] : no, [0] : yes
"fdt": true, //是否忽略PMI信息,true代表忽略
"fdt_visibility": false,//PMI显隐
"features": true,
"filaire": true,//是否移除边界线
"geom_link": true,
//Should we ignore geometrical links for highlightning?
//[1] : Yes, [0] : No
"igesConfig": {
"bound_preference": 2,
//Which boundary curves should we read ?
//2 : Priority to UV boundary curves
//3 : Priority to 3D boundary curves
"name_as_406": false//将实体名称设置为406
},
"jtConfig": {
"jt_pmi_as_semantic": false,//PMI描述数据
"write_export_type": 0,
//Export type 输出类型
//[0] : Monolithic (default),
//[1] : Shattered, [2] : PerPart
"write_release": 80,
//Version output 输出版本
//[80] : version 8.0 (default), [95] : version 9.5
"write_strategy": 1,
//Assembly strategy
//[0] : Write components only (default), [1] : Write
//components and filled nodes
"write_xtbrep": false
//Should we write ParasolidBRep
//in the JT file ?//输出精确数据
//[1] : Yes , [0] : No (default)
},
"keep_assembly": true,//保留装配信息
"merge_bodies": false,//合并body
"mesh": true,
"meta_parameters": true,//是否忽略模型属性
"model_display": false,//是否忽略自定义视图
"nb_decimale": 10.0,
"par_solide": false,/每个body输出一个文件
"parasolidConfig": {
"use_part_name": false,//把零件名称设置到body上
"write_body_attributes": true//填充body属性
},
"pdfConfig": {
"geo_format": 0,
//Should we write tesselated data or brep data ?//几何格式
//[0] : Mesh (Default), [1] : BRep, [2] : Mesh + BRep
//BRep is only available when writing PRC
"monochrome_display": false,//Should we export as monochrome display ?
"rasterize_texts": true,//文本折线化
"truetype_font": ""C:\Windows\Fonts\unifont_0.ttf"",
"write_prc": true//内嵌prc
},
"per_catalog": false,//每个catalog输出一个文件
"referentiel": true, //坐标系
"remove_nodes": false,
"render_infos": true,
"solidworksConfig": {
"multy_body": true//读取所有body
},
"stepConfig": {
"read_component_name": 1,
"read_fdt": 0,
//step reader PMI
//integer Drives Reading of FDT
//(0=no 1=graphic only 2=graphic + semantic)
"validation_property": 0,
//step reader 验证属性
//integer Drives Computing/Checking of
//Validation Propeties (Read & Write)
//[0] : no
//[1] : computes simple validation properties
//[2] : computes geometric validation properties
//(except clouds of points)
//[3] : computes also clouds of points
"write_fdt": 1,
//step write PMI
//integer Drives Writing of FDT
//(0=no 1=semantic + graphic 2=semantic only 3=graphic only)
"write_fdt_polyline": 0,
//step write PMI折线化
//integer Selects mode for graphic output
//(0=default 1=minimal graphic
//2=polyline 3=2D tesselation 4=3D tesselation)
"write_itemname": 2,
//step write item名称
//integer Writes Names of Items (topological items)
//[0] : no (empty name)
//[1] : name from CAD if defined, else empty
//[2] : "n?iii" : ID from CAD
//[3] : "no iii" : ID from CAD
"write_ln_unit": 0,
"write_property": 0,
//step write 属性
//integer Writes Attributes and Properties
//[0] : no
//[1] : Product Data
//[2] : also general attributes(metadata)
//except "File Property"
//[3] : all general attributes, also "File Property"
"write_version": 0
//step write 输出版本
//integer Writes Step Version
//(0=AP214 or AP203E2 with FDT
//1=AP203 2=AP214 3=AP203E2 4=AP242)
},
"tessellationConfig": {
"angular_dis": false,//是否忽略角度公差
"angular_tol": 10.0,//角度公差值
"compute_boundaries_from_mesh": true,
"compute_normales_from_surface": true,
"linear_dis": false,//是否忽略折线公差
"linear_tol": 0.1,//折线公差值
"maxsize": "100000000000000010000000000000000000000000000000000.0000000",
"minsize": 0.0,
"ratio": 10000.0,
"use_tessel": false,//是否忽略优先使用模型中的轻量化数据
"write_ascii": false
},
"tol_continuite": 0.01,
"visibility": false,//零件显隐
"write_log_file": true,//日志
"write_lst_file": false
}
}
cadconverter配置文件返回值如下:
{
"return": "0",
"input": "STEP",
"output": "SVL2.0",
"configname": "cadconverter",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"angle_tolerance": 30.0,//角度公差
"boundaryline": true,//边界线
"cable": true,//线缆
"cablesheath": false,//线鞘
"compress": 1,//压缩模式0、不压缩1、快速压缩2、高质量压缩
"custom_lod": false,//是否使用自定义LOD设置
"customview": true,//自定义视图
"debuginfo": false,//输出PMI调试信息(开发人员使用)
"forcetess": true,//使用SView的分元
"hiddenobject": false,//隐藏对象
"layer": false,//图层
"line_tolerance": 5.0,//折线公差
"log": 1,//输出日志0、不输出1、普通用户2、高级用户3、开发人员
"merge": 0,
"mesh_merge": 0,Mesh合并0、不合并1、合并
"model_compare": false,//模型比较(适合Pro/E二次开发使用)
"model_property": false,
"only_current": false,//只转换当前
"outputmode": 0,//输出方式0、单一文件1、分散文件
"pmi": true,// PMI
"preview": false,//缩略图
"snapshot": true,//输出快照文件
"spaceline": false,//空间线
"spacespot": false//空间点
}
}
rvmconverter配置文件返回值如下:
{
"return": "0",
"input": "RVM",
"output": "SVL2.0",
"configname": "rvmconverter",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"angulartolerance": 30.0,//角度公差
"lineartolerance": 5.0//折线公差
}
}
svlx2fbx配置文件返回值如下:
{
"return": "0",
"input": "SVL2.0",
"output": "FBX(*.fbx)",
"configname": "svlx2fbx",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"fbxversion": "FBX binary (*.fbx)",//Fbx版本 FBX ascii (*.fbx) FBX 6.0 binary (*.fbx) FBX 6.0 ascii (*.fbx)
"upvector": 2,//上方向 X:1,Y:2,Z:3
"coordsystem": 0//坐标系 右手:0,左右:1
}
}
objconverter配置文件返回值如下:
{
"return": "0",
"input": "SVL2.0",
"output": "OBJ(*.obj)",
"configname": "objconverter",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"objversion": "OBJ (*.obj)"//OBJ版本 OBJ (*.obj)、OBJ VertexColor (*.obj)
}
}
plyconverter配置文件返回值如下:
{
"return": "0",
"input": "SVL2.0",
"output": "PLY(*.ply)",
"configname": "plyconverter",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"plyversion": "PLY Binary (*.ply)"//PLY版本 PLY Binary (*.ply)、PLY ASCII (*.ply)
}
}
stlconverter配置文件返回值如下:
{
"return": "0",
"input": "SVL2.0",
"output": "STL(*.stl)",
"configname": "stlconverter",//配置文件名字,可根据此区别是哪种配置文件
"config": {
"stlversion": "STL Binary (*.stl)"//STL版本 STL Binary (*.stl)、STL ASCII (*.stl)
}
}
失败:
{
"return":"1",//1、3010、3011、8003
"msg":"参数不得为空!"
}
备注
无
创建/修改转换配置
接口链接
mroot/convert/config/saveOrUpdate
接口版本
7.1
说明
创建转换配置或者修改转换配置
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| configid | 否 | String | 配置id,为空时执行创建操作 |
| input | 是 | String | 输入类型(例:UG NX 3D) |
| output | 是 | String | 输出类型(例:SVL2.0) |
转换配置相关参数:
1.cadexchanger配置参数
"cadexchanger.filaire":"true",//边界线
"cadexchanger.visibility":"false",//零件
"cadexchanger.asm_visibility":"false",//装配
"cadexchanger.fdt_visibility":"false",//PMI
"cadexchanger.model_display":"false",//自定义视图
"cadexchanger.meta_parameters":"true",//模型属性
"cadexchanger.use_tessel":"false",//优先使用模型中轻量化数据
"cadexchanger.fdt":"true",//PMI
"cadexchanger.par_solide":"false",//每个Body输出一个文件
"cadexchanger.per_catalog":"false",//每个Catalog输出一个文件
"cadexchanger.write_log_file":"true",//日志
"cadexchanger.linear_tol":"0.1",//折线公差
"cadexchanger.angular_tol":"10",//角度公差
"cadexchanger.body_to_nurbs":"false",//将所有的几何转换成Nurbs
"cadexchanger.keep_assembly":"true",//保留装配信息
"cadexchanger.merge_bodies":"false",//合并Body
"cadexchanger.name_as_406":"false",//将实体名称设置为406
"cadexchanger.write_body_attributes":"true",//填充Body属性
"cadexchanger.use_part_name":"false",//把零件名称设置到Body上
"cadexchanger.write_ref_plane_as_hidden":"true",//隐藏参考平面
"cadexchanger.write_hybrid_bodies":"false",//保存混合Body
"cadexchanger.write_release":"14",//输出版本14 15 16 17 18 19
"cadexchanger.multy_body":"true",//读取所有Body
"cadexchanger.read_fdt":"0",
//step read PMI
//integer Drives Reading of FDT
//(0=no 1=graphic only 2=graphic + semantic)
"cadexchanger.write_fdt":"1",
//step write PMI
//integer Drives Writing of FDT
//(0=no 1=semantic + graphic
//2=semantic only 3=graphic only)
"cadexchanger.write_fdt_polyline":"0",
//step write PMI折线化
//integer Selects mode for graphic output
//(0=default 1=minimal graphic
//2=polyline 3=2D tesselation 4=3D tesselation)
"cadexchanger.write_version":"0",
//输出版本
//integer Writes Step Version
//(0=AP214 or AP203E2 with FDT
//1=AP203 2=AP214 3=AP203E2 4=AP242)
"cadexchanger.write_itemname":"2",
//Item名称
//integer Writes Names of Items (topological items)
//[0] : no (empty name)
//[1] : name from CAD if defined, else empty
//[2] : "n?iii" : ID from CAD
"cadexchanger.write_property":"0",
//step write 属性
//integer Writes Attributes and Properties
//[0] : no
//[1] : Product Data
//[2] : also general attributes(metadata)
//except "File Property"
//[3] : all general attributes, also "File Property"
"cadexchanger.rasterize_texts":"true",//文本折线化
"cadexchanger.write_prc":"true",//内嵌Prc
"cadexchanger.geo_format":"0",
//几何格式
//[0] : Mesh (Default),
//[1] : BRep, [2] : Mesh + BRep
"cadexchanger.jt_pmi_as_semantic":"false",//PMI描述数据
"cadexchanger.write_xtbrep":"false",//输出精确数据
"cadexchanger.jtwrite_release":"80",
//输出版本
//[80] : version 8.0 (default),
//[95] : version 9.5
"cadexchanger.write_export_type":"0"
//输出类型
//[0] : Monolithic (default),
//[1] : Shattered, [2] : PerPart
2.cadconverter配置参数
"cadconverter.boundaryline":"true",//边界线
"cadconverter.hiddenobject":"true",//隐藏对象
"cadconverter.spacespot":"true",//空间点
"cadconverter.spaceline":"true",//空间线
"cadconverter.customview":"true",//自定义视图
"cadconverter.model_property":"true",//模型属性
"cadconverter.cable":"true",//线缆
"cadconverter.cablesheath":"true",//线鞘
"cadconverter.layer":"true",//图层
"cadconverter.pmi":"true",// PMI
"cadconverter.forcetess":"true",//使用SView的分元
"cadconverter.preview":"true",//缩略图
"cadconverter.only_current":"true",//只转换当前
"cadconverter.line_tolerance":"5",//折线公差
"cadconverter.angle_tolerance":"25",//角度公差
"cadconverter.outputmode":"0",//输出方式0、单一文件1、分散文件
"cadconverter.compress":"0",//压缩模式0、不压缩1、快速压缩2、高质量压缩
"cadconverter.mesh_merge":"0",//Mesh合并0、不合并1、合并
"cadconverter.snapshot":"true",//输出快照文件
"cadconverter.log":"0",//输出日志0、不输出1、普通用户2、高级用户3、开发人员
"cadconverter.debuginfo":"true",//输出PMI调试信息(开发人员使用)
"cadconverter.model_compare":"true"//模型比较(适合Pro/E二次开发使用)
3.rvmconverter配置参数
"rvmconverter.lineartolerance":"5",//折线公差
"rvmconverter.angulartolerance":"25"//角度公差
4.svlx2fbx配置参数
"svlx2fbx.fbxversion":"FBX binary (*.fbx)",//Fbx版本 FBX ascii (*.fbx) FBX 6.0 binary (*.fbx) FBX 6.0 ascii (*.fbx)
"svlx2fbx.upvector":2,//上方向 X:1,Y:2,Z:3
"svlx2fbx.coordsystem":0//坐标系 右手:0,左右:1
5.objconverter配置参数
"objconverter.objversion":"OBJ (*.obj)"//OBJ版本 OBJ (*.obj)、OBJ VertexColor (*.obj)
6.plyconverter配置参数
"plyconverter.plyversion":"PLY Binary (*.ply)"//PLY版本 PLY Binary (*.ply)、PLY ASCII (*.ply)
5.stlconverter配置参数
"stlconverter.stlversion":"STL Binary (*.stl)"//STL版本 STL Binary (*.stl)、STL ASCII (*.stl)
返回值(JSON):
成功:
{
"return":"0",
"configid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
}
失败:
{
"return":"1",//1、3010、3011、2
"msg":"参数不得为空!"
}
备注
无
保存用户默认配置
接口链接
mroot/convert/config/saveDefault
接口版本
7.1
说明
保存用户默认配置
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| input | 是 | String | 输入类型(例:UG NX 3D) |
| output | 是 | String | 输出类型(例:SVL2.0) |
转换配置相关参数:
1.cadexchanger配置参数
"cadexchanger.filaire":"true",//边界线
"cadexchanger.visibility":"false",//零件
"cadexchanger.asm_visibility":"false",//装配
"cadexchanger.fdt_visibility":"false",//PMI
"cadexchanger.model_display":"false",//自定义视图
"cadexchanger.meta_parameters":"true",//模型属性
"cadexchanger.use_tessel":"false",//优先使用模型中轻量化数据
"cadexchanger.fdt":"true",//PMI
"cadexchanger.par_solide":"false",//每个Body输出一个文件
"cadexchanger.per_catalog":"false",//每个Catalog输出一个文件
"cadexchanger.write_log_file":"true",//日志
"cadexchanger.linear_tol":"0.1",//折线公差
"cadexchanger.angular_tol":"10",//角度公差
"cadexchanger.body_to_nurbs":"false",//将所有的几何转换成Nurbs
"cadexchanger.keep_assembly":"true",//保留装配信息
"cadexchanger.merge_bodies":"false",//合并Body
"cadexchanger.name_as_406":"false",//将实体名称设置为406
"cadexchanger.write_body_attributes":"true",//填充Body属性
"cadexchanger.use_part_name":"false",//把零件名称设置到Body上
"cadexchanger.write_ref_plane_as_hidden":"true",//隐藏参考平面
"cadexchanger.write_hybrid_bodies":"false",//保存混合Body
"cadexchanger.write_release":"14",//输出版本14 15 16 17 18 19
"cadexchanger.multy_body":"true",//读取所有Body
"cadexchanger.read_fdt":"0",
//step read PMI
//integer Drives Reading of FDT
//(0=no 1=graphic only 2=graphic + semantic)
"cadexchanger.write_fdt":"1",
//step write PMI
//integer Drives Writing of FDT
//(0=no 1=semantic + graphic
//2=semantic only 3=graphic only)
"cadexchanger.write_fdt_polyline":"0",
//step write PMI折线化
//integer Selects mode for graphic output
//(0=default 1=minimal graphic
//2=polyline 3=2D tesselation 4=3D tesselation)
"cadexchanger.write_version":"0",
//输出版本
//integer Writes Step Version
//(0=AP214 or AP203E2 with FDT
//1=AP203 2=AP214 3=AP203E2 4=AP242)
"cadexchanger.write_itemname":"2",
//Item名称
//integer Writes Names of Items (topological items)
//[0] : no (empty name)
//[1] : name from CAD if defined, else empty
//[2] : "n?iii" : ID from CAD
"cadexchanger.write_property":"0",
//step write 属性
//integer Writes Attributes and Properties
//[0] : no
//[1] : Product Data
//[2] : also general attributes(metadata)
//except "File Property"
//[3] : all general attributes, also "File Property"
"cadexchanger.rasterize_texts":"true",//文本折线化
"cadexchanger.write_prc":"true",//内嵌Prc
"cadexchanger.geo_format":"0",
//几何格式
//[0] : Mesh (Default),
//[1] : BRep, [2] : Mesh + BRep
"cadexchanger.jt_pmi_as_semantic":"false",//PMI描述数据
"cadexchanger.write_xtbrep":"false",//输出精确数据
"cadexchanger.jtwrite_release":"80",
//输出版本
//[80] : version 8.0 (default),
//[95] : version 9.5
"cadexchanger.write_export_type":"0"
//输出类型
//[0] : Monolithic (default),
//[1] : Shattered, [2] : PerPart
2.cadconverter配置参数
"cadconverter.boundaryline":"true",//边界线
"cadconverter.hiddenobject":"true",//隐藏对象
"cadconverter.spacespot":"true",//空间点
"cadconverter.spaceline":"true",//空间线
"cadconverter.customview":"true",//自定义视图
"cadconverter.model_property":"true",//模型属性
"cadconverter.cable":"true",//线缆
"cadconverter.cablesheath":"true",//线鞘
"cadconverter.layer":"true",//图层
"cadconverter.pmi":"true",// PMI
"cadconverter.forcetess":"true",//使用SView的分元
"cadconverter.preview":"true",//缩略图
"cadconverter.only_current":"true",//只转换当前
"cadconverter.line_tolerance":"5",//折线公差
"cadconverter.angle_tolerance":"25",//角度公差
"cadconverter.outputmode":"0",//输出方式0、单一文件1、分散文件
"cadconverter.compress":"0",//压缩模式0、不压缩1、快速压缩2、高质量压缩
"cadconverter.mesh_merge":"0",//Mesh合并0、不合并1、合并
"cadconverter.snapshot":"true",//输出快照文件
"cadconverter.log":"0",//输出日志0、不输出1、普通用户2、高级用户3、开发人员
"cadconverter.debuginfo":"true",//输出PMI调试信息(开发人员使用)
"cadconverter.model_compare":"true",//模型比较(适合Pro/E二次开发使用)
3.rvmconverter配置参数
"rvmconverter.lineartolerance":"5",//折线公差
"rvmconverter.angulartolerance":"25",//角度公差
4.svlx2fbx配置参数
"svlx2fbx.fbxversion":"FBX binary (*.fbx)",//Fbx版本 FBX ascii (*.fbx) FBX 6.0 binary (*.fbx) FBX 6.0 ascii (*.fbx)
"svlx2fbx.upvector":2,//上方向 X:1,Y:2,Z:3
"svlx2fbx.coordsystem":0//坐标系 右手:0,左右:1
5.objconverter配置参数
"objconverter.objversion":"OBJ (*.obj)"//OBJ版本 OBJ (*.obj)、OBJ VertexColor (*.obj)
6.plyconverter配置参数
"plyconverter.plyversion":"PLY Binary (*.ply)"//PLY版本 PLY Binary (*.ply)、PLY ASCII (*.ply)
5.stlconverter配置参数
"stlconverter.stlversion":"STL Binary (*.stl)"//STL版本 STL Binary (*.stl)、STL ASCII (*.stl)
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、1005
"msg":"参数不得为空!"
}
备注
无
添加到转换
接口链接
mroot/convert/add
接口版本
7.1
说明
将云盘里的文件添加到转换列表,同时创建转换任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| userfileid | 是 | String | 需要转换的用户文件id |
| configid | 否 | String | 配置id,为空时用默认配置 |
| input | 否 | String | 输入类型,(例:Catia V5 3D) |
| output | 否 | String | 输出类型,为空时取默认值(例:SVL2.0) |
返回值(JSON):
成功:
{
"return":"0",
"taskid":"8d2c7c6c-e7aa-49ba-ce609dd7888b",//新建的任务时返回
"userfileid":"d9f28797-daa53-4a79465741bc"//转换引用时返回
}
失败:
{
"return":"1",//1、2、3010、3011、8005、8003、8004、4003、8013
"msg":"参数不得为空!"
}
备注
无
获取转换任务列表
接口链接
mroot/convert/list
接口版本
7.1
说明
获取转换中、等待中、停止和失败的任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| begindate | 否 | String | 根据任务的创建时间进行检索,分别表示任务创建时间的开始跟结束时间 |
| enddate | 否 | String |
返回值(JSON):
成功:
{
"return":"0",
"list": [
{
"begintime": "2019-07-26 15:04:30",//开始转换时间
"configid": "f6d6c604-5941-4f7f-8276-a8094546098d",//配置id
"createtime": "2019-07-26 15:04:29",//创建时间
"filename": "demo.prt",//原文件名
"filesize": 368640,//原文件大小
"finishtime": "2019-07-26 15:04:30",//转换结束时间
"id": "a9d8f4bb-d20e-432c-9c85-5c77eca99b2f",//任务id
"fileid": "cac6c1be-126a-41ff-87cc-301b3090e64c",
"input": "UG NX 3D",//输入类型
"inputformat": "prt",//输入的文件格式
"logname": "demo.prt.log",//转换日志名
"outfilename": "demo.prt.svlx",//转换出的文件名
"outfilesize": 14255,//转换出的文件大小
"output": "SVL2.0",//转换输出类型
"outputformat": "svlx",//转换输出格式
"outuserfileid": "e36654fb-3399-4-bc24965deb",//转换出的文件在云盘中的id
"pfolderid": "6f12180c-ae8c-9b-f7c247c0995d",//云盘中所处的父文件夹id
"result": "8002",//错误吗参考return返回值
"state": 4,//转换状态值,具体参考本文档return返回值
"userfileid": "bc92668b-8bc4-45ebe-09de449243e8",//需要转换的用户文件id
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2",
"version": "2.0"//转换版本
},
{
...
}
]
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取转换完成的任务列表
接口链接
mroot/convert/converted
接口版本
7.1
说明
获取转换成功的任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| begindate | 否 | String | 根据任务的结束时间进行检索,分别表示任务结束时间的开始跟结束时间 |
| enddate | 否 | String |
返回值(JSON):
成功:
{
"return":"0",
"list": [
{
"begintime": "2019-07-26 15:04:30",//开始转换时间
"configid": "f6d6c604-5941-4f7f-8276-a8094546098d",//配置id
"createtime": "2019-07-26 15:04:29",//创建时间
"filename": "demo.prt",//原文件名
"filesize": 368640,//原文件大小
"finishtime": "2019-07-26 15:04:30",//转换结束时间
"id": "a9d8f4bb-d20e-432c-9c85-5c77eca99b2f",//任务id
"fileid": "cac6c1be-126a-41ff-87cc-301b3090e64c",
"input": "UG NX 3D",//输入类型
"inputformat": "prt",//输入的文件格式
"logname": "demo.prt.log",//转换日志名
"outfilename": "demo.prt.svlx",//转换出的文件名
"outfilesize": 14255,//转换出的文件大小
"output": "SVL2.0",//转换输出类型
"outputformat": "svlx",//转换输出格式
"outuserfileid": "e36654fb-3399-4-bc24965deb",//转换出的文件在云盘中的id
"pfolderid": "6f12180c-ae8c-9b-f7c247c0995d",//云盘中所处的父文件夹id
"result": "8002",//错误吗参考return返回值
"state": 5,//转换状态值,具体参考本文档return返回值
"userfileid": "bc92668b-8bc4-45ebe-09de449243e8",//需要转换的用户文件id
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
},
{
...
}
]
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
移动端获取任务列表
接口链接
mroot/convert/mobileList
接口版本
7.1
说明
移动端获取任务列表,包含所有状态的任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| searchtext | 否 | String | 搜索内容:根据文件名搜索 |
返回值(JSON):
成功:
{
"return":"0",
"list": [
{
"begintime": "2019-07-26 15:04:30",//开始转换时间
"configid": "f6d6c604-5941-4f7f-8276-a8094546098d",//配置id
"createtime": "2019-07-26 15:04:29",//创建时间
"filename": "demo.prt",//原文件名
"filesize": 368640,//原文件大小
"finishtime": "2019-07-26 15:04:30",//转换结束时间
"id": "a9d8f4bb-d20e-432c-9c85-5c77eca99b2f",//任务id
"input": "UG NX 3D",//输入类型
"inputformat": "prt",//输入的文件格式
"logname": "demo.prt.log",//转换日志名
"outfilename": "demo.prt.svlx",//转换出的文件名
"outfilesize": 14255,//转换出的文件大小
"output": "SVL2.0",//转换输出类型
"outputformat": "svlx",//转换输出格式
"outuserfileid": "e36654fb-3399-4-bc24965deb",//转换出的文件在云盘中的id
"pfolderid": "6f12180c-ae8c-9b-f7c247c0995d",//云盘中所处的父文件夹id
"result": "8002",//错误吗参考return返回值
"state": 5,//转换状态值,具体参考本文档return返回值
"userfileid": "bc92668b-8bc4-45ebe-09de449243e8",//需要转换的用户文件id
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
},
{
...
}
]
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取转换状态
接口链接
mroot/convert/status
接口版本
7.1
说明
批量获取转换状态
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskids | 是 | String | 任务id字符串,多个任务中间用逗号隔开 |
返回值(JSON):
成功:
{
"return":"0",
"list": [
{
"state": 5,//转换状态值,具体参考本文档return返回值
"taskid": "1193bd23-fcf7-4f07-bd8d-041eca74a086",
"order": "5",//队列中的位置
"process": "100",//转换进度
"result":"4003"
},
{
"state": 5,
"taskid": "a9d8f4bb-d20e-432c-9c85-5c77eca99b2f",
"process": "100",//转换进度
"result":"4003"
}
]
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
重新转换
接口链接
mroot/convert/reconvert
接口版本
7.1
说明
重新转换
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskid | 是 | String | 需要重新转换的任务id |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3010、3011、3、8006、8007
"msg":"参数不得为空!"
}
备注
无
删除任务
接口链接
mroot/convert/delete
接口版本
7.1
说明
删除任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskids | 是 | String | 任务id字符串,多个用逗号隔开 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、3002、3003
"msg":"参数不得为空!"
}
备注
无
停止当前转换
接口链接
mroot/convert/stop
接口版本
7.1
说明
停止当前转换
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskids | 是 | String | 任务id字符串,多个用逗号隔开 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、3002、3003
"msg":"参数不得为空!"
}
备注
无
获取任务信息
接口链接
mroot/convert/info
接口版本
7.1
说明
获取任务信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskid | 是 | String | 任务id |
返回值(JSON):
成功:
{
"return":"0",
"task": {
"begintime": "2019-07-26 15:03:48",
"configid": "5f78e28a-8670-4211-b3f1-8abf965e6435",
"createtime": "2019-07-26 15:03:48",
"filename": "CL367.prt",
"filesize": 7193047,
"finishtime": "2019-07-26 15:03:52",
"id": "1193bd23-fcf7-4f07-bd8d-041eca74a086",
"input": "UG NX 3D",
"inputformat": "prt",
"inputtype": "ProE/Creo Parametric 3D (*.prt;*.prt.*;*.xpr;*.asm;*.asm.*;*.xas)",
"logname": "CL367.prt.log",
"outfilename": "CL367.prt.svlx",
"outfilesize": 80698,
"output": "SVL2.0",
"outputformat": "svlx",
"outputtype": "SVL2.0 (*.svlx)",
"outuserfileid": "3cfb0f90-76d4-4165-a92a-4bd751344c6f",
"pfolderid": "6f12180c-ae8c-4bab-819b-f7c247c0995d",
"result": "8002",//错误码参考return返回值
"state": 5,
"userfileid": "dba570af-efcc-4430-a87b-1e4a9c601704",
"userid": "bc07fd22-e4d3-4555-8c35-b75c36e391a2"
}
}
失败:
{
"return":"1",// 1、3010、3011、3、8006
"msg":"参数不得为空!"
}
备注
无
任务置顶转换
接口链接
mroot/convert/top
接口版本
7.1
说明
任务置顶转换,针对的是等待中的任务
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskid | 是 | String | 任务id |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、3010、3011、3、8006、8008
"msg":"参数不得为空!"
}
备注
无
获取转换日志内容
接口链接
mroot/convert/logInfo
接口版本
7.1
说明
获取转换日志内容
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| onlineid | 是 | String | 访问凭证 |
| taskid | 是 | String | 任务id |
返回值(JSON):
成功:
{
"return":"0",
"log": [
"<DtkApiVersion>174<\DtkApiVersion>",//日志第一行内容
"Start API : 16:21:13 ", //日志第二行内容
"End API : 16:21:13 ", //日志第三行内容
"API started during : 0sec "//....
]
}
失败:
{
"return":"1",// 1、3010、3011、3、8006、8009
"msg":"参数不得为空!"
}
备注
无
授权服务
获取访问令牌
接口链接
mroot/licence/access
接口版本
7.1
说明
获取访问令牌,验证许可首先需要调此接口获取令牌
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | 许可唯一id,从许可文件中获取 |
| name | 是 | String | 产品名 SView for H5 SView for Android SView for iOS SView for Windows SView Designer SView Converter |
| version | 是 | String | 产品版本号 |
| devices | 是 | String | 客户设备唯一号 |
| state | 是 | String | 客户端生成的随机状态数 |
返回值(JSON):
成功:
{
"return":"0",
"token":"649bcd20-a635-488a-8fd7-55647a8a6c6c",
"expires":"3600"//有效时间/秒
}
失败:
{
"return":"1",// 1、2006、2007、2008
"msg":"参数错误!"
}
备注
无
验证许可
接口链接
mroot/licence/check
接口版本
7.1
说明
验证许可
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| token | 是 | String | 访问令牌,由上一个接口获得 |
| devices | 是 | String | 客户设备唯一号 |
| users | 否 | String | 用户账号 |
| modules | 否 | String | 功能模块,["openFile","explosive","animation","measure"] |
| state | 是 | String | 客户端生成的随机状态数 |
返回值(JSON):
成功:
{
"return":"0",
"context": "dfdfdsfdsf"//使用state加密的许可信息,内容为[app:1];0=认证失败,1=认证成功。
}
失败:
{
"return":"1",//1、2009、2022、2023、2018、2010、2011、2012、2019、2004
"msg":"参数错误!"
}
备注
无
释放许可
接口链接
mroot/licence/release
接口版本
7.1
说明
释放许可,仅网络版并发许可类型使用
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| token | 是 | String | 访问令牌,由上一个接口获得 |
| devices | 是 | String | 客户设备唯一号 |
| users | 否 | String | 用户账号 |
| modules | 否 | String | 功能模块,["openFile","explosive","animation","measure"] |
| type | 是 | String | 认证模式,0=设备ID/Mac地址认证(Devices),1=账户认证 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、2009、2022、2023、2013、2012
"msg":"参数错误!"
}
备注
无
获取许可信息
接口链接
mroot/licence/info
接口版本
7.1
说明
获取许可信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| token | 是 | String | 访问令牌,由上一个接口获得 |
| names | 是 | String | 授权信息名,即lic文件中的等号“=”左侧的信息名。如果要获取所有,则使用“all”。如果要获取部分,使用半角逗号来间隔,如“Customer, CustomerEmail” |
| devices | 是 | String | 客户设备唯一号 |
| state | 是 | String | 客户端生成的随机状态数 |
返回值(JSON):
成功:
{
"return":"0",
"context": "{
"CopyRight":"Shandong Hoteam Software Co.,Ltd",
"CreateDate":"2019-07-23",
"Creator":"SView License Tools v1.0",
"Customer":"测试",
"CustomerEmail":"xxxxxxxxxx@qq.com",
"EndDate":"2019-07-28",
"ID":"20190************25697",
"LicenseType":"2110",
"ProductName":"SView for HTML5",
"ProductVersion":"6.1",
"SView License":"v1.0",
"Seat":"10",
"ServerMAC":"xx-xx-xx-xx-xx-xx",
"SignCode":"6a2845654ae7f117d697471c9e5ef352",
"Term":"5"
}"
}
失败:
{
"return":"1",// 1、2009、2022、2023
"msg":"参数错误!"
}
备注
无
会议服务
创建会议
接口链接
mroot/meeting/create
接口版本
7.1
说明
创建会议
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
| title | 是 | String | 会议标题 |
| presenter | 是 | String | 会议主持人 |
| password | 否 | String | 会议密码 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、6001
"msg":"参数错误!"
}
备注
无
参会者参会
接口链接
mroot/meeting/enter
接口版本
7.1
说明
参会者参会
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
| name | 是 | String | 参会者名字 |
| deviceid | 是 | String | 参会者唯一标识 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、6002、6003
"msg":"参数错误!"
}
备注
无
参会者退会
接口链接
mroot/meeting/out
接口版本
7.1
说明
参会者退会
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
| deviceid | 是 | String | 参会者唯一标识 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
引用
接口链接
mroot/meeting/reference
接口版本
7.1
说明
客户端提交文件时,首先发送此请求,如果服务器返回文件不存在,再发送真实上传模型的请求。
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
| filename | 是 | String | 文件的原文件名 |
| deviceid | 是 | String | 用户唯一标识 |
| md5 | 是 | String | 文件MD5 |
| name | 否 | String | 模型中文名 |
| type | 是 | String | 文件类型 0模型 1附件 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、6002、6003、6004
"msg":"参数错误!"
}
备注
无
上传
接口链接
mroot/meeting/upload
接口版本
7.1
说明
上传
参数:(GET、POST)
multipart/form-data
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| modelfile | 是 | 文件流 | 上传的文件 |
| meetingid | 是 | String | 会议id |
| deviceid | 是 | String | 用户唯一标识 |
| name | 否 | String | 模型中文名 |
| type | 是 | String | 文件类型 0模型 1附件 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、6005、6002、6003
"msg":"参数错误!"
}
备注
无
获取会议当前信息
接口链接
mroot/meeting/info
接口版本
7.1
说明
获取会议当前信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
返回值(JSON):
成功:
{
"return":"0",
"meeting":{
"modelid":"5f78e28a-8670-42",//会议模型id
"modelname":"prt.svl",
"fileid":"5f78e28a-8670-42",//会议模型所引用的源模型id
"modelmd5":"dfsfdfsd",
"meetingstate":"0"//会议状态 0:进行中 1:已结束
}
}
失败:
{
"return":"1",// 1、6002、6003、6006
"msg":"参数错误!"
}
备注
无
关闭会议
接口链接
mroot/meeting/close
接口版本
7.1
说明
关闭会议
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
会议模型下载
接口链接
mroot/meeting/download
接口版本
7.1
说明
会议模型下载
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| modelid | 是 | String | 会议模型id |
| type | 是 | String | 文件类型 0模型 1附件 |
返回值(JSON):
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1或3
"msg":"参数错误!"
}
备注
无
会议邀请
接口链接
mroot/meeting/invite
接口版本
7.1
说明
会议邀请
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| title | 是 | String | 会议标题 |
| meetingid | 是 | String | 会议号 |
| presenter | 是 | String | 主持人 |
| password | 是 | String | 密码 |
| count | 是 | String | 会议人数 |
| type | 否 | String | 会议类型 0:红杉树 1:腾讯即时通讯 |
返回值(页面):
成功:
{
返回会议邀请jsp页面
}
腾讯会议服务
获取UserSig
接口链接
mroot/tim/login/usersig
接口版本
8.0
说明
获取usersig
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| userid | 否 | String | 用户需要加密的id,为空时服务器自动生成并返回 |
返回值:
成功:
{
"return": "0",
"userid": "10000",
"usersig": "gfsgfdsgdfgsdf"
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
创建会议
接口链接
mroot/tim/group/create
接口版本
8.0
说明
创建即时通讯会议
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| name | 是 | String | 会议名称 |
| userid | 是 | String | 会议创建者id |
| host | 是 | String | 会议主持人名称 |
返回值:
成功:
{
"return": "0",
"groupid": "12345678" //会议id
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
获取会议列表
接口链接
mroot/tim/group/list
接口版本
8.0
说明
获取即时通讯会议列表
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| offset | 否 | String | 偏移量,默认0 |
| pagesize | 否 | String | 每页条数,默认20 |
| searchcontent | 否 | String | 按会议名称模糊查询 |
返回值:
成功:
{
"return": "0",
"groups": [
{
"createtime": "2020-10-01 15:37:03",
"id":"45854827",//会议id,使用此id与即时通讯sdk进行交互
"isdelete": "0",
"name": "group",//会议名称
"state": "0",//会议状态 "0" 进行中,"1" 已结束
"userid": "zhangsan", //会议创建者id
"host":"主持人名称"
},
{...}
]
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
引用
接口链接
mroot/tim/group/reference
接口版本
8.0
说明
客户端提交文件时,首先发送此请求,如果服务器返回文件不存在(retrun="6004"),再发送真实上传模型的请求。
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| meetingid | 是 | String | 会议id |
| filename | 是 | String | 文件的原文件名 |
| md5 | 是 | String | 文件MD5 |
返回值:
成功:
{
"return": "0",
"fileid":"dfdfsdf"//源文件id
}
失败:
{
"return":"1",// 1
"msg":"参数错误!"
}
备注
无
上传
接口链接
mroot/tim/group/upload
接口版本
8.0
说明
上传
参数:(GET、POST)
multipart/form-data
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| modelfile | 是 | 文件流 | 上传的文件 |
| meetingid | 是 | String | 会议id |
返回值(JSON):
成功:
{
"return":"0",
"fileid":"dfdfsdf"//源文件id
}
失败:
{
"return":"1",// 1、6005、6002、6003
"msg":"参数错误!"
}
备注
无
性能改进
获取SVLX的子文件
接口链接
mroot/svlx/nodes
接口版本
7.1
说明
根据文件扩展名获取SVLX的子文件,当传入相对路径时,先根据相对路径定位到指定目录,然后再获取文件
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | SVLX源文件id |
| content | 是 | String | 获取的内容,多个中间用英文逗号隔开 获取所有:all 获取子文件: fileinfo,Info,bom,lod, animation,pmi,mesh,model,view,lod, annotation,measure,attribute,geo 获取相对路径下的文件:传需要获取的文件名,中间用英文逗号隔开 |
| compress | 否 | String | 是否压缩 0不压缩,1zip压缩,2gzip压缩,默认zip压缩 |
| relativepath | 否 | String | 相对路径 |
返回值:
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1、3、1001、 1004
"msg":"参数错误!"
}
备注
无
获取mesh数据
接口链接
mroot/svlx/mesh
接口版本
7.1
说明
根据模型ID跟lod级别,请求mesh数据
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | SVLX源文件id |
| models | 是 | String | 模型id跟lod级别,格式如下: "modelid":lodlevel","modelid":lodlevel",… |
返回值:
成功:
{
输出文件流
}
失败:
{
"return":"1",// 1、2、3、1006
"msg":"参数错误!"
}
备注
无
获取内容列表
接口链接
mroot/svlx/nodelist
接口版本
7.1
说明
根据type类型,获取对应文件的内容列表,例如type值为view时,则获取视图列表。(返回列表基本内容)
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | SVLX源文件id |
| type | 是 | String | 内容类型: view:视图列表 、 自定义视图列表 annotation:批注列表 |
| range | 否 | String | 0 :内部的 1:外部的 2:全部的 默认0,当获取视图列表的时候此参数为必填 |
| modelid | 否 | String | 文件内部模型ID 当获取视图时需要传递 |
| uniqueid | 否 | String | 客户端唯一标识 当range来源为从外部读取时,此参数代表是获取哪个客户端的创建的视图 |
返回值:
成功:批注列表返回格式:
{
"return":"0",
"list":[
{
"createid": "110886",//批注id
"type": "0"//批注类型
},
{
"createid": "110985",
"type": "2"
},
{ ... }
]
}
视图列表返回格式:
{
"return": "0",
"innerlist": [ //文件内部视图列表
{
"id": "1002", //文件内部视图id
"name": "DefaultView"//文件内部视图名称
},
{
"id": "1002",
"name": "DefaultView"
},
{...}
],
"outerlist": [ //自定义视图返回格式
{
"id": "8db6a21a-f2f6-4f88-94a3-ea6505238039",//数据库中视图id
"fileid":"4eae500d-ab42-432d-8b2f-57f52dc3e97b",//源文件id
"modelid": "1014",//文件内部的模型id,由创建视图时传到服务器
"name": "自定义视图1",
"image1": "data/upload/modelfile/xx/xx/..._1.png",//视图缩略图大图
"image2": "data/upload/modelfile/xx/xx/..._2.png",//视图缩略图小图
"creatorid": "123123123",//视图创建者id
"creator": "张三",//视图创建者名称
"createtime":"2019-11-25 19:39:53",
"modelviewid":"45df56dad",//本地视图id,用来跟本地已有视图做比较
},
{....}
]
}
失败:
{
"return":"1",// 1、2、3、1006
"msg":"参数错误!"
}
备注
无
获取元素内容
接口链接
mroot/svlx/element
接口版本
7.1
说明
根据type类型及相关id,获取对应文件的单个元素详细内容
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | SVLX源文件id |
| type | 是 | String | 内容类型: view、视图内容 viewcontent、视图关联内容 annotation、批注内容 measure、测量 attribute、自定义属性 model、模型属性 instance、实例属性 geo、几何属性 |
| typeids | 是 | String | 根据type类型,传递不同类型的id: 用英文逗号隔开,当获取外部视图内容时,参数值为数据库的视图id |
| geoid | 否 | String | 几何要素id: type为几何属性时需要此参数 |
| range | 否 | String | 0 :内部的 1:外部的 默认0,当获取视图内容与视图关联内容的时候此参数为必填,获取视图关联内容时此参数值传“1” |
返回值:
成功:视图内容:
{
"innerviews": [
//key为视图id,value为对应视图的json串(格式与视图文件中一致)
{
"1014": {
...
}
},
{
"1016": {
....
}
}
],
"outerviews": [
{
"id": "8db6a21a-f2f6-4f88-94a3-ea6505238039",//数据库中视图id
"content": "........",//视图的具体json数据
"subcontent":"........"//视图关联的内容
},
{
......
}
],
"return": "0"
}
批注内容:
{
"annotations": [
//key为批注id,value为对应批注的json串(格式与批注文件中一致)
{
"1014": {
...
}
},
{
"1016": {
....
}
}
],
"return": "0"
}
测量内容:
{
"measures": [
{
"1014": {
...
}
},
{
"1016": {
....
}
}
],
"return": "0"
}
自定义属性:
{
"attributes": [
{
"1014": {
...
}
},
{
"1016": {
....
}
}
],
"return": "0"
}
模型属性:
{
"models": [
{
"1014": {
"id": 1014,
"name": "feijiyinqing"
}
},
{
"1016": {
"id": 1016,
"name": "ASM0001_"
}
}
],
"return": "0"
}
实例属性:
{
"instances": [
{
"1013": {
"id": 1013,
"name": "feijiyinqing"
}
},
{
"1015": {
"id": 1015,
"name": "ASM0001_"
}
}
],
"return": "0"
}
几何属性:
{
"content": {
"axisDirection": "0.00000000 0.00000000 1.00000000",
"axisOrigin": "0.00000000 0.00000000 -1.25000000",
"radius": "1.50000000",
"type": "4"
},
"return": "0"
}
失败:
{
"return":"1",// 1、2、3、1006
"msg":"参数错误!"
}
备注
无
保存自定义视图
接口链接
mroot/svlx/save
接口版本
7.1
说明
保存用户的自定义视图、关联内容
参数:(GET、POST)
multipart/form-data
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | 保存视图时:代表SVLX文件id id需要用get方式传 |
| content | 是 | String | 自定义视图的json格式字符串 |
| contentfile | 是 | 文件流 | 视图关联内容的文件 |
| image1 | 是 | 文件流 | 视图截图,大尺寸截图 |
| image2 | 是 | 文件流 | 视图截图,小尺寸截图 |
| uniqueid | 否 | String | 客户端唯一标识,保存视图时需要传递此参数 |
| creator | 否 | String | 创建者名称 |
| name | 是 | String | 视图名称 |
| modelid | 是 | String | 模型文件中的模型id,用来标记给哪个模型添加的视图 |
| modelviewid | 是 | String | 该视图在本地视图中的id,用来与本地视图比较 |
| isactivated | 否 | String | 是否设置为默认视图:0否;1是 |
返回值(JSON):
成功:
{
"return":"0",
"id":"fdadfdfsds"//创建的视图id
}
失败:
{
"return":"1",// 1、1009
"msg":"参数错误!"
}
备注
无
删除自定义视图
接口链接
mroot/svlx/delete
接口版本
7.1
说明
删除用户自定义视图不是自己的视图禁止删除
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| viewid | 否 | String | 需要删除的viewid(数据库中的id),与fileid不能同时为空 |
| fileid | 否 | String | 源文件id,根据此id实现批量删除,与viewid不能同时为空 |
| uniqueid | 是 | String | 视图所属作者的ID |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、2、1007
"msg":"参数错误!"
}
备注
无
编辑自定义视图
接口链接
mroot/svlx/edit
接口版本
8.1
说明
编辑用户自定义视图不是自己的视图禁止编辑
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| viewid | 是 | String | 需要删除的viewid(数据库中的id) |
| uniqueid | 是 | String | 视图所属作者的ID |
| name | 是 | String | 新视图名 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、2、1008
"msg":"参数错误!"
}
备注
无
设置默认视图
接口链接
mroot/svlx/setDefault
接口版本
7.1
说明
设置默认视图
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| viewid | 是 | String | 视图id |
| isactivated | 否 | String | 是否是默认视图:0否;1是,默认为1 |
返回值(JSON):
成功:
{
"return":"0"
}
失败:
{
"return":"1",// 1、2
"msg":"参数错误!"
}
备注
无
场景信息
保存配置
接口链接
mroot/set/create
接口版本
7.2
说明
创建配置信息,存在时执行修改,不存在时执行保存
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| uniqueid | 是 | String | 唯一号(可传用户id) |
| modelid | 否 | String | 模型id(文档配置时必传) |
| content | 是 | String | 配置内容json串 |
| type | 是 | String | 配置类型:1:系统配置 2:文档配置 |
返回值:
成功:
{
"return":"0"
}
失败:
{
"return":"1",
"msg":"参数错误!"
}
备注
无
获取配置
接口链接
mroot/set/get
接口版本
7.2
说明
获取配置信息
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| uniqueid | 是 | String | 唯一号(可传用户id) |
| modelid | 否 | String | 模型id(文档配置时必传) |
| type | 是 | String | 配置类型:1:系统配置 2:文档配置 |
返回值:
成功:
{
"return":"0",
"content":"...."//配置信息json串
}
失败:
{
"return":"1",
"msg":"参数错误!"
}
备注
无
分散文件
加载分散文件
接口链接
mroot/svlx/distribute/load
接口版本
7.2
说明
根据不同类型,获取合并或压缩后的分散文件用于显示
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| userfileid | 是 | String | 用户文件id |
| filenames | 否 | String | 需要查找的文件名,type为1时必传 |
| type | 是 | String | 分散文件合并类型: 1:通过指定文件名查询,返回指定文件压缩包 2:打包,返回svlx,子文件压缩到文件里"items"文件夹下 3:合并,返回单一svlx |
返回值:
成功:
{
返回文件流
}
失败:
{
"return":"1",1、2、3、1001、1006
"msg":"参数错误!"
}
备注
无
查找文件
接口链接
mroot/svlx/distribute/find
接口版本
7.2
说明
根据文件名查找用户空间当前目录下的子文件
参数:(GET、POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| userfileid | 是 | String | 用户文件id |
| filename | 是 | String | 需要查找的文件名 |
返回值:
成功:
{
"return": "0",
"ufid":"....",//用户文件id
"fileid":"....",//对应的源文件id
}
失败:
{
"return":"1",1、4001
"msg":"参数错误!"
}
备注
无
转换队列
添加转换任务
接口链接
dispatchroot/dispatchconvert/addTask
接口版本
9.0.1
说明
将新的转换任务添加到转换队列,等待转换
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| files | 是 | String | 待转换文件json格式字符串 |
| mainfilename | 是 | String | 待转换主文件名,若转换装配件,此参数为主装配文件名,需要通过Base64进行加密 |
| inputformat | 是 | String | 输入格式,例:Catia V5 3D (*.CATPart;*.CATProduct) |
| outputformat | 是 | String | 输出格式,例:SVL2.0 (*.svlx) |
| configcontent | 是 | String | 转换配置字符串 |
| uniqueid | 是 | String | 唯一码,由客户端生成并传入,转换结束后队列服务会将该参数传回,可用于即将发起的转换任务的唯一标识,或根据具体情况用于其他逻辑实现 |
待转换文件参数格式:若转换装配件,需要将子件信息添加到待转文件中
[
{
"filename": "QmFza2V0LkNBBhcnQ=",//通过Base64加密的文件名
"url": "aHR0cDovLzElkYS9CYlM5LkNBVFBhcnQ="//通过Base64加密的文件下载链接
},
{
"filename": "YmFza2VFByb2R1Y3Q=",
"url": "aHR0cDovLzEw1Mjc0ZGI0YTA5XQuQ0FUUHJvZHVjdA=="
},
{
"filename": "bG93ZXIgDQVRQYXJ0",
"url": "aHR0cDovLzEwLjAuNDiUyMGJvZHkuQ0FUUGFydA=="
},
{
"filename": "bWFzdGVQVRQYXJ0",
"url": "aHR0cDovMGViOTU3BoYW5kbGUuQ0FUUGFydA=="
},
{
"filename": "bWV0YWwFBhcnQ=",
"url": "aHR0cDovLzEwjJkyMGFybS5DQVRQYXJ0"
},
{
"filename": "dXBwZXIgVRQYXJ0",
"url": "aHR0cDovLzEwLj1cHBlciUyMGJvZHkuQ0FUUGFydA=="
}
]
返回值:
成功:
{
"return": "0",
"taskid":"....",//转换队列返回的任务id
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
获取任务状态
接口链接
dispatchroot/dispatchconvert/status
接口版本
9.0.1
说明
获取转换任务的转换状态,转换进度等信息
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskids | 是 | String | 任务id,多个任务id中间用英文逗号隔开 |
返回值:
成功:
{
"return": "0",
"list":[
{
"process":"100",
"state":"5",
"taskid":"70bab6a6959a432081fd9e7b5b3156f9"
},
{
"process":"0",
"state":"1",
"taskid":"610e20a83980426494d36ec0b125015a"
}
],
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
重新转换
接口链接
dispatchroot/dispatchconvert/reAddTask
接口版本
9.0.1
说明
针对已转换的任务,重新发起转换,加入转换队列
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskids | 是 | String | 转换队列返回的任务id |
| files | 是 | String | 待转换文件json格式字符串 |
| mainfilename | 是 | String | 待转换主文件名,若转换装配件,此参数为主装配文件名,需要通过Base64进行加密 |
| inputformat | 是 | String | 输入格式,例:Catia V5 3D (*.CATPart;*.CATProduct) |
| outputformat | 是 | String | 输出格式,例:SVL2.0 (*.svlx) |
| configcontent | 是 | String | 转换配置字符串 |
| uniqueid | 是 | String | 唯一码,由客户端生成并传入,转换结束后队列服务会将该参数传回,可用于即将发起的转换任务的唯一标识,或根据具体情况用于其他逻辑实现 |
待转换文件参数格式:若转换装配件,需要将子件信息添加到待转文件中
[
{
"filename": "QmFza2V0LkNBBhcnQ=",//通过Base64加密的文件名
"url": "aHR0cDovLzElkYS9CYlM5LkNBVFBhcnQ="//通过Base64加密的文件下载链接
},
{
"filename": "YmFza2VFByb2R1Y3Q=",
"url": "aHR0cDovLzEw1Mjc0ZGI0YTA5XQuQ0FUUHJvZHVjdA=="
},
{
"filename": "bG93ZXIgDQVRQYXJ0",
"url": "aHR0cDovLzEwLjAuNDiUyMGJvZHkuQ0FUUGFydA=="
},
{
"filename": "bWFzdGVQVRQYXJ0",
"url": "aHR0cDovMGViOTU3BoYW5kbGUuQ0FUUGFydA=="
},
{
"filename": "bWV0YWwFBhcnQ=",
"url": "aHR0cDovLzEwjJkyMGFybS5DQVRQYXJ0"
},
{
"filename": "dXBwZXIgVRQYXJ0",
"url": "aHR0cDovLzEwLj1cHBlciUyMGJvZHkuQ0FUUGFydA=="
}
]
返回值:
成功:
{
"return": "0",
"taskid":"....",//转换队列返回的任务id
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
停止转换
接口链接
dispatchroot/dispatchconvert/stop
接口版本
9.0.1
说明
只有转换中与等待中的任务可以进行停止操作
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskids | 是 | String | 任务id,多个任务id中间用英文逗号隔开 |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
置顶转换
接口链接
dispatchroot/dispatchconvert/top
接口版本
9.0.1
说明
优先转换置顶的任务
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskid | 是 | String | 需要置顶的任务id |
| taskids | 是 | String | 被置顶的任务所在的任务列表,即将此任务在任务列表范围内进行置顶,任务id,多个任务id中间用英文逗号隔开 |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
添加转换节点
接口链接
dispatchroot/server/add
接口版本
9.0.1
说明
将转换服务节点添加到转换队列里
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| server_name | 是 | String | 转换服务节点名称 |
| ip | 是 | String | 转换服务节点ip地址(格式:http://ip:端口/) |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
更新转换节点
接口链接
dispatchroot/server/update
接口版本
9.0.1
说明
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | 转换服务节点id |
| server_name | 是 | String | 转换服务节点名称 |
| ip | 是 | String | 转换服务节点ip地址(格式:http://ip:端口/) |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
删除转换节点
接口链接
dispatchroot/server/delete
接口版本
9.0.1
说明
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | 转换服务节点id |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3、90009、90010
"msg":"参数错误!"
}
备注
无
获取转换节点列表
接口链接
dispatchroot/server/list
接口版本
9.0.1
说明
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| rows | 是 | String | 每页显示的条数 |
| pages | 是 | String | 页码 |
返回值:
成功:
{
"count": "2",
"list": [
{
"id": "8c04c072623bfbbad200bbaee5b2b",
"server_name": "lcs",
"ip": "http://10.0.43.59:5557/",
"convert_time": null,
"server_max_count": "1",
"server_convert_count": "0",
"server_state": "1",
"server_state_available": "0",
"server_convert_path": "C:/tool/converter",
"server_time_out": "3600000",
"server_file_temp": "E:/temp",
"create_time": "2022-06-14 10:06:53",
"create_id": null,
"server_index": "N",
"server_number": null,
"systemRunInfo": {
"memory": {
"memUse": 11.0,
"menPercent": "73",
"memAll": 15.0
},
"file": {
"fileUse": "359.6",
"fileAll": "2095.7",
"fileUsePerecent": "17"
},
"cpu": {
"cpuAll": null,
"cpu": "25",
"cpuUse": null
},
"return": "0"
}
},
{
"id": "f85d9fb5804749f5864657c8b58570d3",
"server_name": "测试机_姚",
"ip": "http://10.0.43.217:5557/",
"convert_time": null,
"server_max_count": "2",
"server_convert_count": "0",
"server_state": "0",
"server_state_available": "1",
"server_convert_path": "C:/tool/converter",
"server_time_out": "3600000",
"server_file_temp": "E:/temp",
"create_time": "2022-06-07 09:24:19",
"create_id": null,
"server_index": "N",
"server_number": null
}
]
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
转换节点上线
接口链接
dispatchroot/server/online
接口版本
9.0.1
说明
上线后该节点才能执行转换任务
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| id | 是 | String | 转换服务节点id |
| server_max_count | 是 | String | 同时最大的转换数 |
| server_convert_path,例:C:/tool/converter | 是 | String | 转换器安装路径根目录 |
| server_time_out | 是 | String | 转换超时时间,单位毫秒,例:3600000 |
| ip | 是 | String | 转换服务节点ip地址,例:http://10.0.43.59:5557/ |
| server_file_temp | 是 | String | 转换文件临时生成目录,例:E:/temp |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
转换节点下线
接口链接
dispatchroot/server/unlineAll
接口版本
9.0.1
说明
下线后该节点暂时不能被分配转换任务
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| server_id | 是 | String | 转换服务节点id |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3、90004
"msg":"参数错误!"
}
备注
无
获取转换队列转换历史记录
接口链接
dispatchroot/server/listDispatchConvertHistory
接口版本
9.0.1
说明
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| server_id | 是 | String | 转换服务节点id |
返回值:
成功:
{
"return": "0",
"count": "1",
"list": [
{
"id": "9da99c83a8a34943a89ee09dba3dbeb3",
"state": 4,
"create_time": "2022-06-14 15:19:17",
"uniqueid": "1d7c549643584375908496519b0c4dda",
"begintime": "2022-06-14 15:19:18",
"finishtime": "2022-06-14 15:19:20",
"inputformat": "BDF (*.bdf)",
"outputformat": "SVL2.0 (*.svlx)",
"reason": "8016",
"serverName": "lcs",
"mainfilename2": "qs_spotweld.bdf"
},
{...}
]
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
分布式转换服务
添加转换任务
接口链接
convertroot/convertcore/add
接口版本
9.0.1
说明
添加转换任务到对应转换节点,进行转换
参数:(POST)
| files | 是 | String | 待转换文件json格式字符串 |
| mainfilename | 是 | String | 待转换主文件名,若转换装配件,此参数为主装配文件名,需要通过Base64进行加密 |
| inputformat | 是 | String | 输入格式,例:Catia V5 3D (*.CATPart;*.CATProduct) |
| outputformat | 是 | String | 输出格式,例:SVL2.0 (*.svlx) |
| configcontent | 是 | String | 转换配置字符串 |
| uniqueid | 是 | String | 唯一码,由客户端生成并传入,转换结束后队列服务会将该参数传回,可用于即将发起的转换任务的唯一标识,或根据具体情况用于其他逻辑实现 |
待转换文件参数格式:若转换装配件,需要将子件信息添加到待转文件中
[
{
"filename": "QmFza2V0LkNBBhcnQ=",//通过Base64加密的文件名
"url": "aHR0cDovLzElkYS9CYlM5LkNBVFBhcnQ="//通过Base64加密的文件下载链接
},
{
"filename": "YmFza2VFByb2R1Y3Q=",
"url": "aHR0cDovLzEw1Mjc0ZGI0YTA5XQuQ0FUUHJvZHVjdA=="
},
{
"filename": "bG93ZXIgDQVRQYXJ0",
"url": "aHR0cDovLzEwLjAuNDiUyMGJvZHkuQ0FUUGFydA=="
},
{
"filename": "bWFzdGVQVRQYXJ0",
"url": "aHR0cDovMGViOTU3BoYW5kbGUuQ0FUUGFydA=="
},
{
"filename": "bWV0YWwFBhcnQ=",
"url": "aHR0cDovLzEwjJkyMGFybS5DQVRQYXJ0"
},
{
"filename": "dXBwZXIgVRQYXJ0",
"url": "aHR0cDovLzEwLj1cHBlciUyMGJvZHkuQ0FUUGFydA=="
}
]
返回值:
成功:
{
"return": "0",
"taskid": "a99c83a8a34943a89ee09dba3dbe"
}
失败:
{
"return":"1",//1、2、3、8014、8015
"msg":"参数错误!"
}
备注
无
获取任务状态
接口链接
convertroot/convertcore/status
接口版本
9.0.1
说明
获取正在转换的任务的转换状态,转换进度等信息
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskids | 是 | String | 任务id,多个任务id中间用英文逗号隔开 |
返回值:
成功:
{
"return": "0",
"list":[
{
"process":"15",
"taskid":"70bab6a6959a432087b5b3156f9"
},
{
"process":"0",
"taskid":"610e20a839804264ec0b125015a"
}
],
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
停止
接口链接
convertroot/convertcore/stop
接口版本
9.0.1
说明
只有转换中与等待中的任务可以进行停止操作
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskid | 是 | String | 需要停止的任务id |
返回值:
成功:
{
"return": "0",
}
失败:
{
"return":"1",//1、2、3、8017
"msg":"参数错误!"
}
备注
无
下载
接口链接
convertroot/convertcore/download
接口版本
9.0.1
说明
下载转换任务转换出的所有文件
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| taskid | 是 | String | 需要停止的任务id |
返回值:
成功:
{
转换生成的所有文件以压缩成压缩包并以流的形式返回到客户端
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
初始化
接口链接
convertroot/convertcore/init
接口版本
9.0.1
说明
初始化转换节点的基本参数
参数:(POST)
| 变量名 | 必填 | 类型 | 描述 |
|---|---|---|---|
| maxcount | 是 | String | 同时最大的转换数 |
| toolbasepath,例:C:/tool/converter | 是 | String | 转换器安装路径根目录 |
| timeout | 是 | String | 转换超时时间,单位毫秒,例:3600000 |
| temPath | 是 | String | 转换文件临时生成目录,例:E:/temp |
返回值:
成功:
{
"return":"0"
}
失败:
{
"return":"1",//1、2、3
"msg":"参数错误!"
}
备注
无
获取当前转换中的个数
接口链接
convertroot/convertcore/getConvertCount
接口版本
9.0.1
说明
初始化转换节点的基本参数
参数:(POST)
无
返回值:
成功:
{
"return":"0",
"count":"1"
}
失败:
{
"return":"1",//1、2、3、8014
"msg":"参数错误!"
}
备注
无
获取转换节点硬件信息
接口链接
convertroot/systemRun/info
接口版本
9.0.1
说明
初始化转换节点的基本参数
参数:(POST)
无
返回值:
成功:
{
"return":"0",
"memory": {
"memUse": 10.0,
"menPercent": "67",
"memAll": 15.0
},
"file": {
"fileUse": "359.6",
"fileAll": "2095.7",
"fileUsePerecent": "17"
},
"cpu": {
"cpuAll": null,
"cpu": "6",
"cpuUse": null
},
}
失败:
{
"return":"1",//1、2、3、8014
"msg":"参数错误!"
}
备注
无