Trendsic Platform Service

<back to all web services

RoutePlanWeekRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/routeplan/week
"use strict";
export class RoutePlanCrew {
    /** @param {{CrewID?:number,CrewName?:string,CrewColor?:string,HomeZip?:string,YardLat?:number,YardLng?:number,DailyCapacityMin?:number,WeeklyCapacityMin?:number,Specialist?:boolean}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    CrewID;
    /** @type {string} */
    CrewName;
    /** @type {string} */
    CrewColor;
    /** @type {string} */
    HomeZip;
    /** @type {?number} */
    YardLat;
    /** @type {?number} */
    YardLng;
    /** @type {number} */
    DailyCapacityMin;
    /** @type {number} */
    WeeklyCapacityMin;
    /** @type {boolean} */
    Specialist;
}
export class RoutePlanVisit {
    /** @param {{AgreementID?:number,AgreementJobID?:number,Name?:string,Sub?:string,ServiceType?:string,Zip?:string,Area?:string,Lat?:number,Lng?:number,DurationMin?:number,DueIso?:string,DueLabel?:string,Overdue?:boolean,DefaultCrewID?:number,RouteCrewID?:number,RouteSeq?:number,RouteDateIso?:string,LateDays?:number,AutoPay?:boolean,SkipPolicy?:string,SkipCreditAmount?:number}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    AgreementID;
    /** @type {?number} */
    AgreementJobID;
    /** @type {string} */
    Name;
    /** @type {string} */
    Sub;
    /** @type {string} */
    ServiceType;
    /** @type {string} */
    Zip;
    /** @type {string} */
    Area;
    /** @type {?number} */
    Lat;
    /** @type {?number} */
    Lng;
    /** @type {number} */
    DurationMin;
    /** @type {string} */
    DueIso;
    /** @type {string} */
    DueLabel;
    /** @type {boolean} */
    Overdue;
    /** @type {?number} */
    DefaultCrewID;
    /** @type {?number} */
    RouteCrewID;
    /** @type {?number} */
    RouteSeq;
    /** @type {string} */
    RouteDateIso;
    /** @type {number} */
    LateDays;
    /** @type {boolean} */
    AutoPay;
    /** @type {string} */
    SkipPolicy;
    /** @type {number} */
    SkipCreditAmount;
}
export class RoutePlanSkippedVisit {
    /** @param {{AgreementJobID?:number,AgreementID?:number,Name?:string,DateIso?:string,Reason?:string,CreditAmount?:number}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    AgreementJobID;
    /** @type {number} */
    AgreementID;
    /** @type {string} */
    Name;
    /** @type {string} */
    DateIso;
    /** @type {string} */
    Reason;
    /** @type {number} */
    CreditAmount;
}
export class RoutePlanWeekResponse {
    /** @param {{FromIso?:string,ToIso?:string,Crews?:RoutePlanCrew[],Visits?:RoutePlanVisit[],Skipped?:RoutePlanSkippedVisit[],ResponseStatus?:ResponseStatus}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    FromIso;
    /** @type {string} */
    ToIso;
    /** @type {RoutePlanCrew[]} */
    Crews = [];
    /** @type {RoutePlanVisit[]} */
    Visits = [];
    /** @type {RoutePlanSkippedVisit[]} */
    Skipped = [];
    /** @type {ResponseStatus} */
    ResponseStatus;
}
export class RoutePlanWeekRequest {
    /** @param {{From?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    From;
}

JavaScript RoutePlanWeekRequest DTOs

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

HTTP + OTHER

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

GET /v1/routeplan/week HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"FromIso":"String","ToIso":"String","Crews":[{"CrewID":0,"CrewName":"String","CrewColor":"String","HomeZip":"String","YardLat":0,"YardLng":0,"DailyCapacityMin":0,"WeeklyCapacityMin":0,"Specialist":false}],"Visits":[{"AgreementID":0,"AgreementJobID":0,"Name":"String","Sub":"String","ServiceType":"String","Zip":"String","Area":"String","Lat":0,"Lng":0,"DurationMin":0,"DueIso":"String","DueLabel":"String","Overdue":false,"DefaultCrewID":0,"RouteCrewID":0,"RouteSeq":0,"RouteDateIso":"String","LateDays":0,"AutoPay":false,"SkipPolicy":"String","SkipCreditAmount":0}],"Skipped":[{"AgreementJobID":0,"AgreementID":0,"Name":"String","DateIso":"String","Reason":"String","CreditAmount":0}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}