Trendsic Platform Service

<back to all web services

ProjectEquipmentListRequest

Requires Authentication
The following routes are available for this service:
GET,POST,PUT,DELETE,OPTIONS/v1/Project/Equipment/{ProjectID}
GET,POST,PUT,DELETE,OPTIONS/v1/Project/Equipment/{ProjectID}/{JobID}
"use strict";
export class Project {
    /** @param {{ProjectID?:number,ProjectUID?:string,ProjectName?:string,ImageURL?:string,ImageKey?:string,ClientName?:string,ClientPhone?:string,ClientEmail?:string,ProjectManagerID?:number,ProjectManagerName?:string,StartDate?:string,EndDate?:string,ActualStartDate?:string,ActualEndDate?:string,JobCount?:number,CrewMemberCount?:number,EquipmentCount?:number,MaterialCount?:number,ProjectStatusID?:number,ProjectStatusDescription?:string,Budget?:number,CostToDate?:number,ProjectLocation?:string,ProjectType?:string,ProjectSponsor?:string,CreatedBy?:string,CreatedAt?:string,UpdatedAt?:string,ProjectDescription?:string,Scope?:string,StatusId?:number}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    ProjectID;
    /** @type {string} */
    ProjectUID;
    /** @type {string} */
    ProjectName;
    /** @type {string} */
    ImageURL;
    /** @type {string} */
    ImageKey;
    /** @type {string} */
    ClientName;
    /** @type {string} */
    ClientPhone;
    /** @type {string} */
    ClientEmail;
    /** @type {number} */
    ProjectManagerID;
    /** @type {string} */
    ProjectManagerName;
    /** @type {?string} */
    StartDate;
    /** @type {?string} */
    EndDate;
    /** @type {?string} */
    ActualStartDate;
    /** @type {?string} */
    ActualEndDate;
    /** @type {number} */
    JobCount;
    /** @type {number} */
    CrewMemberCount;
    /** @type {number} */
    EquipmentCount;
    /** @type {number} */
    MaterialCount;
    /** @type {number} */
    ProjectStatusID;
    /** @type {string} */
    ProjectStatusDescription;
    /** @type {number} */
    Budget;
    /** @type {number} */
    CostToDate;
    /** @type {string} */
    ProjectLocation;
    /** @type {string} */
    ProjectType;
    /** @type {string} */
    ProjectSponsor;
    /** @type {string} */
    CreatedBy;
    /** @type {?string} */
    CreatedAt;
    /** @type {?string} */
    UpdatedAt;
    /** @type {string} */
    ProjectDescription;
    /** @type {string} */
    Scope;
    /** @type {number} */
    StatusId;
}
export class Equipment {
    /** @param {{EquipmentID?:number,EquipmentName?:string,EquipmentTypeID?:number,Manufacturer?:string,EquipmentType?:string,SerialNumber?:string,BarCode?:string,EquipmentLocation?:string,ImageURL?:string,ProductDetailsURL?:string,RecordCreatedDate?:string,CreatedByUID?:string,Active?:boolean,Notes?:string,Rate?:number,Projects?:Project[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    EquipmentID;
    /** @type {string} */
    EquipmentName;
    /** @type {number} */
    EquipmentTypeID;
    /** @type {string} */
    Manufacturer;
    /** @type {string} */
    EquipmentType;
    /** @type {string} */
    SerialNumber;
    /** @type {string} */
    BarCode;
    /** @type {string} */
    EquipmentLocation;
    /** @type {string} */
    ImageURL;
    /** @type {string} */
    ProductDetailsURL;
    /** @type {string} */
    RecordCreatedDate;
    /** @type {string} */
    CreatedByUID;
    /** @type {boolean} */
    Active;
    /** @type {string} */
    Notes;
    /** @type {number} */
    Rate;
    /** @type {Project[]} */
    Projects = [];
}
export class ProjectEquipment extends Equipment {
    /** @param {{ProjectEquipmentID?:number,ProjectID?:number,ProjectEndDate?:string,EquipmentRate?:number,JobID?:number,BilledEquipmentRate?:number,Status?:string,EquipmentID?:number,EquipmentName?:string,EquipmentTypeID?:number,Manufacturer?:string,EquipmentType?:string,SerialNumber?:string,BarCode?:string,EquipmentLocation?:string,ImageURL?:string,ProductDetailsURL?:string,RecordCreatedDate?:string,CreatedByUID?:string,Active?:boolean,Notes?:string,Rate?:number,Projects?:Project[]}} [init] */
    constructor(init) { super(init); Object.assign(this, init) }
    /** @type {number} */
    ProjectEquipmentID;
    /** @type {number} */
    ProjectID;
    /** @type {string} */
    ProjectEndDate;
    /** @type {number} */
    EquipmentRate;
    /** @type {number} */
    JobID;
    /** @type {number} */
    BilledEquipmentRate;
    /** @type {string} */
    Status;
}
export class ProjectEquipmentListResponse {
    /** @param {{ResponseStatus?:ResponseStatus,ProjectEquipment?:ProjectEquipment[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {ResponseStatus} */
    ResponseStatus;
    /** @type {ProjectEquipment[]} */
    ProjectEquipment = [];
}
export class ProjectEquipmentListRequest {
    /** @param {{ProjectID?:number,JobID?:number,ProjectEquipment?:Equipment[]}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    ProjectID;
    /** @type {number} */
    JobID;
    /** @type {Equipment[]} */
    ProjectEquipment = [];
}

