文档首页> 测试计划 CodeArts TestPlan> API参考> API> 接口测试管理> 分页获取工程BasicAW详细信息列表(含目录)
更新时间:2024-06-28 GMT+08:00
分享

分页获取工程BasicAW详细信息列表(含目录)

功能介绍

分页获取工程BasicAW列表(含目录)

调试

您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。

URI

POST /v4/{project_id}/aw-cata/aw-info-list

表1 路径参数

参数

是否必选

参数类型

描述

project_id

String

项目ID,固定长度32位字符(字母和数字)。

最小长度:32

最大长度:32

表2 Query参数

参数

是否必选

参数类型

描述

page_no

String

当前页数

page_size

String

每页多少记录

parent_id

String

父目录ID

请求参数

表3 请求Header参数

参数

是否必选

参数类型

描述

X-Auth-Token

String

用户Token。

通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。

最小长度:1

最大长度:100000

表4 请求Body参数

参数

是否必选

参数类型

描述

search_type

String

过滤类型

search_value

String

过滤条件

响应参数

状态码: 200

表5 响应Body参数

参数

参数类型

描述

code

String

错误码

error

CommonResponseErrorPageResultBasicAWInfo object

统一错误返回

reason

String

失败原因

result

PageResultBasicAWInfo object

结果

status

String

状态

表6 CommonResponseErrorPageResultBasicAWInfo

参数

参数类型

描述

code

String

错误码

detail

PageResultBasicAWInfo object

错误信息详情

reason

String

错误原因

表7 PageResultBasicAWInfo

参数

参数类型

描述

page_list

Array of BasicAWInfo objects

当前页数据

page_no

Integer

当前页数

page_size

Integer

每页条数

total_page

Integer

总页数

total_size

Long

总条数

表8 BasicAWInfo

参数

参数类型

描述

aw_code

String

aw代码, hasCode为1时有效

aw_description

String

模板描述

aw_ins_list

Array of AwInstanceRes objects

组合aw包含的aw实例信息,awType为2时该字段有效

aw_mark

Integer

aw标记 0-normal;1-new;2-update 3-delete

aw_operationid

String

接口的operationId

aw_tags

String

接口的tags

aw_type

Integer

AW类型1-普通aw,2-组合aw,3-导入aw

aw_uniqueid

String

awOperationId_awTags的拼接

by_order

Integer

顺序

cata_type

Integer

目录层级

child_list

Array of BasicAWInfo objects

新增childList以支持嵌套层级结构

create_time

String

创建时间

create_time_stamp

Long

时间戳字段

create_time_string

String

时间字符串

create_user

String

创建人

create_user_id

String

创建人id

custom_aw_libs

Array of UploadFileRes objects

aw库的文件列表

delete_time

String

更新时间

delete_user

String

删除人

description

String

描述

dft_check_point_list

Array of CheckPoint objects

默认检查点List

dft_custom_header

Array of AwParam objects

默认请求头参数对象

dft_retry_interval

String

重试间隔时间 (ms) 为空表示不等待

dft_retry_times

String

重试次数

dft_variable_list

Array of AwVariable objects

默认变量信息List

extra_info

Object

补充信息

group_name

String

组名

has_code

Integer

是否自带代码 0-不自带代码,该aw依赖source字段中的源;1-自带代码

id

String

id

import_package

Array of strings

导入的包

interface_label

String

接口的x-extend

is_favorite

Integer

是否是当前工程的收藏aw,该字段不存数据库,每次获取时实时判断

is_folder

String

判断是否为文件夹的标识

keyword_variable_value

Array of AwVariable objects

关键字局部变量

method

String

方法

name

String

名称

nameView

String

aw在页面上显示的名字

origin_project

String

源工程信息,如果该aw是从其他工程过来的(继承或者copy to local)

output_param_list

Array of AwVariable objects

组合aw的输出参数信息,该字段不存数据库,实时获取

page_no

Integer

当前页数

page_size

Integer

每页条数

param_type_and_dft_value

Array of AwParam objects

参数类型和参数默认值对应List

parent_id

String

aw目录父编号

project_id

String

