Work Order Photos REST API
Resource URL Summary
Retrieve a Photograph for a specific Work Order
GETÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/${PhotoID}
Attach Photographs to a specific Work Order
POSTÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/
Delete a Photograph for a specific Work Order
DELETEÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/${PhotoID}
Bulk Delete Photographs for a specific Work Order
DELETEÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/
API Specific Parameters
Parameter | Description |
---|---|
${PhotoID} | Identifies the ID of the photo to be accessed. |
| Identifies the Work Order Object. |
HTTP Headers
This API uses the default ServiceMobility HTTP Headers.
API Specifics
Retrieve a Photograph for a specific Work Order
This REST API will return the binary image data (with appropriate mime type HTTP header set) for the Photograph with the specified ID, for the Work Order with the specified ID. The Photograph with the specified ID and the Work Order with the specified ID must already exist in the system.
URL
GETÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/${PhotoID}
HTTP Request Body
This request does not require a request body.Â
HTTP Response Body
On success, an HTTP response code of 200 will be returned, and the response body will contain the the binary data for the Photograph.
Otherwise, on error, the API returns the standard response object.
Attach Photographs to a specific Work Order
This REST API will associate one or more Photographs to the Work Order with specified ID. The Work Order with the specified ID must already exist in the system.
The REST API will store each Photograph as a jpeg file in the storage service. In addition, the Work Order object with specified ID will be updated to contain a reference to the Photograph(s) in the Photos
 object.
The Photos
 object is a collection of Photograph details including the Photograph ID, date the Photograph was captured, and notes.
This REST API requires that the Content-Type
HTTP header be set to multipart/form-data
.
URL
POSTÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/
HTTP Request Body
This request does not require a request body.Â
HTTP Response Body
On success, an HTTP response code of 201 will be returned, and the response body will contain a collection of objects. Each object will contain a file name for the Photograph.Â
[ { "Name": " " } ]
Otherwise, on error, the API returns the standard response object.
Delete a Photograph for a specific Work Order
This REST API will delete a Photograph with the specified ID, for the Work Order with the specified ID, from the system. The Photograph with the specified ID and the Work Order with the specified ID must already exist in the system.
URL
DELETEÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/${PhotoID}
HTTP Request Body
This request does not require a request body.Â
HTTP Response
The API returns the standard response object on both success and error.
Bulk Delete Photographs for a specific Work Order
This REST API will delete Photographs with the specified IDs, for the Work Order with the specified ID, from the system. The Photographs with the specified IDs and the Work Order with the specified ID must already exist in the system.
URL
DELETEÂ /seiapi/v3/trans/WorkOrder/${WorkOrderNum}/Photos/
HTTP Request Body
The HTTP request body must contain a a JSON array of Photograph IDs to be deleted.
HTTP Response
The API returns the standard response object on both success and error.