Types
Linked Properties
Link | Description | Type | Constraints | Supported operations |
---|---|---|---|---|
self | This type | Type | not null | READ |
Local Properties
Property | Description | Type | Constraints | Supported operations |
---|---|---|---|---|
id | Type id | Integer | x > 0 | READ |
name | Type name | String | READ | |
color | The color used to represent this type | Color | READ | |
position | Sort index of the type | Integer | READ | |
isDefault | Boolean | READ | ||
isMilestone | Do tickets of this type represent a milestone? | Boolean | READ | |
createdAt | Time of creation | DateTime | READ | |
updatedAt | Time of the most recent change to the user | DateTime | READ |
Types
List all Types
- Response
200
Toggle details Headers
Content-Type: application/hal+json
Body
{ "_links": { "self": { "href": "/api/v3/types" } }, "total": 2, "count": 2, "_type": "Collection", "_embedded": { "elements": [ { "_links": { "self": { "href": "/api/v3/types/1" } }, "_type": "Type", "id": 1, "name": "Bug", "color": "#ff0000", "position": 1, "isDefault": true, "isMilestone": false, "createdAt": "2014-05-21T08:51:20Z", "updatedAt": "2014-05-21T08:51:20Z" }, { "_links": { "self": { "href": "/api/v3/types/2" } }, "_type": "Type", "id": 2, "name": "Feature", "color": "#888", "position": 2, "isDefault": false, "isMilestone": false, "createdAt": "2014-05-21T08:51:20Z", "updatedAt": "2014-05-21T08:51:20Z" } ] } }
- Response
403
Toggle details Returned if the client does not have sufficient permissions.
Required permission: view work package or manage types (on any project)
Headers
Content-Type: application/hal+json
Body
{ "_type": "Error", "errorIdentifier": "urn:openproject-org:api:v3:errors:MissingPermission", "message": "You are not allowed to see the types." }
Types by Project
List types available in a project
This endpoint lists the types that are available in a given project.
- Parameters
- project_id
integer
(required) Example: 1ID of the project whoose types will be listed
- Response
200
Toggle details Headers
Content-Type: application/hal+json
Body
{ "_links": { "self": { "href": "/api/v3/projects/11/types" } }, "total": 2, "count": 2, "_type": "Collection", "_embedded": { "elements": [ { "_links": { "self": { "href": "/api/v3/types/1" } }, "_type": "Type", "id": 1, "name": "Bug", "color": "#ff0000", "position": 1, "isDefault": true, "isMilestone": false, "createdAt": "2014-05-21T08:51:20Z", "updatedAt": "2014-05-21T08:51:20Z" }, { "_links": { "self": { "href": "/api/v3/types/2" } }, "_type": "Type", "id": 2, "name": "Feature", "color": "#888", "position": 2, "isDefault": false, "isMilestone": false, "createdAt": "2014-05-21T08:51:20Z", "updatedAt": "2014-05-21T08:51:20Z" } ] } }
- 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 work packages or manage types (on given 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." }
Type
View Type
- Parameters
- id
integer
(required) Example: 1type id
- Response
200
Toggle details Headers
Content-Type: application/hal+json
Body
{ "_links": { "self": { "href": "/api/v3/types/1" } }, "_type": "Type", "id": 1, "name": "Bug", "color": "#ff0000", "position": 1, "isDefault": true, "isMilestone": false, "createdAt": "2014-05-21T08:51:20Z", "updatedAt": "2014-05-21T08:51:20Z" }
- Response
403
Toggle details Returned if the client does not have sufficient permissions.
Required permission: view work package or manage types (on any project)
Headers
Content-Type: application/hal+json
Body
{ "_type": "Error", "errorIdentifier": "urn:openproject-org:api:v3:errors:MissingPermission", "message": "You are not allowed to see this type." }
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