ListRepositoryGroups

Updated at:

Retrieves a list of code groups with options for pagination, sorting by creation or update time, and keyword search.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request syntax

GET /repository/groups/get/all HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

organizationId

string

Yes

The organization ID. You can find this ID in your organization's URL on the Alibaba Cloud DevOps platform, for example: https://devops.aliyun.com/organization/{organizationId}.

60de7a6852743a5162b5f957

accessToken

string

No

The personal access token. This parameter is not required when you authenticate with an Alibaba Cloud access key (AK/SK) or Security Token Service (STS).

f0b1e61db5961df5975a93f9129d2513

parentId

integer

Yes

The ID of the parent namespace.

  • To list all groups in the organization, set this parameter to the namespace ID of the organization (not the organizationId).

  • To list all subgroups within a specific group, set this parameter to the namespace ID of that group.

26842

page

integer

No

The page number. The default is 1.

1

pageSize

integer

No

The page size. The value must be between 1 and 100. The default is 20.

10

search

string

No

The keyword to search for.

Demo

orderBy

string

No

The field to sort the results by. The default is updated_at.

  • updated_at: Sorts by update time.

  • created_at: Sorts by creation time.

updated_at

sort

string

No

The sort order. The default is desc.

  • desc: Descending

  • asc: Ascending

desc

includePersonal

boolean

No

Specifies whether to include personal private groups in the results.

false

Response elements

Element

Type

Description

Example

object

The response payload.

requestId

string

The request ID.

F7B85D1B-D1C2-140F-A039-341859F130B9

errorMessage

string

The error message.

”“

errorCode

string

The error code.

Openapi.RequestError

success

boolean

Indicates whether the request was successful.

true

total

integer

The total number of repository groups found.

100

result

array<object>

The list of repository groups.

object

A repository group object.

id

integer

The ID of the repository group. This ID is also the namespace ID.

19285

path

string

The path of the repository group.

test-codeup

name

string

The name of the repository group.

test-codeup

nameWithNamespace

string

The name of the repository group, prefixed with its parent path. The path and name are separated by a slash with surrounding spaces.

60de7a6852743a5162b5f957 / test-codeup(斜杠两侧有空格)

pathWithNamespace

string

The full path of the repository group, including the parent path.

60de7a6852743a5162b5f957/test-codeup

visibilityLevel

integer

The visibility level of the repository group.

  • 0: private

  • 10: internal

0

avatarUrl

string

The avatar URL for the repository group.

https://tcs-devops.aliyuncs.com/thumbnail/112afcb7a6a35c3f67f1bea827c4/w/100/h/100

webUrl

string

The web URL of the repository group.

""

type

string

The type of the object. For a repository group, the value is always Group.

Group

description

string

The description of the repository group.

描述信息的具体内容

parentId

integer

The ID of the parent path.

26842

ownerId

integer

The ID of the owner.

19230

accessLevel

integer

The access level. Valid values: 20 (Reporter), 30 (Developer), and 40 (Maintainer).

40

projectCount

integer

The number of repositories in the group.

10

groupCount

integer

The number of direct subgroups. This count is not recursive.

10

createdAt

string

The timestamp indicating when the repository group was created.

2022-03-18 14:24:54

updatedAt

string

The timestamp indicating when the repository group was last updated.

2022-03-18 14:24:54

Examples

Success response

JSON format

{
  "requestId": "F7B85D1B-D1C2-140F-A039-341859F130B9",
  "errorMessage": "”“",
  "errorCode": "Openapi.RequestError",
  "success": true,
  "total": 100,
  "result": [
    {
      "id": 19285,
      "path": "test-codeup",
      "name": "test-codeup",
      "nameWithNamespace": "60de7a6852743a5162b5f957 / test-codeup(斜杠两侧有空格)",
      "pathWithNamespace": "60de7a6852743a5162b5f957/test-codeup",
      "visibilityLevel": 0,
      "avatarUrl": "https://tcs-devops.aliyuncs.com/thumbnail/112afcb7a6a35c3f67f1bea827c4/w/100/h/100",
      "webUrl": "\"\"",
      "type": "Group",
      "description": "描述信息的具体内容",
      "parentId": 26842,
      "ownerId": 19230,
      "accessLevel": 40,
      "projectCount": 10,
      "groupCount": 10,
      "createdAt": "2022-03-18 14:24:54",
      "updatedAt": "2022-03-18 14:24:54"
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

403 Forbidden.AccessDenied The user is not authorized to perform the operation. The user is not authorized to perform the operation.
403 Forbidden.UserNotInCurrentOrganization The user is not in the organization and is not authorized to perform the operation.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.