aw目录父编号

protocol_type

String

协议类型 (http/dsf/other)

public_aw_lib

PublicAwLibRes object

公共关键字信息

public_aw_lib_id

String

所属公共aw库Id

region

String

区域名称

return_type

String

返回类型

root_id

String

root id

source

String

来源

special_type

Integer

特殊AW类型 0-common,10-header,1-beforeHeader

tmssCaseNumber

String

关键字管理的用例编号

tmss_case_id

String

关键字aw管理的用例ID

total_page

Integer

总页数

total_size

Integer

总条数

update_time

String

更新时间

update_time_stamp

Long

更新时间戳

update_time_string

String

更新字符串

update_user

String

更新人

warningMsg

String

警告信息

yamlName

String

所属yaml文件名称,该字段不存库,用来记录从哪个yaml文件导入

表9 AwInstanceRes

参数

参数类型

描述

alias_runaw

String

AW内容描述字段

authentication_info

AuthInfo object

认证信息

authentication_type

String

认证类型,0-无认证;1-aksk认证

aw_description

String

脚本模板描述信息,在用例更新时添加

aw_id

String

aw id

aw_type

Integer

aw类型 0-setup;1-test;2-teardown

basic_aw

BasicAwRes object

basic aw

body_param_type

String

instance的参数body体类型:form/text

by_order

Integer

顺序

changeSign

Integer

change sign

check_point_list

Array of CheckPoint objects

检查点List

children

Array of AwInstanceRes objects

aw实例

condition_statement

String

条件语句

condition_type

Integer

条件类型 0-not condition;1-if begin;2-if

create_time

String

创建时间

create_time_stamp

Long

创建时间戳

create_time_string

String

创建时间字符串

create_user

String

创建人

custom_header

Array of AwParam objects

测试步骤自定义请求头List;后续自定义URL请求头不再使用该字段

description

String

描述

error_info

ErrorInfo object

执行的错误日志内容列表

extra_info

ExtraInfo object

补充信息

from_outside

Integer

该aw是否来自外部工程 0-no;1-yes

hasLevel

Integer

level

header_array

Object

header 列表

his_script

String

值不为null表示老的IF判断语句;值为null表示新的IF判断语句

id

String

id

is_basic

Integer

是否模板类型测试步骤 0:自定义URL配置类型;1:模板类型测试步骤

is_contract_aw

Integer

是否是契约AW 0-否;1-yes

is_disabled

Integer

是否被禁用 0-否;1-yes

is_sectest_aw

Integer

是否是安全测试aw

level

Integer

用例级别

name

String

名称

param_dependent

String

参数依赖规则

param_dependent_enabled

Integer

是否启用参数依赖

param_type_and_value

Array of AwParam objects

参数类型和参数值对应List

projectId

String

awinstance所在的用例\逻辑用例\组合aw所属项目,该字段是新增字段,因此部分awinstance是无值的,所以只可写该值,而不能读取该值

region

String

区域名称

relation

String

awId层级关系

relation_id

String

relation id

relation_type

Integer

映射类型 1-反向删除映射;2-用例自动添加的方向删除步骤

retry_interval

String

重试间隔时间 (ms) 为空表示不等待

retry_times

String

重试次数

scriptName

String

获取脚本生成时,要使用的步骤名称

service_and_stage

String

aw所来自工程的服务名和阶段名 fromOutside为1时该值有效

special_type

Integer

测试步骤来源

update_time

String

更新时间

update_time_stamp

Long

更新时间戳

update_time_string

String

更新时间字符串

update_user

String

更新人

user_id

String

user id

variable_list

Array of AwVariable objects

定义的变量信息

表10 AuthInfo

参数

参数类型

描述

access_key

String

访问密钥

secret_key

String

私钥

表11 BasicAwRes

参数

参数类型

描述

aw_code

String

关键字代码, hascode字段为1是有效

aw_description

String

模板描述

aw_mark

Integer

关键字标记

aw_operationid

String

关键字操作编号

aw_tags

String

关键字tags

aw_type

Integer

关键字类型

aw_uniqueid

String

关键字来源编号

by_order

