Creating a Part in a Different Organization
Using this request, you can create a part where the part may inherit the owning organization of the parent or with the owning organization specified while creating the part.
To create a part using this request, set the Expose Organization preference to Yes in the Preference Management utility in Windchill.
|
In the Preference Management utility in Windchill, if the Expose Organization and Expose Organization Only for Windchill Supplier Management Parts preferences are set to Yes and the Expose Organization for Change Management Objects preference is set to No, only the supplier management parts can be created.
|
For additional endpoints used for creating a supplier part in a different organization, see the example topic,
Creating a Supplier Part in a Different Organization.
Example: Creating a Part in a Different Organization
This example shows you how to create a part in a different organization by providing the owning organization OID in the request body.
Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/ProdMgmt/Parts
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Name": "TestWTPart",
"@odata.type": "#PTC.ProdMgmt.Part",
"Organization@odata.bind": "Organizations('OR:wt.org.WTOrganization:118052')",
"EndItem": false,
"AssemblyMode": {
"Value": "separable",
"Display": "Separable"
},
"DefaultUnit": {
"Value": "ea"
},
"DefaultTraceCode": {
"Value": "0"
},
"Source": {
"Value": "make"
},
"GatheringPart": false,
"PhantomManufacturingPart": false,
"Context@odata.bind": "Containers('OR:wt.pdmlink.PDMLinkProduct:118301')"
}
The request creates the TestWTPart part in the specified organization.
Example: Creating a Manufacturer Part in a Different Organization
This example shows you how to create a manufacturer part in a different organization by providing the owning organization OID in the request body.
Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/ProdMgmt/Parts
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Name": "TestMfgPart",
"@odata.type": "#PTC.ProdMgmt.ManufacturerPart",
"Organization@odata.bind": "Organizations('OR:wt.org.WTOrganization:206773')",
"EndItem": false,
"ConfigurableModule": {
"Value": "standard",
"Display": "No"
},
"AssemblyMode": {
"Value": "separable"
},
"DefaultUnit": {
"Value": "ea"
},
"DefaultTraceCode": {
"Value": "L"
},
"GatheringPart": false,
"PhantomManufacturingPart": false,
"Source": {
"Value": "buy"
},
"Context@odata.bind": "Containers('OR:wt.pdmlink.PDMLinkProduct:118301')"
}
The request creates the TestMfgPart part in the specified organization.
Example: Creating a Vendor Part in a Different Organization
This example shows you how to create a vendor part in a different organization by providing the owning organization OID in the request body.
URI
POST /Windchill/servlet/odata/ProdMgmt/Parts
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Name": "TestVendorPart",
"@odata.type": "#PTC.ProdMgmt.VendorPart",
"Organization@odata.bind": "Organizations('OR:wt.org.WTOrganization:500152')",
"EndItem": false,
"ConfigurableModule": {
"Value": "standard",
"Display": "No"
},
"AssemblyMode": {
"Value": "separable"
},
"DefaultUnit": {
"Value": "ea"
},
"DefaultTraceCode": {
"Value": "L"
},
"GatheringPart": false,
"PhantomManufacturingPart": false,
"Source": {
"Value": "buy"
},
"Context@odata.bind": "Containers('OR:wt.pdmlink.PDMLinkProduct:118301')"
}
The request creates the TestVendorPart part in the specified organization.