How can we help?
{{docApp.searchError}}
{{product.name}}
Searching in {{docApp.searchFilterBySpecificBookTitle}}
{{docApp.searchResultFilteredItems.length}} results for: {{docApp.currentResultsSearchText}}
in {{docApp.searchFilterBySpecificBookTitle}}
Search results have been limited. There are a total of {{docApp.searchResponse.totalResultsAvailable}} matches.
You have an odd number of " characters in your search terms - each one needs closing with a matching " character!
-
{{resultItem.title}}
{{resultItem.url}}
{{docApp.libraryHomeViewProduct.title || docApp.libraryHomeViewProduct.id}}
{{docApp.libraryHomeViewProduct.description}}
{{group.title || group.id}}
{{group.description}}
Operation Information
- Application Reference:
com.hornbill.projectmanager
- Scope:
Entity - Projects
- Class:
Entity
- Required Privilege Level:
user
- Required Rights: Group E - canUpdateProjects
Description
This flowcode operation updates an existing project.
Request Parameters
The updateProject API takes the following input parameters. It is important to note that the parameters must satisfy the requirement of the input validation checks.
Name | Type | Required | Description |
---|---|---|---|
projectId |
xs:integer |
Yes | The project id. |
name |
xs:string |
No | The name of the project. |
description |
xs:string |
No | A description of the project. |
projectScope |
xs:string |
No | The project's scope |
projectTypeId |
xs:integer |
No | The primary key of the project type. |
qualityStatement |
xs:string |
No | The project's quality statement. |
scheduledStartDate |
xs:dateTime |
No | The project's scheduled start date. If set to '1970-01-01 00:00:00', the column will be nulled in the database. |
scheduledEndDate |
xs:dateTime |
No | The project's scheduled end date. If set to '1970-01-01 00:00:00', the column will be nulled in the database. |
startDate |
xs:dateTime |
No | The project start date. If set to '1970-01-01 00:00:00', the column will be nulled in the database. |
endDate |
xs:dateTime |
No | The project end date. If set to '1970-01-01 00:00:00', the column will be nulled in the database. |
status |
xs:string |
Yes | The status of the project. Accepted values are (status.draft, status.active). |
subStatus |
xs:string |
No | The Project Sub Status value taken from the simple list. e.g. 'subStatus.pipeline' |
budgetCurrency |
xs:string |
No | The currency of the project's budget. |
budget |
xs:decimal |
No | The project's budget. |
businessBenefits |
xs:string |
No | Business benefits of the project. |
lessonsLearnt |
xs:string |
No | Lessons learnt during the project. |
reasons |
xs:string |
No | Reasons for doing the project. |
customA1 |
xs:string |
No | Custom Field A1 (varchar). |
customA2 |
xs:string |
No | Custom Field A2 (varchar). |
customA3 |
xs:string |
No | Custom Field A3 (varchar). |
customA4 |
xs:string |
No | Custom Field A4 (varchar). |
customA5 |
xs:string |
No | Custom Field A5 (varchar). |
customB1 |
xs:string |
No | Custom Field B1 (text). |
customB2 |
xs:string |
No | Custom Field B2 (text). |
customB3 |
xs:string |
No | Custom Field B3 (text). |
customB4 |
xs:string |
No | Custom Field B4 (text). |
customB5 |
xs:string |
No | Custom Field B5 (text). |
customC1 |
xs:dateTime |
No | Custom Field C1 (datetime). |
customC2 |
xs:dateTime |
No | Custom Field C2 (datetime). |
customC3 |
xs:dateTime |
No | Custom Field C3 (datetime). |
customC4 |
xs:dateTime |
No | Custom Field C4 (datetime). |
customC5 |
xs:dateTime |
No | Custom Field C5 (datetime). |
customD1 |
xs:integer |
No | Custom Field D1 (integer). |
customD2 |
xs:integer |
No | Custom Field D2 (integer). |
customD3 |
xs:integer |
No | Custom Field D3 (integer). |
customD4 |
xs:integer |
No | Custom Field D4 (integer). |
customD5 |
xs:integer |
No | Custom Field D5 (integer). |
progress |
xs:integer |
No | The project's progress. |
ragStatus |
xs:string |
No | The project's rag status. E.g. status.green |
projectManagerComments |
xs:string |
No | The project's latest pm comments. |
Response Parameters
Name | Type | Description |
---|---|---|
outcome |
xs:string |
The outcome of the flowcode operation. |
projectDetails |
xs:string |
A JSON string of updated project details. |
Code Examples
curl -X POST 'https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects' \
-H 'Authorization: ESP-APIKEY yourHornbillAPIKey' \
-H 'Content-Type: application/json' \
-d '{"@service":"apps/com.hornbill.projectmanager/Projects","@method":"updateProject","params":{"projectId":1,"name":"xs:string","description":"xs:string","projectScope":"xs:string","projectTypeId":1,"qualityStatement":"xs:string","scheduledStartDate":"xs:dateTime","scheduledEndDate":"xs:dateTime","startDate":"xs:dateTime","endDate":"xs:dateTime","status":"xs:string","subStatus":"xs:string","budgetCurrency":"xs:string","budget":1.23,"businessBenefits":"xs:string","lessonsLearnt":"xs:string","reasons":"xs:string","customA1":"xs:string","customA2":"xs:string","customA3":"xs:string","customA4":"xs:string","customA5":"xs:string","customB1":"xs:string","customB2":"xs:string","customB3":"xs:string","customB4":"xs:string","customB5":"xs:string","customC1":"xs:dateTime","customC2":"xs:dateTime","customC3":"xs:dateTime","customC4":"xs:dateTime","customC5":"xs:dateTime","customD1":1,"customD2":1,"customD3":1,"customD4":1,"customD5":1,"progress":1,"ragStatus":"xs:string","projectManagerComments":"xs:string"}}'
package main
import (
"fmt"
apiLib "github.com/hornbill/goApiLib"
)
func main() {
hornbillAPI := apiLib.NewXmlmcInstance("yourinstanceid")
hornbillAPI.SetAPIKey("yourHornbillAPIKey")
hornbillAPI.SetJSONResponse(true)
hornbillAPI.SetParam("projectId", "xs:integer")
hornbillAPI.SetParam("name", "xs:string")
hornbillAPI.SetParam("description", "xs:string")
hornbillAPI.SetParam("projectScope", "xs:string")
hornbillAPI.SetParam("projectTypeId", "xs:integer")
hornbillAPI.SetParam("qualityStatement", "xs:string")
hornbillAPI.SetParam("scheduledStartDate", "xs:dateTime")
hornbillAPI.SetParam("scheduledEndDate", "xs:dateTime")
hornbillAPI.SetParam("startDate", "xs:dateTime")
hornbillAPI.SetParam("endDate", "xs:dateTime")
hornbillAPI.SetParam("status", "xs:string")
hornbillAPI.SetParam("subStatus", "xs:string")
hornbillAPI.SetParam("budgetCurrency", "xs:string")
hornbillAPI.SetParam("budget", "xs:decimal")
hornbillAPI.SetParam("businessBenefits", "xs:string")
hornbillAPI.SetParam("lessonsLearnt", "xs:string")
hornbillAPI.SetParam("reasons", "xs:string")
hornbillAPI.SetParam("customA1", "xs:string")
hornbillAPI.SetParam("customA2", "xs:string")
hornbillAPI.SetParam("customA3", "xs:string")
hornbillAPI.SetParam("customA4", "xs:string")
hornbillAPI.SetParam("customA5", "xs:string")
hornbillAPI.SetParam("customB1", "xs:string")
hornbillAPI.SetParam("customB2", "xs:string")
hornbillAPI.SetParam("customB3", "xs:string")
hornbillAPI.SetParam("customB4", "xs:string")
hornbillAPI.SetParam("customB5", "xs:string")
hornbillAPI.SetParam("customC1", "xs:dateTime")
hornbillAPI.SetParam("customC2", "xs:dateTime")
hornbillAPI.SetParam("customC3", "xs:dateTime")
hornbillAPI.SetParam("customC4", "xs:dateTime")
hornbillAPI.SetParam("customC5", "xs:dateTime")
hornbillAPI.SetParam("customD1", "xs:integer")
hornbillAPI.SetParam("customD2", "xs:integer")
hornbillAPI.SetParam("customD3", "xs:integer")
hornbillAPI.SetParam("customD4", "xs:integer")
hornbillAPI.SetParam("customD5", "xs:integer")
hornbillAPI.SetParam("progress", "xs:integer")
hornbillAPI.SetParam("ragStatus", "xs:string")
hornbillAPI.SetParam("projectManagerComments", "xs:string")
responseBody, apiError := hornbillAPI.Invoke("apps/com.hornbill.projectmanager/Projects", "updateProject")
if apiError != nil {
fmt.Println(apiError)
return
}
fmt.Println(responseBody)
}
const endpoint = "https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects";
const payload = {
"@service": "apps/com.hornbill.projectmanager/Projects",
"@method": "updateProject",
"params": {
"projectId": 1,
"name": "xs:string",
"description": "xs:string",
"projectScope": "xs:string",
"projectTypeId": 1,
"qualityStatement": "xs:string",
"scheduledStartDate": "xs:dateTime",
"scheduledEndDate": "xs:dateTime",
"startDate": "xs:dateTime",
"endDate": "xs:dateTime",
"status": "xs:string",
"subStatus": "xs:string",
"budgetCurrency": "xs:string",
"budget": 1.23,
"businessBenefits": "xs:string",
"lessonsLearnt": "xs:string",
"reasons": "xs:string",
"customA1": "xs:string",
"customA2": "xs:string",
"customA3": "xs:string",
"customA4": "xs:string",
"customA5": "xs:string",
"customB1": "xs:string",
"customB2": "xs:string",
"customB3": "xs:string",
"customB4": "xs:string",
"customB5": "xs:string",
"customC1": "xs:dateTime",
"customC2": "xs:dateTime",
"customC3": "xs:dateTime",
"customC4": "xs:dateTime",
"customC5": "xs:dateTime",
"customD1": 1,
"customD2": 1,
"customD3": 1,
"customD4": 1,
"customD5": 1,
"progress": 1,
"ragStatus": "xs:string",
"projectManagerComments": "xs:string"
}
};
fetch(endpoint, {
method: 'POST',
headers: {
"Authorization": "ESP-APIKEY yourHornbillAPIKey"
},
body: JSON.stringify(payload)
}).then(res => res.json())
.then(res => console.log(res));
const axios = require('axios');
const endpoint = "https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects";
const payload = {
"@service": "apps/com.hornbill.projectmanager/Projects",
"@method": "updateProject",
"params": {
"projectId": 1,
"name": "xs:string",
"description": "xs:string",
"projectScope": "xs:string",
"projectTypeId": 1,
"qualityStatement": "xs:string",
"scheduledStartDate": "xs:dateTime",
"scheduledEndDate": "xs:dateTime",
"startDate": "xs:dateTime",
"endDate": "xs:dateTime",
"status": "xs:string",
"subStatus": "xs:string",
"budgetCurrency": "xs:string",
"budget": 1.23,
"businessBenefits": "xs:string",
"lessonsLearnt": "xs:string",
"reasons": "xs:string",
"customA1": "xs:string",
"customA2": "xs:string",
"customA3": "xs:string",
"customA4": "xs:string",
"customA5": "xs:string",
"customB1": "xs:string",
"customB2": "xs:string",
"customB3": "xs:string",
"customB4": "xs:string",
"customB5": "xs:string",
"customC1": "xs:dateTime",
"customC2": "xs:dateTime",
"customC3": "xs:dateTime",
"customC4": "xs:dateTime",
"customC5": "xs:dateTime",
"customD1": 1,
"customD2": 1,
"customD3": 1,
"customD4": 1,
"customD5": 1,
"progress": 1,
"ragStatus": "xs:string",
"projectManagerComments": "xs:string"
}
};
const axiosConfig = {
headers: {
"Authorization": "ESP-APIKEY yourHornbillAPIKey"
}
};
axios.post(endpoint, payload, axiosConfig)
.then((res) => {
console.log("RESPONSE RECEIVED: ", res);
})
.catch((err) => {
console.log("AXIOS ERROR: ", err);
})
$endpoint = "https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects";
$payload = (object) [
'@service' => 'apps/com.hornbill.projectmanager/Projects',
'@method' => 'updateProject',
'params' => (object) [
'projectId' => 'xs:integer',
'name' => 'xs:string',
'description' => 'xs:string',
'projectScope' => 'xs:string',
'projectTypeId' => 'xs:integer',
'qualityStatement' => 'xs:string',
'scheduledStartDate' => 'xs:dateTime',
'scheduledEndDate' => 'xs:dateTime',
'startDate' => 'xs:dateTime',
'endDate' => 'xs:dateTime',
'status' => 'xs:string',
'subStatus' => 'xs:string',
'budgetCurrency' => 'xs:string',
'budget' => 'xs:decimal',
'businessBenefits' => 'xs:string',
'lessonsLearnt' => 'xs:string',
'reasons' => 'xs:string',
'customA1' => 'xs:string',
'customA2' => 'xs:string',
'customA3' => 'xs:string',
'customA4' => 'xs:string',
'customA5' => 'xs:string',
'customB1' => 'xs:string',
'customB2' => 'xs:string',
'customB3' => 'xs:string',
'customB4' => 'xs:string',
'customB5' => 'xs:string',
'customC1' => 'xs:dateTime',
'customC2' => 'xs:dateTime',
'customC3' => 'xs:dateTime',
'customC4' => 'xs:dateTime',
'customC5' => 'xs:dateTime',
'customD1' => 'xs:integer',
'customD2' => 'xs:integer',
'customD3' => 'xs:integer',
'customD4' => 'xs:integer',
'customD5' => 'xs:integer',
'progress' => 'xs:integer',
'ragStatus' => 'xs:string',
'projectManagerComments' => 'xs:string',
]
];
$headers = [
'Authorization: ESP-APIKEY yourHornbillAPIKey',
'Content-Type: application/json'
];
$curl = curl_init($url);
curl_setopt($curl, CURLOPT_URL, $endpoint);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($payload));
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
$resp = curl_exec($curl);
curl_close($curl);
echo $resp;
$Endpoint = "https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects"
$Body = @{
"@service" = "apps/com.hornbill.projectmanager/Projects"
"@method" = "updateProject"
params = @{
projectId = "xs:integer"
name = "xs:string"
description = "xs:string"
projectScope = "xs:string"
projectTypeId = "xs:integer"
qualityStatement = "xs:string"
scheduledStartDate = "xs:dateTime"
scheduledEndDate = "xs:dateTime"
startDate = "xs:dateTime"
endDate = "xs:dateTime"
status = "xs:string"
subStatus = "xs:string"
budgetCurrency = "xs:string"
budget = "xs:decimal"
businessBenefits = "xs:string"
lessonsLearnt = "xs:string"
reasons = "xs:string"
customA1 = "xs:string"
customA2 = "xs:string"
customA3 = "xs:string"
customA4 = "xs:string"
customA5 = "xs:string"
customB1 = "xs:string"
customB2 = "xs:string"
customB3 = "xs:string"
customB4 = "xs:string"
customB5 = "xs:string"
customC1 = "xs:dateTime"
customC2 = "xs:dateTime"
customC3 = "xs:dateTime"
customC4 = "xs:dateTime"
customC5 = "xs:dateTime"
customD1 = "xs:integer"
customD2 = "xs:integer"
customD3 = "xs:integer"
customD4 = "xs:integer"
customD5 = "xs:integer"
progress = "xs:integer"
ragStatus = "xs:string"
projectManagerComments = "xs:string"
}
}
$Header = @{
"Authorization" = "ESP-APIKEY yourHornbillAPIKey"
}
$Parameters = @{
Method = "POST"
Uri = $Endpoint
Headers = $Header
Body = ($Body | ConvertTo-Json)
ContentType = "application/json"
}
Invoke-RestMethod @Parameters
import requests
import json
endpoint = "https://api.hornbill.com/yourinstanceid/xmlmc/apps/com.hornbill.projectmanager/Projects"
headers = {
"Authorization": "ESP-APIKEY yourHornbillAPIKey"
}
payload={
"@service":"apps/com.hornbill.projectmanager/Projects",
"@method":"updateProject",
"params":{
"projectId":"xs:integer",
"name":"xs:string",
"description":"xs:string",
"projectScope":"xs:string",
"projectTypeId":"xs:integer",
"qualityStatement":"xs:string",
"scheduledStartDate":"xs:dateTime",
"scheduledEndDate":"xs:dateTime",
"startDate":"xs:dateTime",
"endDate":"xs:dateTime",
"status":"xs:string",
"subStatus":"xs:string",
"budgetCurrency":"xs:string",
"budget":"xs:decimal",
"businessBenefits":"xs:string",
"lessonsLearnt":"xs:string",
"reasons":"xs:string",
"customA1":"xs:string",
"customA2":"xs:string",
"customA3":"xs:string",
"customA4":"xs:string",
"customA5":"xs:string",
"customB1":"xs:string",
"customB2":"xs:string",
"customB3":"xs:string",
"customB4":"xs:string",
"customB5":"xs:string",
"customC1":"xs:dateTime",
"customC2":"xs:dateTime",
"customC3":"xs:dateTime",
"customC4":"xs:dateTime",
"customC5":"xs:dateTime",
"customD1":"xs:integer",
"customD2":"xs:integer",
"customD3":"xs:integer",
"customD4":"xs:integer",
"customD5":"xs:integer",
"progress":"xs:integer",
"ragStatus":"xs:string",
"projectManagerComments":"xs:string",
},
}
response = requests.request("POST", endpoint, json=payload, headers=headers)
print(response.text)
- Version {{docApp.book.version}}
- Node {{docApp.node}} / {{docApp.build}}
In This Document