Integer

关键字顺序

create_time

String

创建时间

create_time_stamp

Long

创建时间戳

create_time_string

String

创建时间戳

create_user

String

创建人

create_user_id

String

创建人ID

delete_time

String

更新时间

delete_user

String

删除人

description

String

描述

dft_check_point_list

Array of objects

默认检查点列表

dft_custom_header

Array of objects

默认请求头参数对象

dft_retry_interval

String

重试间隔时间 (ms) 为空表示不等待

dft_retry_times

String

重试次数

dft_variable_list

Array of objects

默认变量信息

extra_info

Object

补充信息

group_name

String

分组名

has_code

Integer

是否存在代码

id

String

编号

import_package

Array of strings

导入的包名

interface_label

String

接口的x-extend字段说明

is_favorite

Integer

是否收藏

method

String

方法名

name

String

关键字名

nameView

String

在页面上显示的名字

origin_project

String

源工程信息

param_type_and_dft_value

Array of objects

参数类型和参数默认值

project_id

String

工程编号

protocol_type

String

协议类型

public_aw_lib

Object

公共关键字信息

public_aw_lib_id

String

公共关键字id

region

String

region信息

return_type

String

返回值类型

root_id

String

根节点编号

source

String

关键字依赖的类源

special_type

Integer

特殊关键字类型

tmssCaseNumber

String

关键字编号(来自测试管理服务)

tmss_case_id

String

测试用例id

update_time

String

更新时间

update_time_stamp

Long

更新时间戳

update_time_string

String

更新时间戳(字符串格式)

update_user

String

更新人

warningMsg

String

警告信息

yamlName

String

yaml名称

表12 ErrorInfo

参数

参数类型

描述

error_content

String

错误内容的描述

error_index

String

错误索引的描述

error_point

String

错误点的描述

high_light

Boolean

是否高亮标识

表13 ExtraInfo

参数

参数类型

描述

childImportPackage

Array of strings

子级导入的包

document_link

String

文档链接

http_method

String

http请求方法

http_url

String

HTTP请求的URL

importPackage

Array of strings

导入的包

mock

MockInfo object

awInstance中的mock信息

outputParam

Array of AwVariable objects

输出参数

param_dependent

String

参数依赖

summary

String

摘要

表14 UploadFileRes

参数

参数类型

描述

awInsId

String

所属的AWInstance的ID

create_time

String

创建时间

create_time_stamp

Long

创建时间戳

create_time_string

String

创建时间字符串

create_user

String

创建人

current_size

Long

当前大小

filePath

String

文件路径

id

String

id

name

String

文件在系统中的名字

originName

String

文件的原名

projectId

String

项目ID

region

String

区域名称

testcase_id

String

测试用例的唯一标识符

update_time

String

更新时间

update_time_stamp

Long

更新时间戳

update_time_string

String

更新时间字符串

update_user

String

更新人

表15 CheckPoint

参数

参数类型

描述

comparison

String

运算符

description

String

描述信息

function_arg

String

响应提取时要使用什么方法处理参数

function_type

String

响应提取时要使用什么方法处理参数

枚举值:

  • REGEX

  • SUBSTRING

property

String

属性名称

value

String

表16 AwVariable

参数

参数类型

描述

by_order

Integer

节点顺序

currentPermission

String

当前人员权限

description

String

参数描述

dynamicParam

String

动态参数名称

dynamicParamFlag

Boolean

动态参数标志,默认为false:true代表动态参数;false代表非动态参数

functionParams

String

变量参数([]:空参、[a]:一参,[a,b]:两参)

function_arg

String

响应提取时要使用什么方法处理参数

function_type

String

响应提取时要使用什么方法处理参数

枚举值:

  • REGEX

  • SUBSTRING

isSensitiveInfo

Boolean

是否是敏感字段

isSensitiveModified

Boolean

敏感字段是否被修改,不敏感字段不关注此值

is_out_put

Boolean

是否是组合aw的输出参数,只有组合aw下awInstance的aw变量有该字段

name

String

参数名称

node_id

String

节点id

node_type

Integer

0/null-变量节点;1-目录节点

