Trendsic Platform Service

<back to all web services

DispatchIncidentLoadRequest

Requires Authentication
Requires any of the permissions:DISPATCH:HAUL:MANAGE, DISPATCH:JOB:MANAGE, DISPATCH:ONDEMAND:MANAGE
The following routes are available for this service:
POST,OPTIONS/v1/dispatch/incidents/{IncidentId}/load
"use strict";
export class DispatchIncidentMessageView {
    /** @param {{MessageId?:number,Who?:string,Role?:string,Msg?:string,AtUtc?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    MessageId;
    /** @type {string} */
    Who;
    /** @type {string} */
    Role;
    /** @type {string} */
    Msg;
    /** @type {string} */
    AtUtc;
}
export class DispatchIncidentView {
    /** @param {{IncidentId?:number,Code?:string,Kind?:string,KindDetail?:string,LoadId?:number,LoadCode?:string,LoadStatus?:string,SourceLabel?:string,DestinationLabel?:string,QtyText?:string,TruckCode?:string,TruckLabel?:string,LocationText?:string,Lat?:number,Lng?:number,DriverPref?:string,OpenedBy?:string,OpenedVia?:string,Resolver?:string,Status?:string,TruckRecovery?:string,TruckRecoveredUtc?:string,LoadRecovery?:string,LoadRecoveredUtc?:string,TransloadTruckCode?:string,HoldId?:number,HoldCode?:string,PhotoCount?:number,OpenedUtc?:string,ResolvedUtc?:string,ResolvedBy?:string,ReopenedUtc?:string,Messages?:DispatchIncidentMessageView[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    IncidentId;
    /** @type {string} */
    Code;
    /** @type {string} */
    Kind;
    /** @type {string} */
    KindDetail;
    /** @type {?number} */
    LoadId;
    /** @type {string} */
    LoadCode;
    /** @type {string} */
    LoadStatus;
    /** @type {string} */
    SourceLabel;
    /** @type {string} */
    DestinationLabel;
    /** @type {string} */
    QtyText;
    /** @type {string} */
    TruckCode;
    /** @type {string} */
    TruckLabel;
    /** @type {string} */
    LocationText;
    /** @type {?number} */
    Lat;
    /** @type {?number} */
    Lng;
    /** @type {string} */
    DriverPref;
    /** @type {string} */
    OpenedBy;
    /** @type {string} */
    OpenedVia;
    /** @type {string} */
    Resolver;
    /** @type {string} */
    Status;
    /** @type {string} */
    TruckRecovery;
    /** @type {?string} */
    TruckRecoveredUtc;
    /** @type {string} */
    LoadRecovery;
    /** @type {?string} */
    LoadRecoveredUtc;
    /** @type {string} */
    TransloadTruckCode;
    /** @type {?number} */
    HoldId;
    /** @type {string} */
    HoldCode;
    /** @type {number} */
    PhotoCount;
    /** @type {string} */
    OpenedUtc;
    /** @type {?string} */
    ResolvedUtc;
    /** @type {string} */
    ResolvedBy;
    /** @type {?string} */
    ReopenedUtc;
    /** @type {DispatchIncidentMessageView[]} */
    Messages = [];
}
export class DispatchIncidentTruckView {
    /** @param {{Code?:string,DriverName?:string,Stage?:string,OpenLoadCode?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Code;
    /** @type {string} */
    DriverName;
    /** @type {string} */
    Stage;
    /** @type {string} */
    OpenLoadCode;
}
export class DispatchIncidentsResponse {
    /** @param {{Incidents?:DispatchIncidentView[],EmptyTrucks?:DispatchIncidentTruckView[],Trucks?:DispatchIncidentTruckView[],TransloadTruckCode?:string,ResponseStatus?:ResponseStatus}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {DispatchIncidentView[]} */
    Incidents = [];
    /** @type {DispatchIncidentTruckView[]} */
    EmptyTrucks = [];
    /** @type {DispatchIncidentTruckView[]} */
    Trucks = [];
    /** @type {string} */
    TransloadTruckCode;
    /** @type {ResponseStatus} */
    ResponseStatus;
}
export class DispatchIncidentLoadRequest {
    /** @param {{IncidentId?:number,Action?:string,TransloadTruckCode?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    IncidentId;
    /** @type {string} */
    Action;
    /** @type {string} */
    TransloadTruckCode;
}

JavaScript DispatchIncidentLoadRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/dispatch/incidents/{IncidentId}/load HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"IncidentId":0,"Action":"String","TransloadTruckCode":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"Incidents":[{"IncidentId":0,"Code":"String","Kind":"String","KindDetail":"String","LoadId":0,"LoadCode":"String","LoadStatus":"String","SourceLabel":"String","DestinationLabel":"String","QtyText":"String","TruckCode":"String","TruckLabel":"String","LocationText":"String","Lat":0,"Lng":0,"DriverPref":"String","OpenedBy":"String","OpenedVia":"String","Resolver":"String","Status":"String","TruckRecovery":"String","TruckRecoveredUtc":"0001-01-01T00:00:00.0000000","LoadRecovery":"String","LoadRecoveredUtc":"0001-01-01T00:00:00.0000000","TransloadTruckCode":"String","HoldId":0,"HoldCode":"String","PhotoCount":0,"OpenedUtc":"0001-01-01T00:00:00.0000000","ResolvedUtc":"0001-01-01T00:00:00.0000000","ResolvedBy":"String","ReopenedUtc":"0001-01-01T00:00:00.0000000","Messages":[{"MessageId":0,"Who":"String","Role":"String","Msg":"String","AtUtc":"0001-01-01T00:00:00.0000000"}]}],"EmptyTrucks":[{"Code":"String","DriverName":"String","Stage":"String","OpenLoadCode":"String"}],"Trucks":[{"Code":"String","DriverName":"String","Stage":"String","OpenLoadCode":"String"}],"TransloadTruckCode":"String","ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}