Creating Maintenance Plan Using the REST API
You can create maintenance plans using REST API with the following details.
Endpoint URL: /services/apexrest/SVMXA360/mpln/v1/createMaintenancePlan/
Request JSON
The following is an example of the JSON input.
{
"subscriptionId":"TestDesc",
"subscriptionFieldName":"Description",
"startDate":"2021-11-29",
"sourceRecordId":"0012D00000ZpYH5QAN",
"sourceMaintenancePlan":null,
"sourceMaintenanceAssetList":null,
"operationType":null,
"maintenancePlanTitle":"Rest Maintenance Plan",
"maintenancePlanTemplateProductId":"a0j2D000003583oQAA",
"maintenancePlanTemplateId":null,
"maintenancePlanId":null,
"dateOfFirstWorkOrderInNextBatch":"2021-11-29"
}
Response JSON
The following is an example of the JSON response.
{
"success": true,
"message": "",
"data": {
"sourceRecordId": "",
"maintenancePlanTitle": "",
"startDate": "",
"dateOfFirstWorkOrderInNextBatch": "",
"maintenanceTemplateProductId": "",
"subscriptionId": "",
"subscriptionFieldName": "",
"maintenancePlanId": ""

},
"errors": []
}
Was this helpful?