Skip to main content

ToolWatch API: Work Order Charges

ToolWatch API request to retrieve work order charges, with URIs, headers, fields, and example responses.

This article lists the ToolWatch API request for work order charges: Retrieve. Every request needs an authorization token. To get one, see ToolWatch API: Authorization.

Retrieve

Request

URI

https://api.{cluster}.toolwatch.net/workordercharges/{id}

{id} is the work order id. All charges for that work order are returned.

Allowable querystring parameters

Parameter

Description

columns

Comma-separated list of properties to return.

Http Method

GET

Headers

Authorization: {token}

Request Body

Not allowed for GET

Response

200 Ok

By default every property is returned. Use the columns querystring parameter to limit the response to specific properties.

Field

Type

Description

Id

guid

Unique identifier.

WorkOrderId

guid

Work order the charge belongs to.

Description

string

Charge description.

Qty

decimal

Quantity.

Cost

decimal

Cost.

CostCenterId

guid

Cost center id.

CostCodeId

guid

Cost code id.

WorkOrderRequiredPartId

guid

Work order required part id.

WorkOrderPartId

guid

Work order part id.

CreatedOn

date

Date the charge was created.

Example response body:

[
{
"Id": "{id}",
"WorkOrderId": "{workOrderId}",
"Description": "Work Order Charge",
"Qty": 1.0,
"Cost": 25.0
}
]

404 Not Found

Triggered when field parameters in querystring are not allowed.

Response body will contain error message

{"Message":"Criteria is invalid","Type":"Exception"}
Did this answer your question?