Retrieving Co-produce Data
You can retrieve the information for a single Co-produce object or a collection of Co-produce objects or their subtypes by specifying the Co-produce OIDs in the request body. You can retrieve information of specified Co-produces by expanding on relevant links.
Example: Retrieving Information for Multiple Co-produce Objects
This example shows you how to retrieve the information for two Co-produce objects specified in the request body. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/BomTransformation/GetCoproduceData
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Coproduces": [
{
"ID": "OR:wt.part.WTPart:203891"
},
{
"ID": "OR:wt.part.WTPart:204298"
}
]
}
Example: Retrieving Information for Multiple Co-produce Objects for a Specific Navigation Criteria
This example shows you how to retrieve the information for two Co-produce objects with Navigation Criteria specified in the request body. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/BomTransformation/GetCoproduceData
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Coproduces": [
{
"ID": "OR:wt.part.WTPart:203891"
},
{
"ID": "OR:wt.part.WTPart:204298"
}
],
"navigationCriteriaId": "OR:wt.filter.NavigationCriteria:203920"
}
URI with Expand
POST /Windchill/servlet/odata/BomTransformation/GetCoproduceData?$expand=PrimaryCoproduceLink($expand=Primary,AlternateSetMaster),SecondaryCoproduceLinks($expand=Secondary,AlternateSetMaster),CoProduceUsageLinks($expand=CoProduceUses),PrimaryPart($select=Identity),SecondaryMembers($select=Identity),CoProduceUsages($select=Identity)
Example: Retrieving Information for Multiple Co-produce Objects with Inline Navigation Criteria
This example shows you how to retrieve the information for two Co-produce objects with inline Navigation Criteria. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/BomTransformation/GetCoproduceDataWithInlineNavCriteria
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Coproduces": [
{
"ID": "OR:wt.part.WTPart:203891"
},
{
"ID": "OR:wt.part.WTPart:205842"
}
],
"NavigationCriteria": {
"ApplicableType": "PTC.ProdMgmt.Part",
"ApplicationName": null,
"ApplyToTopLevelObject": false,
"Centricity": false,
"ConfigSpecs": [
{
"@odata.type": "#PTC.NavCriteria.WTPartEffectivityDateConfigSpec",
"EffectiveDate": "2022-03-09T23:00:00Z",
"EffectiveContext": "wt.part.WTPartMaster:203145",
"View": "Design",
"Variation1": null,
"Variation2": null
}
],
"Filters": [],
"HideUnresolvedDependents": false,
"SharedToAll": true,
"UseDefaultForUnresolved": false
}
}
URI with Expand
POST /Windchill/servlet/odata/BomTransformation/GetCoproduceDataWithInlineNavCriteria?$expand=PrimaryCoproduceLink($expand=Primary,AlternateSetMaster),SecondaryCoproduceLinks($expand=Secondary,AlternateSetMaster),CoProduceUsageLinks($expand=CoProduceUses),PrimaryPart($select=Identity),SecondaryMembers($select=Identity),CoProduceUsages($select=Identity)
Was this helpful?