API: Project Phase Definitions
Project phases separate the whole of the project’s duration into smaller, distinct parts. Such a phase will then have different focus on certain aspects of project management. E.g. while the first phase might be about gathering requirements, the second phase might be about implementing the requirements and the third phase might be about testing the implementation.
The phases within the projects rely on an abstract definition of the project life cycle valid in a number of projects within the OpenProject instance. That definition is a set of ProjectPhaseDefinitions.
Actions
- None currently
Linked Properties
Link | Description | Type | Constraints | Supported operations | Condition |
---|---|---|---|---|---|
self | This project phase definition | ProjectPhaseDefinition | not null | READ |
Local Properties
Property | Description | Type | Constraints | Supported operations |
---|---|---|---|---|
id | Project phase definition’s id | Integer | x > 0 | READ |
name | String | READ | ||
startGate | Indicates whether the project phase has a gate at the start | Boolean | READ | |
startGateName | The name of the gate at the start of the phase | String | READ | |
finishGate | Indicates whether the project phase has a gate at the end | Boolean | READ | |
finishGateName | The name of the gate at the end of the phase | String | READ | |
createdAt | Time of creation | DateTime | READ | |
updatedAt | Time of the most recent change to the project phase | DateTime | READ |
Methods
Get a project phase definition
Gets a project phase definition resource. This resource is part of the abstract definition of a project life cycle shaping the phases of a project.
id
integer
required path
Project phase definition id
Example:1337
200
OK
ProjectPhaseDefinitionModel
{
"type": "object",
"required": [
"_type",
"id",
"name",
"startGate",
"finishGate",
"createdAt",
"updatedAt"
],
"properties": {
"_type": {
"type": "string",
"enum": [
"ProjectPhaseDefinition"
]
},
"id": {
"type": "integer",
"description": "The project phase definition's id",
"minimum": 1
},
"name": {
"type": "string"
},
"startGate": {
"type": "boolean"
},
"startGateName": {
"type": "string"
},
"finishGate": {
"type": "boolean"
},
"finishGateName": {
"type": "string"
},
"createdAt": {
"type": "string",
"format": "date-time",
"description": "Time of creation"
},
"updatedAt": {
"type": "string",
"format": "date-time",
"description": "Time of the most recent change to the project phase definition"
},
"_links": {
"type": "object",
"required": [
"self"
],
"properties": {
"self": {
"allOf": [
{
"$ref": "#/components/schemas/Link"
},
{
"description": "This project phase definition.\n\n**Resource**: ProjectPhaseDefinition"
}
]
}
}
}
},
"example": {
"_type": "ProjectPhaseDefinition",
"id": 1337,
"title": "Initiating",
"startGate": true,
"startGateName": "Before Initiating",
"finishGate": true,
"finishGateName": null,
"createdAt": "2023-01-20T14:30:00.368Z",
"updatedAt": "2023-05-23T11:57:48.618Z",
"_links": {
"self": {
"href": "/api/v3/project_phase_definitions/23"
}
}
}
}
404
Returned if the user does not have permission to see project phases.
Required permission: view project phase OR select project phase
{
"_type": "Error",
"errorIdentifier": "urn:openproject-org:api:v3:errors:MissingPermission",
"message": "You are not authorized to access this resource."
}
ErrorResponse
{
"type": "object",
"required": [
"_type",
"errorIdentifier",
"message"
],
"properties": {
"_embedded": {
"type": "object",
"properties": {
"details": {
"type": "object",
"properties": {
"attribute": {
"type": "string",
"example": "project"
}
}
}
}
},
"_type": {
"type": "string",
"enum": [
"Error"
]
},
"errorIdentifier": {
"type": "string",
"example": "urn:openproject-org:api:v3:errors:PropertyConstraintViolation"
},
"message": {
"type": "string",
"example": "Project can't be blank."
}
}
}