文档

GetFunctionVersion - 获取版本详情

根据版本ID获取版本信息。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息

当前API暂无授权信息透出。

请求语法

GET /v4/openapi/functions/{functionName}/versions/{versionId}

请求参数

名称类型必填描述示例值
functionNamestring

功能名称

ctr
versionIdinteger

版本 id

100

示例

GET /v4/openapi/functions/ctr/version/101

返回参数

名称类型描述示例值
object

响应体

Statusstring

请求状态

OK
HttpCodelong

http 状态码

200
RequestIdstring

请求 id

1638157479281
Messagestring

错误信息

version not exist.
Codestring

错误码

Version.NotExist
Resultobject

结果体

FunctionNamestring

功能名称

ctr
FunctionTypestring

功能类型

  • PAAS
  • SAAS
PAAS
ModelTypestring

模型类型

tf_checkpoint
VersionConfigobject

配置信息

CreateParametersobject []

创建实例时使用的参数列表

[ { "name": "params1", "required": "true", "formItemProps": "{\"required\": true, \"pattern?\": \"/^[a-zA-Z][a-zA-Z0-9_]{0,29}$/\"}", "componentProps": "{\"component\": \"Input\", \"attributes\": {\"defaultValue\": \"value1\"}}" } ]
Namestring

Name

params1
Requiredstring

Required

true
Dependsobject []

实例的依赖项列表

[ { "dependency": "依赖项", "condition": "条件", "description": "" } ]
Conditionstring

条件

""
Dependencystring

依赖项

""
Descriptionstring

描述

""
UsageParametersobject []

实例在线使用过程中的参数列表

[]
Namestring

Name

""
Requiredstring

Required

""
VersionIdlong

版本 ID

101
VersionNamestring

版本名称

v1
Latencylong

任务最大运行时间

123

正常返回示例

{
    "status": "OK",
    "requestId": "",
    "httpCode": 200,
    "code": "",
    "message": "",
    "latency": 123,
    "result": {
        "versionName": "v1",
        "versionId": 101,
        "functionName": "ctr",
        "modelType": "tf_checkpoint",
        "functionType": "PAAS",
        "versionConfig": {
            "createParameters": [
                {
                    "name": "params1",
                    "required": "true",
                    "formItemProps": "{\"required\": true, \"pattern?\": \"/^[a-zA-Z][a-zA-Z0-9_]{0,29}$/\"}",
                    "componentProps": "{\"component\": \"Input\", \"attributes\": {\"defaultValue\": \"value1\"}}"
                }
            ],
            "depends": [
                {
                    "dependency": "依赖项",
                    "condition": "条件",
                    "description": ""
                }
            ],
            "usageParameters": []
        }
    }
}

示例

正常返回示例

JSON格式

{
  "Status": "OK",
  "HttpCode": 200,
  "RequestId": "1638157479281",
  "Message": "version not exist.",
  "Code": "Version.NotExist",
  "Result": {
    "FunctionName": "ctr",
    "FunctionType": "PAAS",
    "ModelType": "tf_checkpoint",
    "VersionConfig": {
      "CreateParameters": [
        {
          "Name": "params1",
          "Required": "true"
        }
      ],
      "Depends": [
        {
          "Condition": "\"\"",
          "Dependency": "\"\"",
          "Description": "\"\""
        }
      ],
      "UsageParameters": [
        {
          "Name": "\"\"",
          "Required": "\"\""
        }
      ]
    },
    "VersionId": 101,
    "VersionName": "v1"
  },
  "Latency": 123
}

错误码

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
暂无变更历史
  • 本页导读 (0)
文档反馈