oldName

String

旧名称

parent_node_id

String

父节点id

property

String

属性

regex

String

内置函数枚举

sensitiveInfoSetterTime

String

敏感参数设置时间

sensitiveInfoSetterUser

String

敏感参数设置者名称

type

String

类型

variableType

Integer

变量类型(0:text,10-16:7个内置函数)

表17 AwParam

参数

参数类型

描述

basic_value

AwParamBasicValue object

aw参数基本类型取值类

basic_value_list

Array of AwParamBasicValue objects

valueType为1时该值有效

custom_body

String

自定义requestBody内容,inType为2且isBodyCustom为1时有效

defaultValue

String

默认值

description

String

aw参数描述

disabled

Boolean

是否禁用 只有非必需参数才能被禁用

drop_down_value

String

用于存储下拉菜单的值

enum_type

String

枚举类型

enum_type_selected

String

当前选中的枚举类型

format

String

num和String有效

in_type

Integer

rest接口输入参数类型 0-query 1-path 2-body 3-header 4-formdata 5-config

isChecked

Boolean

是否是被选中参数

is_big_field

Boolean

是否是大字段参数

is_body_custom

Integer

requestBody是否自定义,inType为2时有效。0-非自定义,用原有逻辑;1-自定义body,requestBody直接使用字段customBody

is_contract_param

Integer

是否是契约AW 0-否;1-yes

is_sensitive

Boolean

是否敏感参数,0 是, 1 不是

item

ItemParam object

item param

maxItems

Integer

Array类型最大元素数

maxLength

Long

String类型最大长度

maximum

Object

Number类型最大值

minItems

Integer

Array类型最小元素数

minLength

Long

String类型最小长度

minimum

Object

Number类型最小值

mock

MockInfo object

awInstance中的mock信息

name

String

参数名

object_value

Array of AwParam objects

valueType为2时该值有效。valueType为3时,该值用来表示数组中单个结构体

object_value_list

Array<Array<AwParam>>

valueType为3时该值有效

pattern

String

num和String有效

required

Boolean

是否必需参数

type

String

参数类型

validate_rule

ValidateRule object

validate rule

value_type

Integer

参数值类型

xChoiceValue

String

choice选择关系

表18 AwParamBasicValue

参数

参数类型

描述

value

String

参数默认值,用例有效

value_range

String

参数值范围,逻辑用例有效

表19 ItemParam

参数

参数类型

描述

basic_value

AwParamBasicValue object

aw参数基本类型取值类

defaultValue

String

默认值

enum_type

String

枚举类型

enum_type_selected

String

当前选中的枚举类型

format

String

num和String有效

is_big_field

Boolean

是否是大字段参数

maxItems

Integer

Array类型最大元素数

maxLength

Long

String类型最大长度

maximum

Object

Number类型最大值

minItems

Integer

Array类型最小元素数

minLength

Long

String类型最小长度

minimum

Object

Number类型最小值

pattern

String

num和String有效

type

String

参数类型

validate_rule

ValidateRule object

validate rule

value_type

Integer

参数值类型

xChoiceValue

String

choice选择关系

表20 MockInfo

参数

参数类型

描述

mock_id

String

mock id

mock_switch

Boolean

mock开关

mock_url

String

mock url

表21 ValidateRule

参数

参数类型

描述

dependent_info

Array of ConditionInstance objects

依赖信息列表

enabled

Boolean

是否启用的标识符

is_configDep

Boolean

配置依赖的标识符

is_dependent

Boolean

是否依赖的标识符

message

String

消息

result

String

结果

special_char

String

特殊字符

special_char_valid

String

特殊字符的有效性

x_example

String

示例

表22 ConditionInstance

参数

参数类型

描述

conditionIndex

Integer

条件索引,用于标识当前处理的是哪个条件

conditionMap

Map<String,Array<String>>

条件映射,键为整数,值为字符串列表,用于存储各个条件的信息

depParamMap

Map<String,DepParamInstance>

依赖参数实例的映射

statementIndex

Integer

声明索引,用于标识当前处理的是哪个声明

表23 DepParamInstance

