edit a project.md
Edit a project
Management API · Projects
PATCH https://app.mk.io/api/v1/projects/{project_name}
Update project.
RBAC Capability Required: core.project.update
Authentication
Authorizationheader — Bearer authentication of the formBearer <token>.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
project_name |
string | Yes | — |
Request body
Content type: application/json
metadata· object · Optional — Metadata.displayName· string · Optional · 1-255 characters — New display name of the project.
spec· object · Optional — Specification.isActive· boolean · Optional — Is project active?isHidden· boolean · Optional — Is project hidden?
Example request
curl -X PATCH "https://app.mk.io/api/v1/projects/{project_name}" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"metadata": {
"displayName": "string"
},
"spec": {
"isActive": true,
"isHidden": true
}
}'
Responses
200 — OK
kind· string · Optional — The kind of record.metadata· object · Optional — Metadata.cloud· object · Required — Cloud in which the project is hosted.displayName· string · Required — The display name of the cloud.id· string · Optional · format: uuid — The unique identifier of the cloud.name· string · Required — The unique name of the cloud.
created· string · Optional · format: date-time — The time when the resource was createdcreatedBy· string · Optional · format: uuid — ID of the user who created the resourcecreatedByEmail· string · Optional — Email of the user who created the resourcecreatedById· string · Required · format: uuid — ID of the user who created the project.createdByName· string · Required — Name of the user who created the project.displayName· string · Optional — The display name of the resourceid· string · Required · format: uuid — The ID of the resourcename· string · Optional — The name of the resourceupdated· string · Optional · format: date-time — The time when the resource was last updated
spec· object · Required — Specification.assignedPaymentMethodId· string or null · Required · format: uuid — ID of the payment method assigned to the project.displayName· string · Required — Display name of the project.isActive· boolean · Required — Is project active.locationDisplayName· string · Optional — Display name of the location the project is in.locationId· string · Required · format: uuid — ID of the location the project is in.locationName· string · Required — Name of the location the project is in.name· string · Required — Name of the project.
Example:
{
"kind": "string",
"metadata": {
"cloud": {
"displayName": "Azure",
"id": "00000000-0000-0000-0000-000000000000",
"name": "azure"
},
"created": "2024-01-01T00:00:00Z",
"createdBy": "00000000-0000-0000-0000-000000000000",
"createdByEmail": "string",
"createdById": "00000000-0000-0000-0000-000000000000",
"createdByName": "string",
"displayName": "string",
"id": "00000000-0000-0000-0000-000000000000",
"name": "string",
"updated": "2024-01-01T00:00:00Z"
},
"spec": {
"assignedPaymentMethodId": "00000000-0000-0000-0000-000000000000",
"displayName": "string",
"isActive": true,
"locationDisplayName": "string",
"locationId": "00000000-0000-0000-0000-000000000000",
"locationName": "string",
"name": "string"
}
}
400 — Bad Request
error· object · Required — Pertinent information about the errorcode· string · Required — The error code.detail· string · Required — The error message.extraDetail· map from strings to any · Optional — Extra information regarding this error.[any key]· any — map of additional properties
ref· string · Required — A reference to the request that caused the error.status· integer · Required — The HTTP status code
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}
401 — Unauthorized
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}
403 — Forbidden
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}
404 — Not Found
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}
429 — Too Many Requests
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}
500 — Internal Server Error
Example:
{
"error": {
"code": "string",
"detail": "string",
"extraDetail": {
"key": null
}
},
"ref": "string",
"status": 0
}