Here’s the complete solution for asset status transitions via the maintenance API:
Asset Status Transition Requirements:
Workday’s maintenance module uses a state machine for asset status. Each transition has specific prerequisites that must be met before the status can change. The ‘In Progress’ to ‘Completed’ transition requires:
- Associated work order must be in ‘Closed’ status
- All required work order fields must be populated (labor hours, parts, completion notes)
- Asset must have no pending maintenance tasks
- Completion date must be within valid range (not future, not before start date)
The API documentation doesn’t clearly explain these dependencies because they’re enforced at the workflow level, not the API level. This is why you get 200 OK but no status change - the API accepts your request, but the workflow engine rejects it.
Mandatory PATCH Fields for Status Completion:
Your current PATCH payload is missing critical fields:
PATCH /maintenance/assets/A-00123
{
"status": "Completed",
"completion_date": "2024-11-18",
"work_order_ref": "WO-2024-5678",
"actual_labor_hours": 3.5,
"completion_notes": "Replaced pump assembly",
"close_code": "REPAIRED"
}
The work_order_ref links the asset update to the corresponding work order. Without this, Workday can’t validate that the work order is properly closed. The actual_labor_hours and close_code are required for maintenance metrics and reporting - the workflow won’t allow completion without them.
Maintenance Workflow Automation Solution:
For automated maintenance processes, implement a two-step update sequence:
Step 1 - Close the work order:
PATCH /maintenance/work-orders/WO-2024-5678
{
"status": "Closed",
"actual_hours": 3.5,
"parts_used": [{"part_id": "P-123", "quantity": 1}],
"completion_notes": "Replaced pump assembly",
"close_code": "REPAIRED",
"closed_date": "2024-11-18"
}
Step 2 - Update asset status (include work order reference):
PATCH /maintenance/assets/A-00123
{
"status": "Completed",
"completion_date": "2024-11-18",
"work_order_ref": "WO-2024-5678",
"actual_labor_hours": 3.5,
"completion_notes": "Replaced pump assembly",
"close_code": "REPAIRED"
}
Critical: You must wait 2-3 seconds between Step 1 and Step 2 to allow the work order status to propagate through Workday’s workflow engine. If you update the asset too quickly, the work order validation will fail.
For workflow completion tracking, implement verification polling:
GET /maintenance/assets/A-00123?fields=status,work_order_status
Poll every 5 seconds for up to 30 seconds after the PATCH. If status hasn’t changed to ‘Completed’ after 30 seconds, there’s likely a validation error. Check the work order status - if it’s not ‘Closed’, that’s your blocker.
Common validation failures:
- Work order still ‘In Progress’ (close it first)
- Missing required parts list (even if no parts used, pass empty array)
- Invalid close code (must match configured values in tenant)
- Completion date before work order start date
- User lacks ‘Complete Maintenance Work Orders’ permission
The UI works because it enforces these requirements through the form validation before submission. The API allows you to send incomplete data, but the backend workflow rejects it silently. Always include all required fields in your PATCH request to ensure successful status transitions.