Windchill REST Services Domain Capabilities > Examples for Basic REST Operations > Examples for the PTC BOM Transformation Domain > Creating Multiple Department Data Objects for a Specific Plant Data Object assigned to a Specific Parts Object
Creating Multiple Department Data Objects for a Specific Plant Data Object assigned to a Specific Parts Object
Example: Creating Multiple Department Data Objects for a Specific Plant Data Object with Inline Navigation Criteria
This example shows you how to create multiple Department Data objects for a specific Plant Data object with inline Navigation Criteria. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/BomTransformation/CreateDepartmentData?$expand=DepartmentData
* 
You must apply $expand on DepartmentData, otherwise an empty list is returned.
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"parts": [
{
"ID": "OR:wt.part.WTPart:201394"
}
],
"departmentData": [
{
"@odata.type": "#PTC.BomTransformation.Logistics",
"SupplyChain": "005",
"Location": "005",
"Category": "quality"
},
{
"@odata.type": "#PTC.BomTransformation.Logistics",
"SupplyChain": "005",
"Location": "005",
"Category": "inventory"
}
],
"NavigationCriteria": {
"ApplicableType": "PTC.ProdMgmt.Part",
"ApplicationName": null,
"ApplyToTopLevelObject": false,
"Centricity": false,
"ConfigSpecs": [
{
"@odata.type": "#PTC.NavCriteria.PlantStandardConfigSpec",
"WorkingIncluded": false,
"View": "MMG",
"LifeCycleState": null
}
],
"CreatedOn": "2021-11-16T12:04:14+01:00",
"Filters": [],
"HideUnresolvedDependents": false,
"SharedToAll": false,
"UseDefaultForUnresolved": false
}
}
Example: Creating Multiple Department Data Objects for a Specific Plant Data Object with Navigation Criteria and Specified View
This example shows you how to create multiple Department Data objects for a specific Plant Data object with Navigation Criteria and Design View. Use the following POST URI with the request body
URI
POST /Windchill/servlet/odata/BomTransformation/CreateDepartmentData?$expand=DepartmentData
* 
You must apply $expand on DepartmentData, otherwise an empty list is returned.
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"parts": [
{
"ID": "OR:wt.part.WTPart:201394"
}
],
"departmentData": [
{
"@odata.type": "#PTC.BomTransformation.Logistics",
"SupplyChain": "005",
"Location": "005",
"Category": "Quality"
},
{
"@odata.type": "#PTC.BomTransformation.Logistics",
"SupplyChain": "005",
"Location": "005",
"Category": "Inventory"
}
],
"NavigationCriteria": {
"ID": "OR:wt.filter.NavigationCriteria:200537"
},
"view": "Design"
}