参数

参数类型

描述

compareValue

String

比较值

comparison

String

比较

condition

Boolean

条件

inValidValues

Array of strings

无效值列表

name

String

名称

nullInfo

String

空值信息

relationMap

Map<String,String>

关系映射,key为整数,value为字符串

relationNum

Integer

关系数量

values

Array of strings

值列表

表24 PublicAwLibRes

参数

参数类型

描述

create_time

String

创建时间

create_time_stamp

Long

创建时间戳

create_time_string

String

创建时间字符串

create_user

String

创建人

document_link

String

关联公共aw时的编辑链接

id

String

id

name

String

名称

net_area

Array of strings

蓝区:Blue,绿区:Green,黄区:Yellow

obs_temp_url

String

obs临时url

product_line

String

产品线

repo_branch

String

仓库分支

repo_lib_path

String

存公共aw依赖jar包的目录

repo_password

String

仓库密码

repo_private_key

String

仓库秘钥

repo_url

String

仓库地址

repo_username

String

仓库用户名

update_time

String

更新时间

update_time_stamp

Long

更新时间戳

update_time_string

String

更新时间字符串

update_user

String

更新人

请求示例

post https://{endpoint}/v4/09645c1f3f954a8d9ab29174857cffc5/aw-cata/aw-info-list?page_no=1&page_size=10

{
  "search_type" : "",
  "search_value" : ""
}

响应示例

状态码: 200

OK

{
  "status" : "success",
  "result" : {
    "page_no" : 1,
    "page_size" : 10,
    "total_page" : 1,
    "total_size" : 1,
    "page_list" : [ {
      "id" : "dfaba6a51f024c1f95229c1059ca34e0",
      "warningMsg" : null,
      "source" : "",
      "method" : "",
      "description" : null,
      "nameView" : null,
      "tmssCaseNumber" : null,
      "region" : null,
      "yamlName" : null,
      "create_time_string" : "2024-04-11 19:48:13 GMT+08:00",
      "update_time_string" : "2024-04-11 19:48:13 GMT+08:00",
      "create_time_stamp" : 1712836093000,
      "update_time_stamp" : 1712836093000,
      "create_user" : "devcloud_devcloud_s00314720_01",
      "create_time" : "2024-04-11T07:48:13+0800",
      "update_user" : "devcloud_devcloud_s00314720_01",
      "update_time" : "2024-04-11T07:48:13+0800",
      "name" : "默认文件夹",
      "param_type_and_dft_value" : null,
      "dft_custom_header" : null,
      "dft_check_point_list" : null,
      "dft_variable_list" : null,
      "keyword_variable_value" : null,
      "dft_retry_times" : "",
      "dft_retry_interval" : "",
      "return_type" : "",
      "aw_type" : 0,
      "aw_ins_list" : null,
      "project_id" : "09645c1f3f954a8d9ab29174857cffc5",
      "public_aw_lib_id" : "",
      "special_type" : null,
      "has_code" : null,
      "aw_code" : "",
      "group_name" : "",
      "protocol_type" : "",
      "by_order" : null,
      "aw_mark" : null,
      "output_param_list" : null,
      "is_favorite" : null,
      "tmss_case_id" : null,
      "create_user_id" : "",
      "aw_description" : null,
      "origin_project" : null,
      "aw_uniqueid" : null,
      "aw_tags" : null,
      "aw_operationid" : null,
      "interface_label" : null,
      "import_package" : null,
      "public_aw_lib" : null,
      "root_id" : null,
      "custom_aw_libs" : null,
      "delete_time" : null,
      "delete_user" : null,
      "parent_id" : "TOP",
      "is_folder" : "0",
      "cata_type" : 4,
      "page_no" : null,
      "page_size" : null,
      "total_page" : null,
      "total_size" : null,
      "child_list" : [ ],
      "extra_info" : null
    } ]
  },
  "reason" : null,
  "error" : null,
  "code" : null
}

状态码

状态码

描述

200

OK

201

Created

401

Unauthorized

403

Forbidden

404

Not Found

错误码

请参见错误码

分享:

    相关文档

    相关产品