Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Published by Scroll Versions from space SBUD and version 5

Status
colourGreen
title5.4.0

A pass-through API to ServiceDispatch (when configured) which allows the ServiceDispatch's "Get Status History" API to be called.    

Panel
borderColorgrey
bgColorwhitesmoke
borderStylesolid

On this page:

Table of Contents
maxLevel2

Related pages:

Resource URL Summary

Panel
borderColorgrey
bgColorwhitesmoke
borderStylesolid

Pass Through Call to ServiceDispatch's "Get Status History" API

PUT /up/v5/rest/dispatch/getStatusHistory  

Include Page
_Default HTTP Headers
_Default HTTP Headers


API Specifics

Panel
borderColor#D3D3D3

Pass Through Call to ServiceDispatch's "Get Status History" API

This RESTified API will perform a pass-through call to the ServiceDispatch sub-system's "Get Status History" API (when configured).

URL

Panel
borderColorgrey
bgColorwhitesmoke
borderStylesolid

PUT /up/v5/rest/dispatch/getStatusHistory

HTTP Request Body

This request requires a JSON object supplied in the HTTP request body, which defines the parameters that will be passed through to the ServiceBroker "Get Status History" APi.

GetStatusHistory Object Format

Code Block
languagejs
{
	"Id": "",
	"CallStatus": "",
	"SecStatus": "",
	"StartDate": "",
	"StartTime": "",
	"EndDate": "",
	"EndTime": ""
}

GetStatusHistory Object Properties

PropertyTypeRequired?DescriptionServiceDispatch Field Mapping: ServiceDispatch
IdstringNoPass through parameter to the ServiceDispatch "Get Status History" API. CallNo
CallStatusstringNoPass through parameter to the ServiceDispatch "Get Status History" API.CallStatus
SecStatusstringNoPass through parameter to the ServiceDispatch "Get Status History" API.SecStatus
StartDatestringNo

Pass through parameter to the ServiceDispatch "Get Status History" API.

StartDate
StartTimestringNo

Pass through parameter to the ServiceDispatch "Get Status History" API.

StartTime
EndDatestringNo

Pass through parameter to the ServiceDispatch "Get Status History" API.

EndDate
EndTimestringNo

Pass through parameter to the ServiceDispatch "Get Status History" API.

EndTime

HTTP Response

Success

On success, a JSON-formatted version of the ServiceDispatch "Get Status History" API response will be returned.

GetStatusHistory Response Object Format

Code Block
languagejs
{
    "AckMsg": "",
    "WorkItemCount": "4",
    "WorkItems": [
        {
            "MFGID": "9999",
            "Id": "ka.2019-8-7.100263",
            "WorkStatus": "COMPLETED",
            "WorkSubStatus": "COMPLETED",
            "SPSvcrAcct": "FSSTEST",
            "UpdatedDate": "2019-11-04T11:47:00.000Z",
            "CompletedDate": "2019-11-04T00:00:00.000Z",
            "Payment": [
                {
                    "POAmount": "0"
                }
            ],
            "Booking": {
                "ServiceOrg": "FSSTEST",
                "SchdStart": "2019-08-09T12:00:00.000Z",
                "SchdEnd": "2019-08-09T23:00:00.000Z"
            }
        },
		// ...
    ]
}

GetStatusHistory Response Object Properties

PropertyTypeDescription
AckMsgstringDescription of the response success.
WorkItemCountstringThe number of ServiceDispatch Servicer objects in the WorkItems array.
WorkItemsarrayAn array of objects, each representing the status for a ServiceDispatch Work Item.

MFGIDstringThe ServiceDispatch Work Item MfgSvcrAcct value.

IdstringThe ServiceDIspatch Work Item CallNo value.

WorkStatusstringThe ServiceDIspatch Work Item work status.

WorkSubStatusstringThe ServiceDIspatch Work Item work sub-status.

SPSvcrAcctstringThe ServiceDispatch Work Item ServicePower account number.

UpdatedDatestringThe ServiceDIspatch Work Item updated date.

CompletedDatestringThe ServiceDIspatch Work Item completed date.

PaymentarrayAn array containing details of the Work Item payment information.


POAmountstringThe ServiceDispatch PO amount value.

BookingobjectAn object containing details of the Work Item booking.


ServiceOrgstringThe ServiceDIspatch Work Item service organization.


SchdStartstringThe ServiceDIspatch Work Item scheduled start date/time.


SchdEndstringThe ServiceDIspatch Work Item scheduled end date/time.

Error

On error, a JSON-formatted version of the ServiceDispatch "Get Status History" API response will be returned.

Code Block
languagejs
{
    "Success": false,
    "Code": 9,
    "Payload": {
        "returnCode": {
            "type": "Error",
            "message": "Dispatch Error Code"
        }
    }   
}  
Note
In addition to the Standard Return Codes, Service Dispatch has unique error codes that can be found here.