diff --git "a/API_SPECS/1.\347\256\241\347\220\206\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\241\347\220\206\345\261\202API.md" "b/API_SPECS/1.\347\256\241\347\220\206\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\241\347\220\206\345\261\202API.md" index 037775c..5da0471 100644 --- "a/API_SPECS/1.\347\256\241\347\220\206\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\241\347\220\206\345\261\202API.md" +++ "b/API_SPECS/1.\347\256\241\347\220\206\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\241\347\220\206\345\261\202API.md" @@ -36,11 +36,15 @@ - [7.2 流程审批确认](#72-流程审批确认) - [7.3 流程审批解除](#73-流程审批解除) - [7.4 流程审批状态查询](#74-流程审批状态查询) - - [8 模型互通接口](#8-模型互通接口) - - [8.1 合作模型审批](#81-合作模型审批) - - [8.2 合作模型审批确认](#82-合作模型审批确认) - - [8.3 合作模型审批解除](#83-合作模型审批解除) - - [8.4 合作模型审批查询](#84-合作模型审批查询) + - [8 作业互通接口](#8-作业互通接口) + - [8.1 作业审批接口](#81-作业审批接口) + - [8.2 作业审批确认](#82-作业审批确认) + - [8.3 作业审批解除(可选)](#83-作业审批解除可选) + - [9 模型互通接口](#9-模型互通接口) + - [9.1 合作模型审批](#91-合作模型审批) + - [9.2 合作模型审批确认](#92-合作模型审批确认) + - [9.3 合作模型审批解除](#93-合作模型审批解除) + - [9.4 合作模型审批查询](#94-合作模型审批查询) ## 1 整体框架 @@ -56,7 +60,7 @@ **文档版本** ``` -v1.0.0 +v1.1.0 ``` ## 2 通用报文头规范及公共出参 @@ -72,8 +76,8 @@ HTTP Method:读GET,写POST ```python Request Header: -x-auth-sign:利用签约时指定的算法构造的签名值,用于安全校验 -x-csrf-protection: 避免跨站点请求伪造攻击, POST时必选 +x-auth-sign:利用签约时指定的算法构造的签名值,用于安全校验,节点签约完成后才能生成,节点信息查询、合作申请、更新合作意向接口header无需包含 +x-csrf-protection: 避免跨站点请求伪造攻击,POST时必选 x-source-node-id:请求方节点id; x-target-node-id:目的方节点id; x-nonce:系统生成的防重放随机串,如 UUID @@ -90,13 +94,13 @@ x-mprac-token-set:多方资源访问控制的许可凭证 ### 2.3 公共出参 -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 中文名 | 说明 | -| ---- | ------ | ---- | ------------ | ------------------ | -| code | int32 | true | 状态码 | 200 正常,否则错误 | -| msg | string | true | 错误信息 | none | -| data | object | true | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 中文名 | 说明 | +| ---- | ------ | ---- | ------------ | ---------------- | +| code | int32 | true | 状态码 | 0 正常,否则错误 | +| msg | string | true | 错误信息 | none | +| data | object | true | 响应数据内容 | none | ## 3 节点互通接口 @@ -117,10 +121,10 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | auth_type | string | | true | 认证方式:公钥、证书 | | description | string | | | 节点描述 | | expired_time | int64 | | | 合约过期时间,时区约定 Asia/Shanghai | -| inst_id | string | | true | 机构 Id | +| inst_id | string | | true | 合作方机构 Id | | institution | string | | true | 节点所属机构 | | name | string | | true | 节点名称 | -| node_id | string | | true | 合作方的节点 Id | +| node_id | string | | true | 发起方的节点 Id | | system | string | | true | 技术服务提供系统 | | system_version | string | | true | 系统版本 | @@ -128,15 +132,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | -------------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ contract_id | string | | true | 合约 id | @@ -163,11 +167,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** ### 3.3 节点合约解除 @@ -187,17 +191,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 3.4 更新节点信息(可选) @@ -226,17 +230,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 3.5 节点合作查询 @@ -256,15 +260,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | ---------------------------------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ status | string | | true | 合约状态。枚举值:REJECTED-已拒绝,APPROVED-已接受,TERMINATED-已解除,APPLIED-已申请 | @@ -287,15 +291,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | ----------------- | ------ | ------ | ------ | --------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ address | string | | true | 节点服务地址 | @@ -324,15 +328,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ status | string | | true | 节点健康状态,直接返回 ok | @@ -359,15 +363,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------------------- | ------------- | ------ | ------ | ------------------------------------------------------------ | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ records | array[object] | | true | 数据 | @@ -403,15 +407,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | ------------------ | ------------- | ------ | ------ | ------------------------------------------------------------ | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ category | string | | | 数据类别 | @@ -436,29 +440,30 @@ x-mprac-token-set:多方资源访问控制的许可凭证 **请求体(Request Body)** -| 参数名称 | 数据类型 | 默认值 | 不为空 | 描述 | -| ----------- | -------- | ------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| audit_id | string | | true | 审批 id | +| 参数名称 | 数据类型 | 默认值 | 不为空 | 描述 | +| ----------- | -------- | ------ | ------ | ------------------------------------------------------------ | +| audit_id | string | | true | 审批 id | | auth_scope | map | | | 数据集授权适用范围。key 对应授权范围的类型,取值为:NODE 节点级 PROJECT 项目级 COMPONENT 组件级 value 为该类型具体的授权对象唯一 id 列表。样例:{"PROJECT": ["project_123"],"COMPONENT": ["psi"]} | -| contract_id | string | | true | 合约 id | -| dataset_id | string | | true | 数据集 id | -| time_limit | int64 | | | 访问时间限制 | +| contract_id | string | | true | 合约 id | +| dataset_id | string | | true | 数据集 id | +| time_limit | int64 | | | 访问时间限制 | +| times_limit | int32 | | | 访问次数限制 | **返回结果** | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 4.4 数据集授权意向更新 @@ -479,8 +484,8 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | ⇥ resource_level | int32 | | true | 资源等级 | | ⇥ resource_type | string | | true | 资源类型 | | ⇥ resource_id | string | | true | 资源 ID | -| ⇥ resourse_node_id | string | | true | 资源提供方的节点 ID | -| ⇥ resourse_inst_id | string | | true | 资源提供方的机构 ID | +| ⇥ resource_node_id | string | | true | 资源提供方的节点 ID | +| ⇥ resource_inst_id | string | | true | 资源提供方的机构 ID | | ⇥ request_node_id | string | | true | 资源使用方的节点 ID | | ⇥ request_inst_id | string | | true | 资源使用方的机构 ID | | ⇥ time_limit | int64 | | | 访问时间限制 | @@ -490,17 +495,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 4.5 数据集授权解除 @@ -520,17 +525,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 4.6 数据集授权状态查询 @@ -550,15 +555,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | ---------------------------------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ status | string | | true | 授权状态。枚举值:APPLIED 已申请 APPROVED 已授权 REJECTED 已拒绝 TERMINATED 已解除 | @@ -594,17 +599,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 5.2 项目审批确认 @@ -626,17 +631,17 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| -------- | ------ | ------ | ------ | -------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | -| msg | string | | true | 错误信息 | -| data | object | | true | 响应数据内容 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | ------------------------ | +| code | int32 | | true | 状态码。0 正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | true | 响应数据内容 | ### 5.3 项目审批解除 @@ -656,11 +661,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** ### 5.4 项目审批状态查询 @@ -680,11 +685,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | ---------------------------------------------------------------------------------- | @@ -713,15 +718,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | ----------------- | ------------- | ------ | ------ | ------------------------------------------------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ records | array[object] | | true | 数据 | @@ -750,15 +755,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | -------------- | ----------- | ------ | ------ | -------------------------------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ nodes | array[Node] | | true | 项目的参与节点列表 | @@ -780,27 +785,27 @@ x-mprac-token-set:多方资源访问控制的许可凭证 **请求参数(****Query**** Param)** -| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | -| ---------- | ------ | ------ | ------ | -------------------------------------------------- | -| category | string | | | 所属分类,如 LOADER、FEATURE_ENGINEERING… | -| contractId | string | | 是 | 合约 ID | -| developer | string | | | 组件开发者,如:baidu、webank | -| page_num | int32 | | | 页码,从 1 开始 | -| page_size | int32 | | | 每页查询数据量,默认 20,page_size=-1 时为全量查询 | +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| ----------- | ------ | ------ | ------ | -------------------------------------------------- | +| category | string | | | 所属分类,如 LOADER、FEATURE_ENGINEERING… | +| contract_Id | string | | 是 | 合约 ID | +| developer | string | | | 组件开发者,如:baidu、webank | +| page_num | int32 | | | 页码,从 1 开始 | +| page_size | int32 | | | 每页查询数据量,默认 20,page_size=-1 时为全量查询 | **返回结果** | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------------- | ------------- | ------ | ------ | ---------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ records | array[object] | | true | 数据 | @@ -830,15 +835,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | -------------- | ------------- | ------ | ------ | ---------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ category | string | | | 所属分类,如加载器、特征工程 | @@ -879,11 +884,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** ### 7.2 流程审批确认 @@ -905,11 +910,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** ### 7.3 流程审批解除 @@ -929,11 +934,11 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** ### 7.4 流程审批状态查询 @@ -953,22 +958,122 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | --------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ status | string | | true | 审批状态,枚举值:APPLIED、REJECTED、APPROVED、TERMINATED | -## 8 模型互通接口 +## 8 作业互通接口 + +### 8.1 作业审批接口 + +>POST /v1/interconn/job/audit/apply + +**接口描述** + +>请求对方节点进行作业审批 + +**请求体(Request Body)** + +| 参数名称 | 数据类型 | 默认值 | 不为空 | 描述 | +| ---------- | -------- | ------ | ------ | -------------- | +| audit_id | string | | true | 审批id | +| job_id | string | | true | 作业 id | +| flow_id | string | | true | 作业所属流程 | +| name | string | | true | 作业名称 | +| project_id | string | | true | 作业所属项目id | +| dag | DAG | | true | 流程DAG | +| conf | CONF | | true | 作业运行配置 | + +**返回结果** + +| 状态码 | 状态码含义 | 说明 | 数据模型 | +| ------ | ------------------------------------------------------- | ---- | -------- | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | + +**返回数据结构** + +状态码 **0** + +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | -------------------------- | +| code | int32 | | true | 状态码。0正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | | 相应数据内容,成功时可为空 | + +### 8.2 作业审批确认 + +> POST /v1/interconn/job/audit/confirm + +**接口描述** + +> 审批合作方发起的作业审批请求 + +**请求体(Request Body)** + +| 参数名称 | 数据类型 | 默认值 | 不为空 | 描述 | +| --------------- | -------- | ------ | ------ | ---------------------------------- | +| audit_id | string | | true | 审批id | +| status | string | | true | 审批状态,枚举值APPROVED、REJECTED | +| resource_permit | string | | | 资源许可凭证 | + +**返回结果** + +| 状态码 | 状态码含义 | 说明 | 数据模型 | +| ------ | ------------------------------------------------------- | ---- | -------- | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | + +**返回数据结构** + +状态码 **0** + +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | -------------------------- | +| code | int32 | | true | 状态码。0正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | | 相应数据内容,成功时可为空 | + +### 8.3 作业审批解除(可选) + +> POST /v1/interconn/job/audit/terminate + +**接口描述** + +> 撤销已通过审批的作业 + +**请求体(Request Body)** + +| 参数名称 | 数据类型 | 默认值 | 不为空 | 描述 | +| -------- | -------- | ------ | ------ | ------ | +| audit_id | string | | true | 审批id | + +**返回结果** + +| 状态码 | 状态码含义 | 说明 | 数据模型 | +| ------ | ------------------------------------------------------- | ---- | -------- | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | + +**返回数据结构** + +状态码 **0** + +| 参数名称 | 类型 | 默认值 | 不为空 | 描述 | +| -------- | ------ | ------ | ------ | -------------------------- | +| code | int32 | | true | 状态码。0正常,否则错误 | +| msg | string | | true | 错误信息 | +| data | object | | | 相应数据内容,成功时可为空 | + +## 9 模型互通接口 -### 8.1 合作模型审批 +### 9.1 合作模型审批 > POST /v1/interconn/model/audit/apply @@ -990,13 +1095,13 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -### 8.2 合作模型审批确认 +### 9.2 合作模型审批确认 > POST /v1/interconn/model/audit/confirm @@ -1016,13 +1121,13 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -### 8.3 合作模型审批解除 +### 9.3 合作模型审批解除 > POST /v1/interconn/model/audit/terminate @@ -1040,13 +1145,13 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -### 8.4 合作模型审批查询 +### 9.4 合作模型审批查询 > GET /v1/interconn/model/audit/query @@ -1064,15 +1169,15 @@ x-mprac-token-set:多方资源访问控制的许可凭证 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 参数名称 | 类型 | 默认值 | 不为空 | 描述 | | --------- | ------ | ------ | ------ | --------------------------------------------------------- | -| code | int32 | | true | 状态码。200 正常,否则错误 | +| code | int32 | | true | 状态码。0 正常,否则错误 | | msg | string | | true | 错误信息 | | data | object | | true | 响应数据内容 | | ⇥ status | string | | true | 审批状态,枚举值:APPLIED、REJECTED、APPROVED、TERMINATED | diff --git "a/API_SPECS/2.\346\216\247\345\210\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\346\216\247\345\210\266\345\261\202API.md" "b/API_SPECS/2.\346\216\247\345\210\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\346\216\247\345\210\266\345\261\202API.md" index 1707bda..289339e 100644 --- "a/API_SPECS/2.\346\216\247\345\210\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\346\216\247\345\210\266\345\261\202API.md" +++ "b/API_SPECS/2.\346\216\247\345\210\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\346\216\247\345\210\266\345\261\202API.md" @@ -16,7 +16,6 @@ - [3.7 查询作业状态-调度方](#37-查询作业状态-调度方) - [3.8 查询任务回调信息](#38-查询任务回调信息) - [3.9 推送任务回调信息](#39-推送任务回调信息) - - [3.10 作业审批确认](#310-作业审批确认) - [4 任务信息回调接口](#4-任务信息回调接口) - [4.1 回调任务信息](#41-回调任务信息) - [5 流程调度接口(南北向)](#5-流程调度接口南北向) @@ -49,7 +48,7 @@ **文档版本** ``` -v1.0.0 +v1.1.0 ``` ## 2 通用报文头规范及公共出参 @@ -65,7 +64,7 @@ HTTP Method:读GET,写POST ``` Request Header: -x-auth-sign: required 利用签约时指定的算法构造的签名值,用于安全校验,节点信息查询、合作申请、更新合作意向接口header无需包含X-Auth-Sign,节点签约完成后才能生成签名值; +x-auth-sign: required 利用签约时指定的算法构造的签名值,用于安全校验,节点签约完成后才能生成,节点信息查询、合作申请、更新合作意向接口header无需包含; x-csrf-protection: required 避免跨站点请求伪造攻击, POST时必选 x-source-node-id: required 请求方节点id; x-target-node-id: required 目的方节点id; @@ -75,17 +74,17 @@ x-timestamp: required 调用方毫秒时间戳(Unix epoch time,具 x-mprac-token-set: required 多方资源访问控制的许可凭证,用于多方资源访问控制,是资源的使用方向资源的持有方发资源操作时,所需要的凭证集合,集合元组之间,用逗号分割,单个许可凭证的格式定义如下为:统一资源名称/资源等级/资源授权令牌 ``` -注:调度层需协商生成 session-id,{session-id}={job-id} +注:调度层需协商生成 session-id,{session-id}={"session_"+job-id} ### 2.3 公共出参 -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 中文名 | 说明 | -| ---- | ------ | ---- | ------------ | ------------------ | -| code | int32 | true | 状态码 | 200 正常,否则错误 | -| msg | string | true | 错误信息 | none | -| data | object | true | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 中文名 | 说明 | +| ---- | ------ | ---- | ------------ | ---------------- | +| code | int32 | true | 状态码 | 0 正常,否则错误 | +| msg | string | true | 错误信息 | none | +| data | object | true | 响应数据内容 | none | ## 3 流程调度接口(东西向) @@ -202,21 +201,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -339,21 +338,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -389,21 +388,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -443,21 +442,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -495,21 +494,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -547,21 +546,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -589,15 +588,15 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ------------ | ------- | ---- | ---- | ------------------ | -------------------------------------------------- | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥job_status | string | true | none | 作业状态 | 状态有 PENDING、READY、REJECTED、RUNNING、FINISHED | @@ -605,7 +604,7 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 > 返回示例 -> 200 Response +> 0 Response ```json { @@ -646,22 +645,22 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | -------- | ------- | ---- | ---- | ------------ | ---------------------------------------- | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥status | string | true | none | 状态 | PENDING、READY、RUNNING、SUCCESS、FAILED | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -703,73 +702,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response - -```json -{ - "code": 0, - "msg": "string", - "data": {} -} -``` - -### 3.10 作业审批确认 - -> POST /v1/interconn/schedule/job/audit_confirm - -**接口描述** - -某个参与方向调度方或发起方作业审批结果时调用的接口 - -**请求参数** - -| 名称 | 位置 | 类型 | 必选 | 中文名 | 说明 | -| ------ | ---- | ------ | ---- | -------- | --------------- | -| job_id | body | string | 是 | 作业 ID | none | -| status | body | string | 是 | 作业状态 | READY、REJECTED | - -> Body 请求参数 - -```json -{ - "job_id": "string", - "status": "string" -} -``` - -**返回结果** - -| 状态码 | 状态码含义 | 说明 | 数据模型 | -| ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | - -**返回数据结构** - -状态码 **200** - -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | - -> 返回示例 - -> 200 Response +> 0 Response ```json { @@ -811,21 +758,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -948,22 +895,22 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | -------- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥job_id | string | true | none | 作业 ID | 全局唯一 | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1001,21 +948,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1043,15 +990,15 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ------------ | ------- | ----- | ---- | ------------------ | ---------------------------------------------------------------------------------------------------- | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥job_status | string | true | none | 作业状态 | 状态有 PENDING、READY、REJECTED、RUNNING、FINISHED | @@ -1059,7 +1006,7 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1091,22 +1038,22 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ----- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥num | integer | true | none | 日志行数 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1139,22 +1086,22 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ------ | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥data | string | true | none | 日志内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1184,22 +1131,22 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ---------- | ------- | ---- | ---- | ------------ | --------------------------------------------------------------------------------------------------- | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | msg | string | true | none | 错误信息 | none | | data | object | true | none | 响应数据内容 | none | | ⇥job_list | object | true | none | 作业列表 | 作业列表,key 为 job_id,value 为作业的状态,作业状态有 PENDING、READY、REJECTED、RUNNING、FINISHED | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1239,11 +1186,11 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | response | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | response | > 返回示例 -> 200 Response +> 0 Response ```json { @@ -1380,21 +1327,21 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | -| ---- | ------- | ---- | ---- | ------------ | ------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | -| msg | string | true | none | 错误信息 | none | -| data | object | true | none | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | +| ---- | ------- | ---- | ---- | ------------ | ---------------- | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | +| msg | string | true | none | 错误信息 | none | +| data | object | true | none | 响应数据内容 | none | > 返回示例 -> 200 Response +> 0 Response ```json { diff --git "a/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/README.md" "b/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/README.md" index 86cdc3f..0e82371 100644 --- "a/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/README.md" +++ "b/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/README.md" @@ -8,15 +8,16 @@ 关于接口 API 内容如有问题可以联系我们,联系方式如下: -| 姓名 | 单位 | 联系方式 | -| ------ | ---------------- | --------------------------------------------------------- | -| 丁亚丹 | 中国银联 | dingyadan@unionpay.com | -| 刘瑞 | 上海浦东发展银行 | liur29@spdb.com.cn | -| 龚乐诚 | 上海浦东发展银行 | gonglc@spdb.com.cn | -| 靳新 | 洞见科技 | jinxin@insightone.cn | -| 赵永坤 | 洞见科技 | zhaoyongkun@insightone.cn| -| 马煜翔 | 蓝象智联 | zichen.ma@trustbe.cn | -| 王超 | 蓝象智联 | congying.wang@trustbe.cn | +| 姓名 | 单位 | 联系方式 | +| ------ | ---------------- | ------------------------- | +| 丁亚丹 | 中国银联 | dingyadan@unionpay.com | +| 谢袁源 | 中国银联 | xieyuanyuan@unionpay.com | +| 刘瑞 | 上海浦东发展银行 | liur29@spdb.com.cn | +| 龚乐诚 | 上海浦东发展银行 | gonglc@spdb.com.cn | +| 靳新 | 洞见科技 | jinxin@insightone.cn | +| 赵永坤 | 洞见科技 | zhaoyongkun@insightone.cn | +| 马煜翔 | 蓝象智联 | zichen.ma@trustbe.cn | +| 王超 | 蓝象智联 | congying.wang@trustbe.cn | ## 目录结构 @@ -25,7 +26,7 @@ InterOp ├─ LICENSE ├─ README.md # 互联互通统一框架,贡献单位,版权声明等 └─ 互联互通集成对接指引 # 存放对接指引,注意事项等相关内容 -└─ 互联互通API接口文档 +└─ 互联互通API接口规范 ├─ README.md # 子模块概述,Contributor联系方式等 └─ 算法组件层接口 ├── README.md # 模块简介,Contributor联系方式等 diff --git "a/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202API.md" "b/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202API.md" index e50881c..c229121 100644 --- "a/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202API.md" +++ "b/API_SPECS/3.\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\347\256\227\346\263\225\347\273\204\344\273\266\345\261\202API.md" @@ -49,7 +49,7 @@ **文档版本** ``` -v1.0.0 +v1.1.0 ``` ## 2 算法组件自描述文件 @@ -449,13 +449,13 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 #### 3.1.3 公共出参 -状态码 **200** +状态码 **0** -| 名称 | 类型 | 必选 | 中文名 | 说明 | -| ---- | ------ | ---- | ------------ | ------------------ | -| code | int32 | true | 状态码 | 200 正常,否则错误 | -| msg | string | true | 错误信息 | none | -| data | object | true | 响应数据内容 | none | +| 名称 | 类型 | 必选 | 中文名 | 说明 | +| ---- | ------ | ---- | ------------ | ---------------- | +| code | int32 | true | 状态码 | 0 正常,否则错误 | +| msg | string | true | 错误信息 | none | +| data | object | true | 响应数据内容 | none | ### 3.2 接口定义 @@ -487,25 +487,25 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | 状态码 | 状态码含义 | 说明 | 数据模型 | | ------ | ------------------------------------------------------- | ---- | -------- | -| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | +| 0 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | 成功 | Inline | **返回数据结构** -状态码 **200** +状态码 **0** | 名称 | 类型 | 必选 | 约束 | 中文名 | 说明 | | ------ | ------- | ---- | ---- | -------- | ------------------------ | -| code | integer | true | none | 状态码 | 200 正常,否则错误 | +| code | integer | true | none | 状态码 | 0 正常,否则错误 | | status | string | true | none | 任务状态 | RUNNING、SUCCESS、FAILED | | role | string | true | none | 角色 | 任务节点所属角色 | > 返回示例 -> 200 Response +> 0 Response ```json { - "code": 200, + "code": 0, "status": "RUNNING", "role": "host", } @@ -518,7 +518,7 @@ x-mprac-token-set: required 多方资源访问控制的许可凭证,用于 | **标识名称** | **可选性** | **标识含义** | **描述** | | ---------------- | ---------- | ---------------- | -------------------------------------------- | | system.storage | 必选 | 存储层服务地址 | 支持配置多个存储服务地址 | -| system.callback | 可选 | 调度层回调地址 | 可通过接口回调,也可通过容器运行结果,或其他 | +| system.callback | 必选 | 调度层回调地址 | 可通过接口回调,也可通过容器运行结果,或其他 | | system.transport | 必选 | 传输服务地址 | 填写传输地址信息 | | system.compute | 可选 | 计算引擎服务地址 | 填写引擎服务地址信息 | | system.control_port | 可选 | 信息查询端口 | 填写算法容器对外的信息查询端口,默认10086 | @@ -861,7 +861,7 @@ x-ptp-target-inst-id: optional 接收端机构编号,全网唯一 **响应体** -200 响应数据格式:JSON +0 响应数据格式:JSON | 参数名称 | 数据类型 | 可选 | 描述 | | --------------- | ------------- | ----- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | @@ -888,7 +888,7 @@ x-ptp-target-inst-id: optional 接收端机构编号,全网唯一 **响应体** -200 响应数据格式:JSON +0 响应数据格式:JSON | 参数名称 | 数据类型 | 可选 | 描述 | | --------------- | ------------- | ----- | ---------------------------------- | @@ -921,7 +921,7 @@ x-ptp-target-inst-id: optional 接收端机构编号,全网唯一 **响应体** -200 响应数据格式:JSON +0 响应数据格式:JSON | 参数名称 | 数据类型 | 可选 | 描述 | | --------------- | ------------- | ----- | ---------------------------------------------------------------------------------------------------------------------------------------- | @@ -956,7 +956,7 @@ x-ptp-target-inst-id: optional 接收端机构编号,全网唯一 **响应体** -200 响应数据格式:JSON +0 响应数据格式:JSON | 参数名称 | 数据类型 | 可选 | 描述 | | --------------- | ------------- | ----- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | diff --git "a/API_SPECS/4.\344\274\240\350\276\223\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\344\274\240\350\276\223\345\261\202API.md" "b/API_SPECS/4.\344\274\240\350\276\223\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\344\274\240\350\276\223\345\261\202API.md" index 07135ea..ab73ee5 100644 --- "a/API_SPECS/4.\344\274\240\350\276\223\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\344\274\240\350\276\223\345\261\202API.md" +++ "b/API_SPECS/4.\344\274\240\350\276\223\345\261\202\346\216\245\345\217\243/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\344\274\240\350\276\223\345\261\202API.md" @@ -28,7 +28,7 @@ **文档版本** ``` -v1.0.0 +v1.1.0 ``` ## 2 节点间通信接口 diff --git "a/API_SPECS/5.\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256.md" "b/API_SPECS/5.\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256.md" index 17b21fa..95ea848 100644 --- "a/API_SPECS/5.\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256.md" +++ "b/API_SPECS/5.\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256/\351\232\220\347\247\201\350\256\241\347\256\227\344\272\222\350\201\224\344\272\222\351\200\232\345\274\200\346\224\276\347\256\227\346\263\225\345\215\217\350\256\256.md" @@ -50,7 +50,7 @@ ECDH-PSI 算法整体框架如下图所示,共包括五个步骤: **文档版本** ``` -v1.0.0 +v1.1.0 ``` ## 2 算法层接口 diff --git a/GUIDE/README.md b/GUIDE/README.md index 4bb95d7..495fb14 100644 --- a/GUIDE/README.md +++ b/GUIDE/README.md @@ -11,6 +11,7 @@ | 姓名 | 单位 | 联系方式 | | ------ | -------- | --------------------------------------------------- | | 丁亚丹 | 中国银联 | dingyadan@unionpay.com| +| 谢袁源 | 中国银联 | xieyuanyuan@unionpay.com | | 王思婷 | 招商银行 | w_siting@cmbchina.com | | 刘瑞 | 上海浦东发展银行 | liur29@spdb.com.cn | | 龚乐诚 | 上海浦东发展银行 | gonglc@spdb.com.cn |