Creating Multiple MPMStandardProcedureLinks
You can create single or multiple MPMStandardProcedureLink objects by specifying the OOTB attributes Lag and Insert Operation in the request body. To create an MPMStandardProcedureLink between an Operation Holder (Process Plan, Standard Procedure, Operation, or Sequence) or its subtype and a Standard Procedure or its subtype, you must first check out the Operation Holder object.
* 
To create an MPMStandardProcedureLink, you must specify only the latest version of the Standard Procedure object or its subtype.
Example: Creating Multiple MPMStandardProcedureLinks for a Specific Process Plan
This example shows you how to create two MPMStandardProcedureLinks for a Process Plan by specifying the Process Plan OID in the request URI. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/ProcessPlans('OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:352137')/PTC.MfgProcMgmt.CreateMPMStandardProcedureLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"StandardProcedureLink": [
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "1",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288042)"
},
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "2",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288052)"
}
]
}
Example: Creating Multiple MPMStandardProcedureLinks for a Specific Standard Procedure
This example shows you how to create two MPMStandardProcedureLinks for a Standard Procedure by specifying the Standard Procedure OID in the request URI. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/StandardProcedures('OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:352137')/PTC.MfgProcMgmt.CreateMPMStandardProcedureLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"StandardProcedureLink": [
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "1",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288042)"
},
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "2",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288052)"
}
]
}
Example: Creating Multiple MPMStandardProcedureLink for a Specific Operation
This example shows you how to create two MPMStandardProcedureLinks for an Operation by specifying the Operation OID in the request URI. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/Operations('OR:com.ptc.windchill.mpml.processplan.operation.MPMOperation:352181')/PTC.MfgProcMgmt.CreateMPMStandardProcedureLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"StandardProcedureLink": [
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "1",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288042)"
},
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "2",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288052)"
}
]
}
Example: Creating Multiple MPMStandardProcedureLinks for a Specific Sequence
This example shows you how to create two MPMStandardProcedureLinks for a Sequence by specifying the Sequence OID in the request URI. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/Sequences('OR:com.ptc.windchill.mpml.processplan.sequence.MPMSequence:352274')/PTC.MfgProcMgmt.CreateMPMStandardProcedureLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"StandardProcedureLink": [
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "1",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288042)"
},
{
"Lag": [
{
"Precision": 1,
"Unit": "kg",
"Value": 1,
"Display": "lag"
}
],
"InsertionOperation": "2",
"ProcessPlan@odata.bind": "StandardProcedures(OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:288052)"
}
]
}
Was this helpful?