JavaScript ProjectEquipmentListRequest 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/Project/Equipment/{ProjectID} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	ProjectID: 0,
	JobID: 0,
	ProjectEquipment: 
	[
		{
			EquipmentID: 0,
			EquipmentName: String,
			EquipmentTypeID: 0,
			Manufacturer: String,
			EquipmentType: String,
			SerialNumber: String,
			BarCode: String,
			EquipmentLocation: String,
			ImageURL: String,
			ProductDetailsURL: String,
			RecordCreatedDate: 0001-01-01,
			CreatedByUID: 00000000000000000000000000000000,
			Active: False,
			Notes: String,
			Rate: 0,
			Projects: 
			[
				{
					ProjectID: 0,
					ProjectUID: 00000000000000000000000000000000,
					ProjectName: String,
					ImageURL: String,
					ImageKey: String,
					ClientName: String,
					ClientPhone: String,
					ClientEmail: String,
					ProjectManagerID: 0,
					ProjectManagerName: String,
					StartDate: 0001-01-01,
					EndDate: 0001-01-01,
					ActualStartDate: 0001-01-01,
					ActualEndDate: 0001-01-01,
					JobCount: 0,
					CrewMemberCount: 0,
					EquipmentCount: 0,
					MaterialCount: 0,
					ProjectStatusID: 0,
					ProjectStatusDescription: String,
					Budget: 0,
					CostToDate: 0,
					ProjectLocation: String,
					ProjectType: String,
					ProjectSponsor: String,
					CreatedBy: String,
					CreatedAt: 0001-01-01,
					UpdatedAt: 0001-01-01,
					ProjectDescription: String,
					Scope: String,
					StatusId: 0
				}
			]
		}
	]
}
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
		}
	},
	ProjectEquipment: 
	[
		{
			ProjectEquipmentID: 0,
			ProjectID: 0,
			ProjectEndDate: 0001-01-01,
			EquipmentRate: 0,
			JobID: 0,
			BilledEquipmentRate: 0,
			Status: String,
			EquipmentID: 0,
			EquipmentName: String,
			EquipmentTypeID: 0,
			Manufacturer: String,
			EquipmentType: String,
			SerialNumber: String,
			BarCode: String,
			EquipmentLocation: String,
			ImageURL: String,
			ProductDetailsURL: String,
			RecordCreatedDate: 0001-01-01,
			CreatedByUID: 00000000000000000000000000000000,
			Active: False,
			Notes: String,
			Rate: 0,
			Projects: 
			[
				{
					ProjectID: 0,
					ProjectUID: 00000000000000000000000000000000,
					ProjectName: String,
					ImageURL: String,
					ImageKey: String,
					ClientName: String,
					ClientPhone: String,
					ClientEmail: String,
					ProjectManagerID: 0,
					ProjectManagerName: String,
					StartDate: 0001-01-01,
					EndDate: 0001-01-01,
					ActualStartDate: 0001-01-01,
					ActualEndDate: 0001-01-01,
					JobCount: 0,
					CrewMemberCount: 0,
					EquipmentCount: 0,
					MaterialCount: 0,
					ProjectStatusID: 0,
					ProjectStatusDescription: String,
					Budget: 0,
					CostToDate: 0,
					ProjectLocation: String,
					ProjectType: String,
					ProjectSponsor: String,
					CreatedBy: String,
					CreatedAt: 0001-01-01,
					UpdatedAt: 0001-01-01,
					ProjectDescription: String,
					Scope: String,
					StatusId: 0
				}
			]
		}
	]
}