Update Work Order
PATCHhttps://secure.fleetio.com/api/v2/work_orders/:work_order_id/work_order_line_items/:id
Update a Work Order
Request
Path Parameters
Possible values: Value must match regular expression ^[0-9]+$
The id of the associated Work Order
Possible values: Value must match regular expression ^[0-9]+$
The id of the relevant record
- application/json
Body
Possible values: [WorkOrderServiceTaskLineItem
, WorkOrderFreeTextLineItem
]
The Type of the item associated with the Work Order Line Item
Possible values: [Issue
, ServiceTask
]
The ID of the item associated with this Work Order Line Item.
The IDs of any Issues
associated with this Work Order Line Item.
The cost of labor of this line item.
The cost of Parts
of this line item.
The subtotal of this line item.
The ID of the VMRS Reason for Repair associated with this Work Order Line Item.
The ID of the VMRS System Group associated with this Work Order Line Item.
The ID of the VMRS System associated with this Work Order Line Item.
The ID of the VMRS Assembly associated with this Work Order Line Item.
The ID of the VMRS Component associated with this Work Order Line Item.
work_order_sub_line_items_attributes object[]
work_order_part_line_items_attributes object[]
work_order_labor_line_items_attributes object[]
Responses
- 204
- 401
- 403
- 404
- 422
- 500
OK
Request could not be authenticated
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Insufficient permission to perform this operation
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
The requested resource could not be located
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Unprocessable Entity
- application/json
- Schema
- Example (auto)
- Example
Schema
errors object
{
"errors": {}
}
{
"errors": {
"field1": [
"error1",
"error2"
],
"field2": [
"error3"
]
}
}
Something unexpected happened
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Authorization: Authorization
name: Authorizationtype: apiKeyin: headerdescription: Prefix the value with "Token", for example: "Token 76cbe06c49a64". You can generate a new API key [here](https://secure.fleetio.com/api_keys).
name: Account-Tokentype: apiKeyin: headerdescription: You can find your Account-Token [here](https://secure.fleetio.com/api_keys)
- curl
- ruby
- python
- csharp
- go
- java
- nodejs
- php
- CURL
curl -L -X PATCH 'https://secure.fleetio.com/api/v2/work_orders/:work_order_id/work_order_line_items/:id' \
-H 'Content-Type: application/json' \
-H 'Authorization: Token <Authorization>' \
-H 'Account-Token: <Authorization>' \
-d '{
"type": "WorkOrderServiceTaskLineItem",
"item_type": "Issue",
"item_id": 0,
"description": "string",
"issue_ids": [
0
],
"labor_cost": 0,
"parts_cost": 0,
"subtotal": 0,
"vmrs_reason_for_repair_id": 0,
"vmrs_system_group_id": 0,
"vmrs_system_id": 0,
"vmrs_assembly_id": 0,
"vmrs_component_id": 0,
"work_order_sub_line_items_attributes": [
{
"work_order_id": 0,
"item_id": 0,
"item_type": "Part",
"quantity": 0,
"unit_cost": 0,
"subtotal": 0,
"position": 0
}
],
"work_order_part_line_items_attributes": [
{
"work_order_id": 0,
"item_id": 0,
"item_type": "Part",
"quantity": 0,
"unit_cost": 0,
"subtotal": 0,
"position": 0
}
],
"work_order_labor_line_items_attributes": [
{
"work_order_id": 0,
"item_id": 0,
"item_type": "Contact",
"quantity": 0,
"unit_cost": 0,
"subtotal": 0,
"position": 0
}
]
}'