Categories
Linked Properties
Link | Description | Type | Constraints | Supported operations |
---|---|---|---|---|
self | This category | Category | not null | READ |
project | The project of this category | Project | not null | READ |
defaultAssignee | Default assignee for work packages of this category | User | READ |
Local Properties
Property | Description | Type | Constraints | Supported operations |
---|---|---|---|---|
id | Category id | Integer | x > 0 | READ |
name | Category name | String | READ |
Categories by Project
List categories of a project
- Parameters
- project_id
integer
(required) Example: 1ID of the project whoose categories will be listed
- Response
200
Toggle details Headers
Content-Type: application/hal+json
Body
{ "_links": { "self": { "href": "/api/v3/projects/11/categories" } }, "total": 2, "count": 2, "_type": "Collection", "_embedded": { "elements": [ { "_links": { "self": { "href": "/api/v3/categories/10", "title": "Category with assignee" }, "project": { "href": "/api/v3/projects/11", "title": "Example project" }, "defaultAssignee": { "href": "/api/v3/users/42", "title": "John Sheppard" } }, "_type": "Category", "id": 10, "name": "Foo" }, { "_links": { "self": { "href": "/api/v3/categories/11" }, "project": { "href": "/api/v3/projects/11" } }, "_type": "Category", "id": 11, "name": "Bar" } ] } }
- Response
404
Toggle details Returned if the project does not exist or the client does not have sufficient permissions to see it.
Required permission: view project
Note: A client without sufficient permissions shall not be able to test for the existence of a project. That’s why a 404 is returned here, even if a 403 might be more appropriate.
Headers
Content-Type: application/hal+json
Body
{ "_type": "Error", "errorIdentifier": "urn:openproject-org:api:v3:errors:NotFound", "message": "The specified project does not exist." }
Category
View Category
- Parameters
- id
integer
(required) Example: 1category id
- Response
200
Toggle details Headers
Content-Type: application/hal+json
Body
{ "_links": { "self": { "href": "/api/v3/categories/10", "title": "Category with assignee" }, "project": { "href": "/api/v3/projects/11", "title": "Example project" }, "defaultAssignee": { "href": "/api/v3/users/42", "title": "John Sheppard" } }, "_type": "Category", "id": 10, "name": "Foo" }
- Response
404
Toggle details Returned if the category does not exist or the client does not have sufficient permissions to see it.
Required permission: view project (defining the category)
Note: A client without sufficient permissions shall not be able to test for the existence of a category. That’s why a 404 is returned here, even if a 403 might be more appropriate.
Headers
Content-Type: application/hal+json
Body
{ "_type": "Error", "errorIdentifier": "urn:openproject-org:api:v3:errors:NotFound", "message": "The specified category does not exist." }
Help and feedback
If you did not find what you were looking for
If you need help from the community or want to support others
If you are eligible for professional support and have more questions
REQUEST SUPPORT
If you find an easily fixable error or need for improvement in the documentation for the stable release
If you would like to suggest bigger updates or improvements to this documentation
If you want to contribute to translate this documentation to another language
If there's something you don't like or understand about this feature
If you want to propose a new feature that OpenProject does not offer yet
To further help OpenProject to shape and test new features
To view OpenProject premium features and pricing
If you want to try all premium features in the OpenProject Cloud Edition 14 days for free
If you want to try all premium features in your on premise Community installation 14 days for free