This method allows to create a failure in a simplified manner.
The method to be used when creating a failure is:
POST url/api/mytenant/myorganization/maintenancecore/failures
Json example for creating a failure:
{
"failureKey": "001",
"description": "fail 001",
"failureDate": "2021-08-09T11:21:13+01:00",
"causedEnvironmentalDamage": false,
"causedPersonalInjury": true,
"increasedRiskPersonalInjury": false,
"remarks": null,
"workOrder": "000001",
"assetType": 2,
"equipment": "ATC02",
"tool": null,
"failureTypifications": [
{
"failureSymptom": "S01",
"failureCause": "C01",
"failureAction": "A01"
}
],
"company": "DEMO"
}This method allows to create a failure according to the parameters filled in:
- failureKey: The key of the failure. Mandatory field.
- description: Short description of the failure. Mandatory field.
- failureDate: Failure date.
- causedEnvironmentalDamage: "caused environmental damage?" Fill in this field with true or false.
- causedPersonalInjury: "caused personal injury?" Fill in this field with true or false.
- increasedRiskPersonalInjury: "increased risk of personal injury?" Fill in this field with true or false.
- remarks: Remarks.
- WorkOrder: The key of the work order the failure will be associated to. Mandatory field.
- AssetType: The asset type (2- equipment; 3- tool). It is only possible to associate to a failure, an asset of type 2 or 3. Mandatory field.
- equipment: The equipment key.
- tool: The tool's key.
- failureTypifications: In these parameters, we can associate the failure symptoms, causes and actions, placing in each parameter the corresponding key.
- company: The company's key. Mandatory field.
When this method is executed successfully, it returns HttpStatusCode.201Created.