Help Center> CodeArts Deploy> API Reference> APIs> Managing Host Cluster Permissions> Checking Whether the Current User Has Permissions to Create a Host Cluster in a Project
Updated on 2024-07-05 GMT+08:00

Checking Whether the Current User Has Permissions to Create a Host Cluster in a Project

Function

This API is used to check whether the current user has permissions to create a host cluster in a project.

Calling Method

For details, see Calling APIs.

URI

GET /v1/host-groups/creatable/{project_id}/permissions

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID

Minimum: 32

Maximum: 32

Request Parameters

None

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

can_created

Boolean

Whether you have permissions to create a host cluster. true: Authorized. false: Not authorized.

Example Requests

https://{endpoint}/v1/host-groups/creatable/7e6caf3cd9a64d5b8ea451e38221892e/permissions

Example Responses

Status code: 200

OK: The request is successful.

{
  "can_created" : true
}

Status Codes

Status Code

Description

200

OK: The request is successful.

Error Codes

See Error Codes.