Trendsic Platform Service

<back to all web services

DriverPhotoRequest

Requires Authentication
The following routes are available for this service:
POST,OPTIONS/v1/worker/dispatch/photo
"use strict";
export class DriverStampView {
    /** @param {{Stage?:string,AtUtc?:string,Note?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Stage;
    /** @type {string} */
    AtUtc;
    /** @type {string} */
    Note;
}
export class DriverTruckView {
    /** @param {{Code?:string,Stage?:string,StageSinceUtc?:string,LoadsToday?:number,NetToday?:number,EstLoad?:number,Slot?:string,SiteName?:string,SupplierName?:string,NextSiteName?:string,Facility?:string,FacilityShort?:string,Unit?:string,QueuePosition?:number,HoldCode?:string,HoldReason?:string,HoldEndUtc?:string,OpenLoadId?:number,OpenLoadCode?:string,OpenLoadPhotos?:number,Stamps?:DriverStampView[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Code;
    /** @type {string} */
    Stage;
    /** @type {?string} */
    StageSinceUtc;
    /** @type {number} */
    LoadsToday;
    /** @type {number} */
    NetToday;
    /** @type {?number} */
    EstLoad;
    /** @type {string} */
    Slot;
    /** @type {string} */
    SiteName;
    /** @type {string} */
    SupplierName;
    /** @type {string} */
    NextSiteName;
    /** @type {string} */
    Facility;
    /** @type {string} */
    FacilityShort;
    /** @type {string} */
    Unit;
    /** @type {?number} */
    QueuePosition;
    /** @type {string} */
    HoldCode;
    /** @type {string} */
    HoldReason;
    /** @type {?string} */
    HoldEndUtc;
    /** @type {?number} */
    OpenLoadId;
    /** @type {string} */
    OpenLoadCode;
    /** @type {number} */
    OpenLoadPhotos;
    /** @type {DriverStampView[]} */
    Stamps = [];
}
export class DriverRigView {
    /** @param {{Code?:string,Name?:string,RigType?:string,IsFree?:boolean,HoldCode?:string,HoldReason?:string,HoldEndUtc?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Code;
    /** @type {string} */
    Name;
    /** @type {string} */
    RigType;
    /** @type {boolean} */
    IsFree;
    /** @type {string} */
    HoldCode;
    /** @type {string} */
    HoldReason;
    /** @type {?string} */
    HoldEndUtc;
}
export class DriverJobView {
    /** @param {{Kind?:string,Code?:string,Cargo?:string,Customer?:string,CustomerPhone?:string,HoldContact?:string,HoldPhone?:string,FromLoc?:string,ToLoc?:string,Miles?:number,WindowText?:string,Stage?:string,Rate?:number,RequiredRig?:string,EtaText?:string,OfferExpiresUtc?:string,RequestId?:number,LoadId?:number,LoadCode?:string,LoadPay?:number,Photos?:number,Stamps?:DriverStampView[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Kind;
    /** @type {string} */
    Code;
    /** @type {string} */
    Cargo;
    /** @type {string} */
    Customer;
    /** @type {string} */
    CustomerPhone;
    /** @type {string} */
    HoldContact;
    /** @type {string} */
    HoldPhone;
    /** @type {string} */
    FromLoc;
    /** @type {string} */
    ToLoc;
    /** @type {number} */
    Miles;
    /** @type {string} */
    WindowText;
    /** @type {string} */
    Stage;
    /** @type {?number} */
    Rate;
    /** @type {string} */
    RequiredRig;
    /** @type {string} */
    EtaText;
    /** @type {?string} */
    OfferExpiresUtc;
    /** @type {?number} */
    RequestId;
    /** @type {?number} */
    LoadId;
    /** @type {string} */
    LoadCode;
    /** @type {?number} */
    LoadPay;
    /** @type {number} */
    Photos;
    /** @type {DriverStampView[]} */
    Stamps = [];
}
export class DriverOdView {
    /** @param {{Code?:string,Name?:string,Zone?:string,Status?:string,Tier?:string,Capabilities?:string,PingCode?:string,PingAddress?:string,PingZone?:string,PingBags?:number,PingNeeds?:string,PingNote?:string,PingExpiresUtc?:string,RunCode?:string,RunAddress?:string,RunZone?:string,RunBags?:number,RunStage?:string,RunNeeds?:string,RunNote?:string,RunEta?:string,OdBase?:number,OdPerBag?:number,HoldCode?:string,HoldReason?:string,HoldEndUtc?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Code;
    /** @type {string} */
    Name;
    /** @type {string} */
    Zone;
    /** @type {string} */
    Status;
    /** @type {string} */
    Tier;
    /** @type {string} */
    Capabilities;
    /** @type {string} */
    PingCode;
    /** @type {string} */
    PingAddress;
    /** @type {string} */
    PingZone;
    /** @type {?number} */
    PingBags;
    /** @type {string} */
    PingNeeds;
    /** @type {string} */
    PingNote;
    /** @type {?string} */
    PingExpiresUtc;
    /** @type {string} */
    RunCode;
    /** @type {string} */
    RunAddress;
    /** @type {string} */
    RunZone;
    /** @type {?number} */
    RunBags;
    /** @type {string} */
    RunStage;
    /** @type {string} */
    RunNeeds;
    /** @type {string} */
    RunNote;
    /** @type {string} */
    RunEta;
    /** @type {?number} */
    OdBase;
    /** @type {?number} */
    OdPerBag;
    /** @type {string} */
    HoldCode;
    /** @type {string} */
    HoldReason;
    /** @type {?string} */
    HoldEndUtc;
}
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 DriverIncidentView {
    /** @param {{IncidentId?:number,Code?:string,Kind?:string,KindDetail?:string,Status?:string,LoadCode?:string,TruckCode?:string,LocationText?:string,DriverPref?:string,TruckRecovery?:string,LoadRecovery?:string,TransloadTruckCode?:string,HoldCode?:string,OpenedUtc?:string,ResolvedUtc?:string,Messages?:DispatchIncidentMessageView[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    IncidentId;
    /** @type {string} */
    Code;
    /** @type {string} */
    Kind;
    /** @type {string} */
    KindDetail;
    /** @type {string} */
    Status;
    /** @type {string} */
    LoadCode;
    /** @type {string} */
    TruckCode;
    /** @type {string} */
    LocationText;
    /** @type {string} */
    DriverPref;
    /** @type {string} */
    TruckRecovery;
    /** @type {string} */
    LoadRecovery;
    /** @type {string} */
    TransloadTruckCode;
    /** @type {string} */
    HoldCode;
    /** @type {string} */
    OpenedUtc;
    /** @type {?string} */
    ResolvedUtc;
    /** @type {DispatchIncidentMessageView[]} */
    Messages = [];
}
export class DriverPayLineView {
    /** @param {{Code?:string,Module?:string,SourceLabel?:string,DestinationLabel?:string,QtyText?:string,Pay?:number,PayPlanLabel?:string,Status?:string,ClosedUtc?:string,OpenedUtc?:string,TicketCode?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Code;
    /** @type {string} */
    Module;
    /** @type {string} */
    SourceLabel;
    /** @type {string} */
    DestinationLabel;
    /** @type {string} */
    QtyText;
    /** @type {?number} */
    Pay;
    /** @type {string} */
    PayPlanLabel;
    /** @type {string} */
    Status;
    /** @type {?string} */
    ClosedUtc;
    /** @type {string} */
    OpenedUtc;
    /** @type {string} */
    TicketCode;
}
export class DriverMeResponse {
    /** @param {{ContactId?:number,Name?:string,Phone?:string,PayPlanName?:string,PayPlanBasis?:string,PayPlanRate?:number,Truck?:DriverTruckView,Rig?:DriverRigView,Jobs?:DriverJobView[],Od?:DriverOdView,Incidents?:DriverIncidentView[],Pay?:DriverPayLineView[],ServerUtc?:string,Message?:string,ResponseStatus?:ResponseStatus}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    ContactId;
    /** @type {string} */
    Name;
    /** @type {string} */
    Phone;
    /** @type {string} */
    PayPlanName;
    /** @type {string} */
    PayPlanBasis;
    /** @type {?number} */
    PayPlanRate;
    /** @type {DriverTruckView} */
    Truck;
    /** @type {DriverRigView} */
    Rig;
    /** @type {DriverJobView[]} */
    Jobs = [];
    /** @type {DriverOdView} */
    Od;
    /** @type {DriverIncidentView[]} */
    Incidents = [];
    /** @type {DriverPayLineView[]} */
    Pay = [];
    /** @type {string} */
    ServerUtc;
    /** @type {string} */
    Message;
    /** @type {ResponseStatus} */
    ResponseStatus;
}
export class DriverPhotoRequest {
    /** @param {{LoadId?:number,Kind?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    LoadId;
    /** @type {string} */
    Kind;
}

