Help Center/ Identity and Access Management/ API Reference/ API/ Enterprise Project Management/ Querying the Enterprise Projects Associated with a User Group
Updated on 2023-09-14 GMT+08:00

Querying the Enterprise Projects Associated with a User Group

Function

This API is used to query the enterprise projects associated with a user group.

The API can be called using both the global endpoint and region-specific endpoints.

URI

GET /v3.0/OS-PERMISSION/groups/{group_id}/enterprise-projects

Table 1 URI parameters

Parameter

Mandatory

Type

Description

group_id

Yes

String

User group ID.

Request Parameters

Table 2 Parameters in the request header

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Authenticated token with iam:permissions:listEnterpriseProjectsForGroup or Security Administrator permission. The domain_id of the account to which the group_id belongs must be the same as the domain_id in the token.

Response Parameters

Status code: 200

Table 3 Parameters in the response body

Parameter

Type

Description

enterprise-projects

Array of objects

Enterprise project information.

Table 4 ListEnterpriseProjectsResDetail

Parameter

Type

Description

projectId

String

Project ID.

Example Request

Request for querying enterprise projects associated with a user group

GET  https://iam.myhuaweicloud.eu/v3.0/OS-PERMISSION/groups/{group_id}/enterprise-projects

Example Response

Status code: 200

The request is successful.

{ 
  "enterprise-projects" : [ { 
    "projectId" : "dd87a1a8-8602-45a8-8145-393af4c95..." 
  } ] 
}

Status Codes

Status Code

Description

200

The request is successful.

400

Parameter error.

401

Authentication failed.

403

Access denied.

404

The requested resource cannot be found.

415

Incorrect Content-Type.

500

A system error occurred.

Error Codes

For details, see Error Codes.