GET | /v1/order/customer/{CustomerId} | Get Order by Customer |
---|
"use strict";
export class Order {
/** @param {{Guid?:string,Reference?:string,Status?:number,CustomerId?:string,MulesoftReference?:string,GasId?:string,OrderDate?:string,OfferSnapShot?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Guid;
/** @type {string} */
Reference;
/** @type {number} */
Status;
/** @type {string} */
CustomerId;
/** @type {string} */
MulesoftReference;
/** @type {string} */
GasId;
/** @type {string} */
OrderDate;
/** @type {string} */
OfferSnapShot;
}
export class OrderStatus {
/** @param {{Id?:number,Description?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
Id;
/** @type {string} */
Description;
}
export class OnlineShowroomStatus {
/** @param {{Id?:number,Description?:string,Slug?:string,Current?:boolean,Completed?:boolean,OrderStatuses?:OrderStatus[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
Id;
/** @type {string} */
Description;
/** @type {string} */
Slug;
/** @type {boolean} */
Current;
/** @type {boolean} */
Completed;
/** @type {OrderStatus[]} */
OrderStatuses = [];
}
export class RetailerOpeningTime {
/** @param {{Day?:string,OpenFrom?:string,OpenTo?:string,Special?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Day;
/** @type {string} */
OpenFrom;
/** @type {string} */
OpenTo;
/** @type {string} */
Special;
}
export class RetailerOpeningTimes {
/** @param {{New?:RetailerOpeningTime[],Used?:RetailerOpeningTime[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {RetailerOpeningTime[]} */
New = [];
/** @type {RetailerOpeningTime[]} */
Used = [];
}
export class Retailer {
/** @param {{Id?:number,GssnId?:string,Description?:string,Street?:string,City?:string,Postcode?:string,GoogleMapPostcode?:string,Phone?:string,Fax?:string,Email?:string,Website?:string,RetailerGroupId?:string,RetailerGroupName?:string,IsOnline?:boolean,IsNewCarRetailer?:boolean,IsUsedCarRetailer?:boolean,IsCentralRetailer?:boolean,ChatEnabled?:boolean,TradeInEnabled?:boolean,smart?:boolean,DisplayPhoneNumberNew?:string,DisplayPhoneNumberUsed?:string,Latitude?:number,Longitude?:number,smartDescription?:string,smartWebsite?:string,smartPhone?:string,LegacyId?:string,Agent?:boolean,MarketAreaId?:number,DigitalLoungeParentGssnId?:string,SendLeadsToDigitalLoungeParent?:boolean,OpeningTimes?:RetailerOpeningTimes}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
Id;
/** @type {string} */
GssnId;
/** @type {string} */
Description;
/** @type {string} */
Street;
/** @type {string} */
City;
/** @type {string} */
Postcode;
/** @type {string} */
GoogleMapPostcode;
/** @type {string} */
Phone;
/** @type {string} */
Fax;
/** @type {string} */
Email;
/** @type {string} */
Website;
/** @type {string} */
RetailerGroupId;
/** @type {string} */
RetailerGroupName;
/** @type {boolean} */
IsOnline;
/** @type {boolean} */
IsNewCarRetailer;
/** @type {boolean} */
IsUsedCarRetailer;
/** @type {boolean} */
IsCentralRetailer;
/** @type {boolean} */
ChatEnabled;
/** @type {boolean} */
TradeInEnabled;
/** @type {boolean} */
smart;
/** @type {string} */
DisplayPhoneNumberNew;
/** @type {string} */
DisplayPhoneNumberUsed;
/** @type {number} */
Latitude;
/** @type {number} */
Longitude;
/** @type {string} */
smartDescription;
/** @type {string} */
smartWebsite;
/** @type {string} */
smartPhone;
/** @type {string} */
LegacyId;
/** @type {boolean} */
Agent;
/** @type {number} */
MarketAreaId;
/** @type {?string} */
DigitalLoungeParentGssnId;
/** @type {boolean} */
SendLeadsToDigitalLoungeParent;
/** @type {?RetailerOpeningTimes} */
OpeningTimes;
}
export class OnlineShowroomVehicle {
/** @param {{Vin?:string,VehicleClass?:string,TransmissionType?:string,FuelType?:string,ImageUrl?:string,Colour?:string,Description?:string,BodyStyle?:string,UpholsteryType?:string,Retailer?:Retailer,OTR?:number,ActualPrice?:number,TotalOfferValue?:number,NetPrice?:number,VehicleType?:string,OfferExpiryDate?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Vin;
/** @type {string} */
VehicleClass;
/** @type {string} */
TransmissionType;
/** @type {string} */
FuelType;
/** @type {string} */
ImageUrl;
/** @type {string} */
Colour;
/** @type {string} */
Description;
/** @type {string} */
BodyStyle;
/** @type {string} */
UpholsteryType;
/** @type {Retailer} */
Retailer;
/** @type {number} */
OTR;
/** @type {number} */
ActualPrice;
/** @type {number} */
TotalOfferValue;
/** @type {number} */
NetPrice;
/** @type {string} */
VehicleType;
/** @type {?string} */
OfferExpiryDate;
}
export class PaymentDetail {
/** @param {{PaymentType?:string,PaymentLink?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
PaymentType;
/** @type {string} */
PaymentLink;
}
export class OnlineShowroomOrder {
/** @param {{Guid?:string,Reference?:string,Status?:OnlineShowroomStatus[],Vehicle?:OnlineShowroomVehicle,ClosedDate?:string,CustomerId?:string,HandoverDate?:string,ClosedReason?:string,OrderDate?:string,PaymentLinks?:PaymentDetail[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Guid;
/** @type {string} */
Reference;
/** @type {OnlineShowroomStatus[]} */
Status = [];
/** @type {OnlineShowroomVehicle} */
Vehicle;
/** @type {string} */
ClosedDate;
/** @type {string} */
CustomerId;
/** @type {string} */
HandoverDate;
/** @type {string} */
ClosedReason;
/** @type {string} */
OrderDate;
/** @type {PaymentDetail[]} */
PaymentLinks = [];
}
export class GetOrderCustomerResponse {
/** @param {{Orders?:Order[],Completed?:OnlineShowroomOrder[],Cancelled?:OnlineShowroomOrder[],InProgress?:OnlineShowroomOrder[],Archived?:OnlineShowroomOrder[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {Order[]} */
Orders = [];
/** @type {OnlineShowroomOrder[]} */
Completed = [];
/** @type {OnlineShowroomOrder[]} */
Cancelled = [];
/** @type {OnlineShowroomOrder[]} */
InProgress = [];
/** @type {OnlineShowroomOrder[]} */
Archived = [];
}
export class GetOrderCustomerRequest {
/** @param {{CustomerId?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
CustomerId;
}
JavaScript GetOrderCustomerRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/order/customer/{CustomerId} HTTP/1.1 Host: prod-api-agency-orch-mb-dhc.rapp-customers.co.uk Accept: application/json
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"Orders":[{"Guid":"00000000000000000000000000000000","Reference":"String","Status":0,"CustomerId":"String","MulesoftReference":"String","GasId":"String","OrderDate":"String","OfferSnapShot":"String"}],"Completed":[{"Guid":"00000000000000000000000000000000","Reference":"String","Status":[{"Id":0,"Description":"String","Slug":"String","Current":false,"Completed":false,"OrderStatuses":[{"Id":0,"Description":"String"}]}],"Vehicle":{"Vin":"String","VehicleClass":"String","TransmissionType":"String","FuelType":"String","ImageUrl":"String","Colour":"String","Description":"String","BodyStyle":"String","UpholsteryType":"String","Retailer":{"Id":0,"GssnId":"String","Description":"String","Street":"String","City":"String","Postcode":"String","GoogleMapPostcode":"String","Phone":"String","Fax":"String","Email":"String","Website":"String","RetailerGroupId":"String","RetailerGroupName":"String","IsOnline":false,"IsNewCarRetailer":false,"IsUsedCarRetailer":false,"IsCentralRetailer":false,"ChatEnabled":false,"TradeInEnabled":false,"smart":false,"DisplayPhoneNumberNew":"String","DisplayPhoneNumberUsed":"String","Latitude":0,"Longitude":0,"smartDescription":"String","smartWebsite":"String","smartPhone":"String","LegacyId":"String","Agent":false,"MarketAreaId":0,"DigitalLoungeParentGssnId":"String","SendLeadsToDigitalLoungeParent":false,"OpeningTimes":{"New":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}],"Used":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}]}},"OTR":0,"ActualPrice":0,"TotalOfferValue":0,"NetPrice":0,"VehicleType":"String","OfferExpiryDate":"String"},"ClosedDate":"String","CustomerId":"String","HandoverDate":"String","ClosedReason":"String","OrderDate":"String","PaymentLinks":[{"PaymentType":"String","PaymentLink":"String"}]}],"Cancelled":[{"Guid":"00000000000000000000000000000000","Reference":"String","Status":[{"Id":0,"Description":"String","Slug":"String","Current":false,"Completed":false,"OrderStatuses":[{"Id":0,"Description":"String"}]}],"Vehicle":{"Vin":"String","VehicleClass":"String","TransmissionType":"String","FuelType":"String","ImageUrl":"String","Colour":"String","Description":"String","BodyStyle":"String","UpholsteryType":"String","Retailer":{"Id":0,"GssnId":"String","Description":"String","Street":"String","City":"String","Postcode":"String","GoogleMapPostcode":"String","Phone":"String","Fax":"String","Email":"String","Website":"String","RetailerGroupId":"String","RetailerGroupName":"String","IsOnline":false,"IsNewCarRetailer":false,"IsUsedCarRetailer":false,"IsCentralRetailer":false,"ChatEnabled":false,"TradeInEnabled":false,"smart":false,"DisplayPhoneNumberNew":"String","DisplayPhoneNumberUsed":"String","Latitude":0,"Longitude":0,"smartDescription":"String","smartWebsite":"String","smartPhone":"String","LegacyId":"String","Agent":false,"MarketAreaId":0,"DigitalLoungeParentGssnId":"String","SendLeadsToDigitalLoungeParent":false,"OpeningTimes":{"New":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}],"Used":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}]}},"OTR":0,"ActualPrice":0,"TotalOfferValue":0,"NetPrice":0,"VehicleType":"String","OfferExpiryDate":"String"},"ClosedDate":"String","CustomerId":"String","HandoverDate":"String","ClosedReason":"String","OrderDate":"String","PaymentLinks":[{"PaymentType":"String","PaymentLink":"String"}]}],"InProgress":[{"Guid":"00000000000000000000000000000000","Reference":"String","Status":[{"Id":0,"Description":"String","Slug":"String","Current":false,"Completed":false,"OrderStatuses":[{"Id":0,"Description":"String"}]}],"Vehicle":{"Vin":"String","VehicleClass":"String","TransmissionType":"String","FuelType":"String","ImageUrl":"String","Colour":"String","Description":"String","BodyStyle":"String","UpholsteryType":"String","Retailer":{"Id":0,"GssnId":"String","Description":"String","Street":"String","City":"String","Postcode":"String","GoogleMapPostcode":"String","Phone":"String","Fax":"String","Email":"String","Website":"String","RetailerGroupId":"String","RetailerGroupName":"String","IsOnline":false,"IsNewCarRetailer":false,"IsUsedCarRetailer":false,"IsCentralRetailer":false,"ChatEnabled":false,"TradeInEnabled":false,"smart":false,"DisplayPhoneNumberNew":"String","DisplayPhoneNumberUsed":"String","Latitude":0,"Longitude":0,"smartDescription":"String","smartWebsite":"String","smartPhone":"String","LegacyId":"String","Agent":false,"MarketAreaId":0,"DigitalLoungeParentGssnId":"String","SendLeadsToDigitalLoungeParent":false,"OpeningTimes":{"New":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}],"Used":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}]}},"OTR":0,"ActualPrice":0,"TotalOfferValue":0,"NetPrice":0,"VehicleType":"String","OfferExpiryDate":"String"},"ClosedDate":"String","CustomerId":"String","HandoverDate":"String","ClosedReason":"String","OrderDate":"String","PaymentLinks":[{"PaymentType":"String","PaymentLink":"String"}]}],"Archived":[{"Guid":"00000000000000000000000000000000","Reference":"String","Status":[{"Id":0,"Description":"String","Slug":"String","Current":false,"Completed":false,"OrderStatuses":[{"Id":0,"Description":"String"}]}],"Vehicle":{"Vin":"String","VehicleClass":"String","TransmissionType":"String","FuelType":"String","ImageUrl":"String","Colour":"String","Description":"String","BodyStyle":"String","UpholsteryType":"String","Retailer":{"Id":0,"GssnId":"String","Description":"String","Street":"String","City":"String","Postcode":"String","GoogleMapPostcode":"String","Phone":"String","Fax":"String","Email":"String","Website":"String","RetailerGroupId":"String","RetailerGroupName":"String","IsOnline":false,"IsNewCarRetailer":false,"IsUsedCarRetailer":false,"IsCentralRetailer":false,"ChatEnabled":false,"TradeInEnabled":false,"smart":false,"DisplayPhoneNumberNew":"String","DisplayPhoneNumberUsed":"String","Latitude":0,"Longitude":0,"smartDescription":"String","smartWebsite":"String","smartPhone":"String","LegacyId":"String","Agent":false,"MarketAreaId":0,"DigitalLoungeParentGssnId":"String","SendLeadsToDigitalLoungeParent":false,"OpeningTimes":{"New":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}],"Used":[{"Day":"String","OpenFrom":"String","OpenTo":"String","Special":"String"}]}},"OTR":0,"ActualPrice":0,"TotalOfferValue":0,"NetPrice":0,"VehicleType":"String","OfferExpiryDate":"String"},"ClosedDate":"String","CustomerId":"String","HandoverDate":"String","ClosedReason":"String","OrderDate":"String","PaymentLinks":[{"PaymentType":"String","PaymentLink":"String"}]}]}