On this page

أنواع المشاريع ٢ — the categories a projects2 project is filed under (separate from Projects' types).

Two gates, two bodies (both 403): the community's page switch (settings.pageVisibility.projects2, off by default) → FEATURE_DISABLED; the plan lacks projects2 → FEATURE_NOT_AVAILABLE. Every route needs both.

Reads need no token; create/edit/delete need projects2:manage or projects2:moderate. A name is capped like any category name. A communityId in the body, if sent, must equal the path's (400 COMMUNITY_MISMATCH).

6 endpoints.

MethodPathSummary
GET/api/communities/{communityId}/projects2/typesList the community's projects2 types
POST/api/communities/{communityId}/projects2/typesCreate a type (managers)
DELETE/api/communities/{communityId}/projects2/types/{id}Delete a type (managers)
GET/api/communities/{communityId}/projects2/types/{id}One type
PUT/api/communities/{communityId}/projects2/types/{id}Rename or re-describe a type (managers)
GET/api/communities/{communityId}/projects2/types/project/{projectId}The types of one projects2 project

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—
qquerynostring—
pagequerynointeger—
pageSizequerynointeger—

Responses

StatusDescriptionBody
200{ success, data: ProjectType[], ...page }—

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—

Request body (required) — application/json

FieldTypeRequiredDescription
namestringyes—
descriptionstringno—

Responses

StatusDescriptionBody
201data is the ProjectType—
400Invalid name—

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—
idpathyesstring (uuid)—

Responses

StatusDescriptionBody
200Deleted—

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—
idpathyesstring (uuid)—

Responses

StatusDescriptionBody
200data is the ProjectType—
404Not found—

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—
idpathyesstring (uuid)—

Request body — application/json

FieldTypeRequiredDescription
namestringno—
descriptionstringno—

Responses

StatusDescriptionBody
200data is the ProjectType—

Auth: Bearer JWT required.

Parameters

NameInRequiredTypeDescription
communityIdpathyesstring (uuid)—
projectIdpathyesstring (uuid)—

Responses

StatusDescriptionBody
200data is ProjectType[]—