| GET,OPTIONS | /v1/visits/week |
|---|
"use strict";
export class CrewWeekCell {
/** @param {{Date?:string,VisitCount?:number,LoadPct?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Date;
/** @type {number} */
VisitCount;
/** @type {number} */
LoadPct;
}
export class CrewWeekRow {
/** @param {{CrewID?:number,CrewName?:string,CrewColor?:string,Cells?:CrewWeekCell[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
CrewID;
/** @type {string} */
CrewName;
/** @type {string} */
CrewColor;
/** @type {CrewWeekCell[]} */
Cells = [];
}
export class VisitWeekResponse {
/** @param {{From?:string,To?:string,Days?:string[],Rows?:CrewWeekRow[],ResponseStatus?:ResponseStatus}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
From;
/** @type {string} */
To;
/** @type {string[]} */
Days = [];
/** @type {CrewWeekRow[]} */
Rows = [];
/** @type {ResponseStatus} */
ResponseStatus;
}
export class VisitWeekRequest {
/** @param {{From?:string,Days?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
From;
/** @type {number} */
Days;
}
JavaScript VisitWeekRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/visits/week HTTP/1.1 Host: api.dev.dynamics.trendsic.com Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
From: String,
To: String,
Days:
[
String
],
Rows:
[
{
CrewID: 0,
CrewName: String,
CrewColor: String,
Cells:
[
{
Date: String,
VisitCount: 0,
LoadPct: 0
}
]
}
],
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}
}