Dispatch: AddRouteByDeviceCreates a Route and assigns it to a Device

See Also

Usage Notes

<location id="#" name="" pickups="" dropoffs="" delay="#" notes="" />
<point name="" latitude="#" longitude="#" pickups="" dropoffs="" delay="#" notes="" />
<address name="" pickups="" dropoffs="" delay="#" notes="">
street address

Example of Returned Data

<AddRouteByDevice Success="?" Message="" RouteID="#" />

Test Method

DeviceIDint32Unique device identifier
FleetIDint32Unique fleet identifier; or -1 to assign it to same fleet as the device
NamestringThe name of the Route
DirectionsbooleanReserved for future use
AvoidTollsbooleanAttempt to bypass toll-roads (not guaranteed)
AvoidHighwaysbooleanAttempt to bypass highways (not guaranteed)
AdHocbooleanTemporary Route which is automatically deleted when the Device is unassigned
OptimizebooleanSolve in-between destinations for "Travelling Salesman" problem
ColourcharMust be a Char listed by APIZoneColours
LateThresholdint32The amount of time elapsed after a Device fails to reach a destination on time (in seconds)
EarlyThresholdint32The amount of time before a Device reaches a destination on time (in seconds)
DestinationsXmlstringSee Usage Notes.
A string to represent the stops in a route.