Returns the used items declared on a work order, sorted by lastUpdate ascending.
Rules
- Items are returned only for work orders in status SYNCHRONIZED or above, else the list is empty.
- Booked and ordered items are not returned.
Pair with the workorder.validation webhook to fetch the used items once the work order is validated.
Rate limit range : High
Query parameters
-
The continuation token which was received in the previous request. It contains information on the page to fetch. If not present, then the first page of results will be returned.
-
Maximum number of items returned per page. Hard limit 200.
Minimum value is
1, maximum value is200. Default value is200. -
Filter items by billing ownership. Omit it to get every item. Any other value is refused.
external- catalog item flagged for invoicing, or on-the-fly item (no catalog article).internal- catalog item not flagged for invoicing.
Values are
externalorinternal.
Responses
-
OK - Paginated list of used items on the work order.
-
Bad Request - invalid
invoiceMode, invalidsizeor invalid continuation token. -
Unauthorized - authentication issue.
-
Forbidden - not enough rights.
-
Not Found - Work order not found or outside caller's org unit.
-
Too Many Requests.
-
Internal server error.
curl \
--request GET 'https://ws-eu1.praxedo.com/eTech/rest/ws/fieldService/v1/workOrders/uuid:550e8400-e29b-41d4-a716-446655440000/usedItems' \
--header "Authorization: Bearer $ACCESS_TOKEN"
{
"continuationToken": "eyJsYXN0VXBkYXRlIjoiMjAyNC0xMC0xNVQxNjowNTowMFoifQ==",
"data": [
{
"lineItemId": "80ae5498-6d98-45d0-be83-11748b49692a",
"itemCode": "PUMP-V3",
"reference": "182DGH32",
"name": "Pompe elec motron v3",
"agentCode": "T_SMITH_04",
"associatedSectionCode": "REPLACEMENT_SECTION",
"invoiceMode": "INTERNAL",
"expectedQuantity": 1,
"quantity": 2,
"dimension": "2*1.5",
"priceDetails": {
"unitPrice": 59,
"vatRate": 0.2
},
"tracking": {
"serialNumber": "SN-9982-XP",
"storeCode": null
},
"lastUpdate": "2024-10-15 16:05:00 UTC"
}
]
}
{
"continuationToken": null,
"data": [
{
"lineItemId": "ffffffff-0000-0000-0000-000000000001",
"itemCode": "JOINT-50MM",
"reference": null,
"name": "Joint caoutchouc 50mm",
"agentCode": "T_MARTIN_07",
"associatedSectionCode": null,
"invoiceMode": "EXTERNAL",
"expectedQuantity": null,
"quantity": 3,
"dimension": null,
"priceDetails": {
"unitPrice": 4.5,
"vatRate": null
},
"tracking": {
"serialNumber": null,
"storeCode": "STORE-PARIS-03"
},
"lastUpdate": "2024-10-14 09:10:00 UTC"
}
]
}
{
"continuationToken": null,
"data": []
}
{
"errors": [
{
"code": "fieldService.continuationToken.invalid",
"message": "The provided continuation token does not respect the expected format."
}
],
"errorReference": "59ddc09a23159395367307ab95b1c41a"
}
{
"errors": [
{
"code": "fieldservice.workorders.items.used.filter.invalid",
"message": "The invoice mode is invalid"
}
],
"errorReference": "59ddc09a23159395367307ab95b1c41b"
}
{
"errors": [
{
"code": "fieldService.size.exceeded",
"message": "size must not exceed 200."
}
],
"errorReference": "223e4567e89b12d3a456426614174001"
}
{
"errors": [
{
"code": "fieldService.size.tooSmall",
"message": "size must be at least 1."
}
],
"errorReference": "223e4567e89b12d3a456426614174002"
}
{
"errors": [
{
"code": "fieldService.size.invalid",
"message": "size must be an integer."
}
],
"errorReference": "223e4567e89b12d3a456426614174003"
}
{
"errors": [
{
"code": "unauthorized.nocredentials",
"message": "No credentials."
}
],
"errorReference": "f939c6b8c15045c9a70f500fdb570555"
}
{
"errors": [
{
"code": "unauthorized.badcredentials",
"message": "Bad Credentials."
}
],
"errorReference": "f1028f99811b422eb21f5ff176664069"
}
{
"errors": [
{
"code": "access.forbidden",
"message": "You don't have the rights to access this resource."
}
],
"errorReference": "a745dc4c5a2b473aaf8ce94c9260aa8f"
}
{
"errors": [
{
"code": "fieldService.workOrder.notfound",
"message": "Work order not found."
}
],
"errorReference": "a745dc4c5a2b473aaf8ce94c9260aa8f"
}
{
"errors": [
{
"code": "ratelimiter.toomanyrequest",
"message": "Rejected because of the rate limit definition."
}
],
"errorReference": "973326230a3f44daba6cc34a5939b4fb"
}
{
"errors": [
{
"code": "internal.server.error",
"message": "Something went wrong."
}
],
"errorReference": "6377010431314bf6b0b95ec4d32ddae0"
}