Chuyển tới nội dung chính

Unarchive category

POST/api/categories/{categoryId}/unarchive
Quản trị viên

Đọc thêm: CategoryMã nguồn: CategoryApiController#unarchive(mở trong thẻ mới)

Tham số đường dẫn​

TênKiểuBắt buộcGhi chú
categoryIdstring (uuid)Bắt buộc

Response​

Thành công: 200

TrườngKiểuBắt buộcGhi chú
idstring (uuid)Tùy chọn
codestringTùy chọn
displayNamestringTùy chọn
groupenum CategoryGroupTùy chọnFEATUREFIXPERFORMANCEDOCUMENTATIONMAINTENANCEOTHER
systemCategorybooleanTùy chọn
activebooleanTùy chọn
createdAtstring (date-time)Tùy chọn
updatedAtstring (date-time)Tùy chọn

Lỗi​

Trạng tháiMãÁp dụng cho
400validation_failedthiếu trường hoặc giá trị nằm ngoài khoảng cho phépMọi endpoint
400invalid_parametermột tham số trên đường dẫn hoặc query bị thiếu hoặc không chuyển đổi được, chẳng hạn một ID không phải UUIDMọi endpoint
401authentication_requiredchưa có phiên đăng nhậpMọi endpoint
403access_deniedendpoint dành cho quản trị viên, hoặc CSRF token thiếu hay đã cũMọi endpoint
404not_foundkhông có địa chỉ đóMọi endpoint
405method_not_allowedđịa chỉ không nhận phương thức đóMọi endpoint
415unsupported_media_typeđịa chỉ không đọc body thuộc kiểu đóMọi endpoint
500internal_errormột lỗi ReleaseFlow không lường trước; body không bao giờ chứa exception gây ra nóMọi endpoint
400invalid_change_filterKhu vực Changes
400invalid_change_reviewKhu vực Changes
400invalid_sensitive_pathsKhu vực Changes
404change_not_foundKhu vực Changes
404duplicate_candidate_not_foundKhu vực Changes
409change_processingKhu vực Changes
409change_not_eligible_for_aiKhu vực Changes
409duplicate_candidate_decidedKhu vực Changes
409change_excludedKhu vực Changes
409change_in_releaseKhu vực Changes
502ai_classification_failedKhu vực Changes
503ai_classification_unavailableKhu vực Changes
404category_not_foundKhu vực Categories
404category_suggestion_not_foundKhu vực Categories
409category_code_takenKhu vực Categories
409category_systemKhu vực Categories
409category_suggestion_decidedKhu vực Categories

Request

bash
# Sign in first and keep the session cookie in cookies.txt (see Sessions and CSRF).
# CSRF_HEADER and CSRF_TOKEN are the headerName and token GET /api/csrf returned.
curl -X POST "http://localhost:8080/api/categories/$CATEGORY_ID/unarchive" \
-b cookies.txt -c cookies.txt \
-H "$CSRF_HEADER: $CSRF_TOKEN"

Response

200

Ví dụ

{
  "id": "<uuid>",
  "code": "<string>",
  "displayName": "<string>",
  "group": "FEATURE",
  "systemCategory": false,
  "active": false,
  "createdAt": "<date-time>",
  "updatedAt": "<date-time>"
}