Trendsic Platform Service

<back to all web services

CrewAssignmentsExportCsvRequest

Requires Authentication
The following routes are available for this service:
POST,OPTIONS/v1/CrewAssignments/Export/CSV/{SelectedDate}
"use strict";
export class CrewAssignmentsExportCsvResponse {
    /** @param {{ResponseStatus?:ResponseStatus,file?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {ResponseStatus} */
    ResponseStatus;
    /** @type {string} */
    file;
}
export class CrewAssignmentCrewMember {
    /** @param {{Name?:string,Status?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Name;
    /** @type {string} */
    Status;
}
export class CrewAssignmentEquipment {
    /** @param {{Name?:string,Status?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Name;
    /** @type {string} */
    Status;
}
export class CrewAssignmentJob {
    /** @param {{JobName?:string,CrewMembers?:CrewAssignmentCrewMember[],Equipment?:CrewAssignmentEquipment[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    JobName;
    /** @type {CrewAssignmentCrewMember[]} */
    CrewMembers = [];
    /** @type {CrewAssignmentEquipment[]} */
    Equipment = [];
}
export class CrewAssignmentProject {
    /** @param {{ProjectName?:string,Jobs?:CrewAssignmentJob[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    ProjectName;
    /** @type {CrewAssignmentJob[]} */
    Jobs = [];
}
export class CrewAssignmentsExportCsvRequest {
    /** @param {{SelectedDate?:string,projects?:CrewAssignmentProject[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    SelectedDate;
    /** @type {CrewAssignmentProject[]} */
    projects = [];
}

JavaScript CrewAssignmentsExportCsvRequest DTOs

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

HTTP + JSV

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

POST /v1/CrewAssignments/Export/CSV/{SelectedDate} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	SelectedDate: 0001-01-01,
	projects: 
	[
		{
			ProjectName: String,
			Jobs: 
			[
				{
					JobName: String,
					CrewMembers: 
					[
						{
							Name: String,
							Status: String
						}
					],
					Equipment: 
					[
						{
							Name: String,
							Status: String
						}
					]
				}
			]
		}
	]
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	file: String
}