模版管理-获取模版列表

请求方法/请求路径

GET /ms/openapi/api/apigw/v3/projects/{projectId}/templates

资源描述

模版管理-获取模版列表

输入参数说明

Query参数

参数名称参数类型必须参数说明默认值

templateType

string

模版类型

storeFlag

boolean

是否已关联到store

Path参数

参数名称参数类型必须参数说明默认值

projectId

string

项目ID

响应

HTTP代码说明参数类型

200

successful operation

请求样例

curl -X GET '[请替换为API地址栏请求地址]?templateType={templateType}&storeFlag={storeFlag}' \
-H 'X-DEVOPS-UID:xxx'

HEADER样例

accept: application/json
Content-Type: application/json
X-DEVOPS-UID:xxx

返回样例-200

{
  "data" : {
    "models" : [ {
      "templateType" : "String",
      "associatePipelines" : [ {
        "id" : "String"
      } ],
      "hasPermission" : true,
      "name" : "String",
      "templateTypeDesc" : "String",
      "templateId" : "String",
      "versionName" : "String",
      "version" : 0,
      "hasInstance2Upgrade" : true,
      "logoUrl" : "String",
      "storeFlag" : true,
      "associateCodes" : "string"
    } ],
    "hasPermission" : true,
    "count" : 0,
    "projectId" : "String"
  },
  "message" : "String",
  "status" : 0
}

数据返回包装模型TemplateListModel

参数名称参数类型必须参数说明

data

数据

message

string

错误信息

status

integer

状态码

TemplateListModel

参数名称参数类型必须参数说明

models

models

hasPermission

boolean

hasPermission

count

integer

count

projectId

string

projectId

TemplateModel

参数名称参数类型必须参数说明

templateType

string

模板类型

associatePipelines

关联的流水线

hasPermission

boolean

是否有模版操作权限

name

string

模版名称

templateTypeDesc

string

模板类型描述

templateId

string

模版ID

versionName

string

最新版本号

version

integer

版本ID

hasInstance2Upgrade

boolean

是否有可更新实例

logoUrl

string

模版logo

storeFlag

boolean

是否关联到市场

associateCodes

List

关联的代码库

流水线模型-ID

参数名称参数类型必须参数说明

id

string

流水线ID

最后更新于