To view existing custom fields in the system and to add new custom fields, use the Administration > Customization > User Defined Fields
Prior to using the Web Api to request a model with a CustomFieldValue property, you should set up your User Defined Custom Fields.
Then, you'll be able to successfully make a request to return the model with the populated CustomFieldValue JSON object in the response.
curl -X GET --header 'Accept: application/json' 'https://yourdomain.projectinsight.net/api/user/{Id}?modelProperties=CustomFieldValue'
curl -X GET --header 'Accept: application/json' 'https://yourdomain.projectinsight.net/api/user/{Id}?modelProperties=CustomFieldValue'
{
"CustomFieldValue": {
"EditedInline": false,
"CustomField1": "Bounty Hunter",
"CustomField2": "False",
"CustomField3": "",
"CustomField4": "False",
"CustomField5": "",
"CustomField6": "",
"CustomField7": "",
"CustomField8": "",
"CustomField9": "",
"CustomField10": "",
"CustomField11": "",
"CustomField12": "",
"CustomField13": "",
"CustomField14": "",
"CustomField15": "",
"CustomField16": "",
"CustomField17": "",
"CustomField18": "",
"CustomField19": "",
"CustomField20": "",
"CustomField21": "",
"CustomField22": "",
"CustomField23": "",
"CustomField24": "",
"CustomField25": "",
"CustomField26": "",
"CustomField27": "",
"CustomField28": "",
"CustomField29": "",
"CustomField30": "",
"CustomField31": "",
"CustomField32": "",
"CustomField33": "",
"CustomField34": "",
"CustomField35": "",
"CustomField36": "",
"CustomField37": "",
"CustomField38": "",
"CustomField39": "",
"CustomField40": "",
"CustomField41": "",
"CustomField42": "",
"CustomField43": "",
"CustomField44": "",
"CustomField45": "",
"CustomField46": "",
"CustomField47": "",
"CustomField48": "",
"CustomField49": "",
"CustomField50": "",
"CustomField51": "",
"CustomField52": "",
"CustomField53": "",
"CustomField54": "",
"CustomField55": "",
"CustomField56": "",
"CustomField57": "",
"CustomField58": "",
"CustomField59": "",
"CustomField60": "",
"CustomField61": "",
"CustomField62": "",
"CustomField63": "",
"CustomField64": "",
"CustomField65": "",
"CustomField66": "",
"CustomField67": "",
"CustomField68": "",
"CustomField69": "",
"CustomField70": "",
"CustomField71": "",
"CustomField72": "",
"CustomField73": "",
"CustomField74": "",
"CustomField75": "",
"CustomField76": "",
"CustomField77": "",
"CustomField78": "",
"CustomField79": "",
"CustomField80": "",
"Id": "f6a4883c-ab9d-4157-8968-8aada52d965c",
"IdExternal": null
},
"Id": "8e46ca6a-17b3-4506-93a0-064a6d7f88f0",
"IdExternal": null
}
You now can access and view the custom field values set for your objects. To validate the custom field value, look at the number appended to CustomFieldXX and reference it against the Field # column in your Custom Fields editor within Project Insight.
For more reading, you can also Retrieve Custom Field Items and Create a Custom Field Value object on an item using the REST API.
Comments
0 comments
Please sign in to leave a comment.