Updated on 2023-12-28 GMT+08:00

Coordinated Search

Function

Coordinated search.

URI

POST /cloudartifact/v5/tree/repos/artifacts

Request Parameters

Table 1 Request body parameters

Parameter

Mandatory

Type

Description

artifact_name

Yes

String

Search for artifact names.

artifact_type

No

String

Artifact type.

page_no

No

String

Page number.

page_size

No

String

Number of items on each page.

project_id

No

String

Project ID.

in_project

No

String

Whether it is in project or not.

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

status

String

Result status.

trace_id

String

Request ID.

result

String

Returned result of the request. The return value varies according to the API.

Example Requests

Coordinated search.

https://artifact.cn-south-1.myhuaweicloud.com/cloudartifact/v5/tree/repos/artifacts

{
  "artifact_name" : "mod.txt",
  "artifact_type" : "pypi",
  "page_no" : 1,
  "page_size" : 10,
  "project_id" : "e2ee90487d6349dd944a5767225f6f55",
  "in_project" : true
}

Example Responses

Status code: 200

OK

{
  "status" : "success",
  "trace_id" : "143002-1701221035715-403",
  "result" : {
    "artifacts" : [ {
      "name" : "mod.txt",
      "relativePath" : "1/1/mod.txt",
      "createdBy" : "cn-north-7_5a775fdcb14f4431b6c0015618140bc3_e9253deb37654775bb3c411aca89153a",
      "createdUserName" : "devcloud_devcloud_y00226182_01",
      "created" : "1701220753711",
      "modified" : "2023-11-29T09:19:13.711+08:00",
      "repo" : "cn-north-7_5a775fdcb14f4431b6c0015618140bc3_pypi_40",
      "repoName" : "testpypi",
      "displayName" : null,
      "oldRepoId" : "cn-north-7_5a775fdcb14f4431b6c0015618140bc3_pypi_40",
      "repoType" : "pypi"
    } ]
  }
}

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.