JavaScript DriverPhotoRequest DTOs

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

HTTP + XML

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

POST /v1/worker/dispatch/photo HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<DriverPhotoRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Kind>String</Kind>
  <LoadId>0</LoadId>
</DriverPhotoRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<DriverMeResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <ContactId>0</ContactId>
  <Incidents>
    <DriverIncidentView>
      <Code>String</Code>
      <DriverPref>String</DriverPref>
      <HoldCode>String</HoldCode>
      <IncidentId>0</IncidentId>
      <Kind>String</Kind>
      <KindDetail>String</KindDetail>
      <LoadCode>String</LoadCode>
      <LoadRecovery>String</LoadRecovery>
      <LocationText>String</LocationText>
      <Messages>
        <DispatchIncidentMessageView>
          <AtUtc>0001-01-01T00:00:00</AtUtc>
          <MessageId>0</MessageId>
          <Msg>String</Msg>
          <Role>String</Role>
          <Who>String</Who>
        </DispatchIncidentMessageView>
      </Messages>
      <OpenedUtc>0001-01-01T00:00:00</OpenedUtc>
      <ResolvedUtc>0001-01-01T00:00:00</ResolvedUtc>
      <Status>String</Status>
      <TransloadTruckCode>String</TransloadTruckCode>
      <TruckCode>String</TruckCode>
      <TruckRecovery>String</TruckRecovery>
    </DriverIncidentView>
  </Incidents>
  <Jobs>
    <DriverJobView>
      <Cargo>String</Cargo>
      <Code>String</Code>
      <Customer>String</Customer>
      <CustomerPhone>String</CustomerPhone>
      <EtaText>String</EtaText>
      <FromLoc>String</FromLoc>
      <HoldContact>String</HoldContact>
      <HoldPhone>String</HoldPhone>
      <Kind>String</Kind>
      <LoadCode>String</LoadCode>
      <LoadId>0</LoadId>
      <LoadPay>0</LoadPay>
      <Miles>0</Miles>
      <OfferExpiresUtc>0001-01-01T00:00:00</OfferExpiresUtc>
      <Photos>0</Photos>
      <Rate>0</Rate>
      <RequestId>0</RequestId>
      <RequiredRig>String</RequiredRig>
      <Stage>String</Stage>
      <Stamps>
        <DriverStampView>
          <AtUtc>0001-01-01T00:00:00</AtUtc>
          <Note>String</Note>
          <Stage>String</Stage>
        </DriverStampView>
      </Stamps>
      <ToLoc>String</ToLoc>
      <WindowText>String</WindowText>
    </DriverJobView>
  </Jobs>
  <Message>String</Message>
  <Name>String</Name>
  <Od>
    <Capabilities>String</Capabilities>
    <Code>String</Code>
    <HoldCode>String</HoldCode>
    <HoldEndUtc>0001-01-01T00:00:00</HoldEndUtc>
    <HoldReason>String</HoldReason>
    <Name>String</Name>
    <OdBase>0</OdBase>
    <OdPerBag>0</OdPerBag>
    <PingAddress>String</PingAddress>
    <PingBags>0</PingBags>
    <PingCode>String</PingCode>
    <PingExpiresUtc>0001-01-01T00:00:00</PingExpiresUtc>
    <PingNeeds>String</PingNeeds>
    <PingNote>String</PingNote>
    <PingZone>String</PingZone>
    <RunAddress>String</RunAddress>
    <RunBags>0</RunBags>
    <RunCode>String</RunCode>
    <RunEta>String</RunEta>
    <RunNeeds>String</RunNeeds>
    <RunNote>String</RunNote>
    <RunStage>String</RunStage>
    <RunZone>String</RunZone>
    <Status>String</Status>
    <Tier>String</Tier>
    <Zone>String</Zone>
  </Od>
  <Pay>
    <DriverPayLineView>
      <ClosedUtc>0001-01-01T00:00:00</ClosedUtc>
      <Code>String</Code>
      <DestinationLabel>String</DestinationLabel>
      <Module>String</Module>
      <OpenedUtc>0001-01-01T00:00:00</OpenedUtc>
      <Pay>0</Pay>
      <PayPlanLabel>String</PayPlanLabel>
      <QtyText>String</QtyText>
      <SourceLabel>String</SourceLabel>
      <Status>String</Status>
      <TicketCode>String</TicketCode>
    </DriverPayLineView>
  </Pay>
  <PayPlanBasis>String</PayPlanBasis>
  <PayPlanName>String</PayPlanName>
  <PayPlanRate>0</PayPlanRate>
  <Phone>String</Phone>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
  <Rig>
    <Code>String</Code>
    <HoldCode>String</HoldCode>
    <HoldEndUtc>0001-01-01T00:00:00</HoldEndUtc>
    <HoldReason>String</HoldReason>
    <IsFree>false</IsFree>
    <Name>String</Name>
    <RigType>String</RigType>
  </Rig>
  <ServerUtc>0001-01-01T00:00:00</ServerUtc>
  <Truck>
    <Code>String</Code>
    <EstLoad>0</EstLoad>
    <Facility>String</Facility>
    <FacilityShort>String</FacilityShort>
    <HoldCode>String</HoldCode>
    <HoldEndUtc>0001-01-01T00:00:00</HoldEndUtc>
    <HoldReason>String</HoldReason>
    <LoadsToday>0</LoadsToday>
    <NetToday>0</NetToday>
    <NextSiteName>String</NextSiteName>
    <OpenLoadCode>String</OpenLoadCode>
    <OpenLoadId>0</OpenLoadId>
    <OpenLoadPhotos>0</OpenLoadPhotos>
    <QueuePosition>0</QueuePosition>
    <SiteName>String</SiteName>
    <Slot>String</Slot>
    <Stage>String</Stage>
    <StageSinceUtc>0001-01-01T00:00:00</StageSinceUtc>
    <Stamps>
      <DriverStampView>
        <AtUtc>0001-01-01T00:00:00</AtUtc>
        <Note>String</Note>
        <Stage>String</Stage>
      </DriverStampView>
    </Stamps>
    <SupplierName>String</SupplierName>
    <Unit>String</Unit>
  </Truck>
</DriverMeResponse>