# system.kanoa.cmms.updateProcedureStep(procedureStepInfo, userId)

Updates an existing procedure step definition, such as a step's name, description, sort order, or estimated duration. 
Call this when editing a maintenance procedure template in the procedure builder UI � for example, after a technician or planner reorders steps, adjusts the estimated time, or toggles whether a step is required or enabled. 
All keys in `procedureStepInfo` are required; the function overwrites the identified step's fields with the values supplied and records `userId` against the change for audit purposes.

---
### Parameters
**procedureStepInfo** `Dictionary`<br />
<table class='dictionaryKeyTable'>
	<tbody>
 	<tr><td> - enabled</td><td>Boolean</td><td></td></tr>	
 	<tr><td> - estimatedMinutes</td><td>Integer</td><td></td></tr>	
 	<tr><td> - procedureId</td><td>Integer</td><td>Id of procedure</td></tr>	
 	<tr><td> - procedureStepId</td><td>Integer</td><td>Id of procedure step</td></tr>	
 	<tr><td> - required</td><td>Boolean</td><td></td></tr>	
 	<tr><td> - sortOrder</td><td>Integer</td><td></td></tr>	
 	<tr><td> - stepConfig</td><td>String</td><td></td></tr>	
 	<tr><td> - stepDescription</td><td>String</td><td></td></tr>	
 	<tr><td> - stepName</td><td>String</td><td></td></tr>	
	</tbody>
</table>

**userId** `Integer`:Id of the user executing the function<br />

---
### Returns
**# of records modified** `Integer`<br />
**message** `String` None if success<br />

---
### Example
```python
procedureStepInfo = {
						"procedureStepId": 4021,
						"procedureId": 310,
						"stepName": "Inspect belt tension",
						"stepDescription": "Check drive belt deflection against spec and adjust tensioner if outside tolerance.",
						"stepConfig": "",
						"sortOrder": 3,
						"estimatedMinutes": 15,
						"required": True,
						"enabled": True
					}
userId = system.kanoa.security.getIDPUserId({'userName': 'SYSTEM'})
result, message = system.kanoa.cmms.updateProcedureStep(procedureStepInfo, userId)
print result, message
```
