Setting a Repository to Public or Private
Function
This API is used to set a repository to public or private.
URI
PUT /v2/repositories/{repository_uuid}/template-status
Parameter | Mandatory | Type | Description |
|---|---|---|---|
repository_uuid | Yes | String | Repository ID. |
Request Parameters
Parameter | Mandatory | Type | Description |
|---|---|---|---|
X-Auth-Token | Yes | String | Explanation: User token. It can be obtained by calling the corresponding IAM API. The value of X-Subject-Token in the response header is the user token. Constraints: Mandatory Range: 1–100,000 characters. Default value: None |
Parameter | Mandatory | Type | Description |
|---|---|---|---|
template_type | Yes | String | Template type. |
code_title | No | String | Code template name. |
creator_name | No | String | Creator name. |
code_description | No | String | Code template description. |
languages | No | Array of strings | Template language. |
plateform | No | Array of strings | Template platform. |
entertype | No | Array of strings | Template type. |
Response Parameters
Status code: 200
Parameter | Type | Description |
|---|---|---|
error | Error object | Response error. |
result | String | Response result. |
status | String | Response status. |
Example Requests
PUT https://{endpoint}/v2/repositories/{repository_uuid}/template-status
{
"template_type": "SHARE",
"code_title": "exampleTitle",
"creator_name": "exampleName",
"code_description": "exampleDescription",
"languages": ['Java'],
"plateform": ['Console'],
"entertype": ['AI']
} Example Responses
Status code: 200
OK
{
"result" : null,
"error" : null,
"status" : "success"
} Status Codes
Status Code | Description |
|---|---|
200 | OK |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.

