GET | /v1/order/customer/{CustomerId} | Get Order by Customer |
---|
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;
public class dtos
{
public static class GetOrderCustomerRequest implements IGet
{
public String CustomerId = null;
public String getCustomerId() { return CustomerId; }
public GetOrderCustomerRequest setCustomerId(String value) { this.CustomerId = value; return this; }
}
public static class GetOrderCustomerResponse
{
public ArrayList<Order> Orders = new ArrayList<Order>();
public ArrayList<OnlineShowroomOrder> Completed = new ArrayList<OnlineShowroomOrder>();
public ArrayList<OnlineShowroomOrder> Cancelled = new ArrayList<OnlineShowroomOrder>();
public ArrayList<OnlineShowroomOrder> InProgress = new ArrayList<OnlineShowroomOrder>();
public ArrayList<OnlineShowroomOrder> Archived = new ArrayList<OnlineShowroomOrder>();
public ArrayList<Order> getOrders() { return Orders; }
public GetOrderCustomerResponse setOrders(ArrayList<Order> value) { this.Orders = value; return this; }
public ArrayList<OnlineShowroomOrder> getCompleted() { return Completed; }
public GetOrderCustomerResponse setCompleted(ArrayList<OnlineShowroomOrder> value) { this.Completed = value; return this; }
public ArrayList<OnlineShowroomOrder> getCancelled() { return Cancelled; }
public GetOrderCustomerResponse setCancelled(ArrayList<OnlineShowroomOrder> value) { this.Cancelled = value; return this; }
public ArrayList<OnlineShowroomOrder> getInProgress() { return InProgress; }
public GetOrderCustomerResponse setInProgress(ArrayList<OnlineShowroomOrder> value) { this.InProgress = value; return this; }
public ArrayList<OnlineShowroomOrder> getArchived() { return Archived; }
public GetOrderCustomerResponse setArchived(ArrayList<OnlineShowroomOrder> value) { this.Archived = value; return this; }
}
public static class Order
{
public UUID Guid = null;
public String Reference = null;
public Integer Status = null;
public String CustomerId = null;
public String MulesoftReference = null;
public String GasId = null;
public String OrderDate = null;
public String OfferSnapShot = null;
public UUID getGuid() { return Guid; }
public Order setGuid(UUID value) { this.Guid = value; return this; }
public String getReference() { return Reference; }
public Order setReference(String value) { this.Reference = value; return this; }
public Integer getStatus() { return Status; }
public Order setStatus(Integer value) { this.Status = value; return this; }
public String getCustomerId() { return CustomerId; }
public Order setCustomerId(String value) { this.CustomerId = value; return this; }
public String getMulesoftReference() { return MulesoftReference; }
public Order setMulesoftReference(String value) { this.MulesoftReference = value; return this; }
public String getGasId() { return GasId; }
public Order setGasId(String value) { this.GasId = value; return this; }
public String getOrderDate() { return OrderDate; }
public Order setOrderDate(String value) { this.OrderDate = value; return this; }
public String getOfferSnapShot() { return OfferSnapShot; }
public Order setOfferSnapShot(String value) { this.OfferSnapShot = value; return this; }
}
public static class OnlineShowroomOrder
{
public UUID Guid = null;
public String Reference = null;
public ArrayList<OnlineShowroomStatus> Status = new ArrayList<OnlineShowroomStatus>();
public OnlineShowroomVehicle Vehicle = null;
public String ClosedDate = null;
public String CustomerId = null;
public String HandoverDate = null;
public String ClosedReason = null;
public String OrderDate = null;
public ArrayList<PaymentDetail> PaymentLinks = new ArrayList<PaymentDetail>();
public UUID getGuid() { return Guid; }
public OnlineShowroomOrder setGuid(UUID value) { this.Guid = value; return this; }
public String getReference() { return Reference; }
public OnlineShowroomOrder setReference(String value) { this.Reference = value; return this; }
public ArrayList<OnlineShowroomStatus> getStatus() { return Status; }
public OnlineShowroomOrder setStatus(ArrayList<OnlineShowroomStatus> value) { this.Status = value; return this; }
public OnlineShowroomVehicle getVehicle() { return Vehicle; }
public OnlineShowroomOrder setVehicle(OnlineShowroomVehicle value) { this.Vehicle = value; return this; }
public String getClosedDate() { return ClosedDate; }
public OnlineShowroomOrder setClosedDate(String value) { this.ClosedDate = value; return this; }
public String getCustomerId() { return CustomerId; }
public OnlineShowroomOrder setCustomerId(String value) { this.CustomerId = value; return this; }
public String getHandoverDate() { return HandoverDate; }
public OnlineShowroomOrder setHandoverDate(String value) { this.HandoverDate = value; return this; }
public String getClosedReason() { return ClosedReason; }
public OnlineShowroomOrder setClosedReason(String value) { this.ClosedReason = value; return this; }
public String getOrderDate() { return OrderDate; }
public OnlineShowroomOrder setOrderDate(String value) { this.OrderDate = value; return this; }
public ArrayList<PaymentDetail> getPaymentLinks() { return PaymentLinks; }
public OnlineShowroomOrder setPaymentLinks(ArrayList<PaymentDetail> value) { this.PaymentLinks = value; return this; }
}
public static class OnlineShowroomStatus
{
public Integer Id = null;
public String Description = null;
public String Slug = null;
public Boolean Current = null;
public Boolean Completed = null;
public ArrayList<OrderStatus> OrderStatuses = new ArrayList<OrderStatus>();
public Integer getId() { return Id; }
public OnlineShowroomStatus setId(Integer value) { this.Id = value; return this; }
public String getDescription() { return Description; }
public OnlineShowroomStatus setDescription(String value) { this.Description = value; return this; }
public String getSlug() { return Slug; }
public OnlineShowroomStatus setSlug(String value) { this.Slug = value; return this; }
public Boolean isCurrent() { return Current; }
public OnlineShowroomStatus setCurrent(Boolean value) { this.Current = value; return this; }
public Boolean isCompleted() { return Completed; }
public OnlineShowroomStatus setCompleted(Boolean value) { this.Completed = value; return this; }
public ArrayList<OrderStatus> getOrderStatuses() { return OrderStatuses; }
public OnlineShowroomStatus setOrderStatuses(ArrayList<OrderStatus> value) { this.OrderStatuses = value; return this; }
}
public static class OrderStatus
{
public Integer Id = null;
public String Description = null;
public Integer getId() { return Id; }
public OrderStatus setId(Integer value) { this.Id = value; return this; }
public String getDescription() { return Description; }
public OrderStatus setDescription(String value) { this.Description = value; return this; }
}
public static class OnlineShowroomVehicle
{
public String Vin = null;
public String VehicleClass = null;
public String TransmissionType = null;
public String FuelType = null;
public String ImageUrl = null;
public String Colour = null;
public String Description = null;
public String BodyStyle = null;
public String UpholsteryType = null;
public Retailer Retailer = null;
public BigDecimal OTR = null;
public BigDecimal ActualPrice = null;
public BigDecimal TotalOfferValue = null;
public BigDecimal NetPrice = null;
public String VehicleType = null;
public String OfferExpiryDate = null;
public String getVin() { return Vin; }
public OnlineShowroomVehicle setVin(String value) { this.Vin = value; return this; }
public String getVehicleClass() { return VehicleClass; }
public OnlineShowroomVehicle setVehicleClass(String value) { this.VehicleClass = value; return this; }
public String getTransmissionType() { return TransmissionType; }
public OnlineShowroomVehicle setTransmissionType(String value) { this.TransmissionType = value; return this; }
public String getFuelType() { return FuelType; }
public OnlineShowroomVehicle setFuelType(String value) { this.FuelType = value; return this; }
public String getImageUrl() { return ImageUrl; }
public OnlineShowroomVehicle setImageUrl(String value) { this.ImageUrl = value; return this; }
public String getColour() { return Colour; }
public OnlineShowroomVehicle setColour(String value) { this.Colour = value; return this; }
public String getDescription() { return Description; }
public OnlineShowroomVehicle setDescription(String value) { this.Description = value; return this; }
public String getBodyStyle() { return BodyStyle; }
public OnlineShowroomVehicle setBodyStyle(String value) { this.BodyStyle = value; return this; }
public String getUpholsteryType() { return UpholsteryType; }
public OnlineShowroomVehicle setUpholsteryType(String value) { this.UpholsteryType = value; return this; }
public Retailer getRetailer() { return Retailer; }
public OnlineShowroomVehicle setRetailer(Retailer value) { this.Retailer = value; return this; }
public BigDecimal getOtr() { return OTR; }
public OnlineShowroomVehicle setOtr(BigDecimal value) { this.OTR = value; return this; }
public BigDecimal getActualPrice() { return ActualPrice; }
public OnlineShowroomVehicle setActualPrice(BigDecimal value) { this.ActualPrice = value; return this; }
public BigDecimal getTotalOfferValue() { return TotalOfferValue; }
public OnlineShowroomVehicle setTotalOfferValue(BigDecimal value) { this.TotalOfferValue = value; return this; }
public BigDecimal getNetPrice() { return NetPrice; }
public OnlineShowroomVehicle setNetPrice(BigDecimal value) { this.NetPrice = value; return this; }
public String getVehicleType() { return VehicleType; }
public OnlineShowroomVehicle setVehicleType(String value) { this.VehicleType = value; return this; }
public String getOfferExpiryDate() { return OfferExpiryDate; }
public OnlineShowroomVehicle setOfferExpiryDate(String value) { this.OfferExpiryDate = value; return this; }
}
public static class Retailer
{
public Integer Id = null;
public String GssnId = null;
public String Description = null;
public String Street = null;
public String City = null;
public String Postcode = null;
public String GoogleMapPostcode = null;
public String Phone = null;
public String Fax = null;
public String Email = null;
public String Website = null;
public String RetailerGroupId = null;
public String RetailerGroupName = null;
public Boolean IsOnline = null;
public Boolean IsNewCarRetailer = null;
public Boolean IsUsedCarRetailer = null;
public Boolean IsCentralRetailer = null;
public Boolean ChatEnabled = null;
public Boolean TradeInEnabled = null;
public Boolean smart = null;
public String DisplayPhoneNumberNew = null;
public String DisplayPhoneNumberUsed = null;
public BigDecimal Latitude = null;
public BigDecimal Longitude = null;
public String smartDescription = null;
public String smartWebsite = null;
public String smartPhone = null;
public String LegacyId = null;
public Boolean Agent = null;
public Integer MarketAreaId = null;
public String DigitalLoungeParentGssnId = null;
public Boolean SendLeadsToDigitalLoungeParent = null;
public RetailerOpeningTimes OpeningTimes = null;
public Integer getId() { return Id; }
public Retailer setId(Integer value) { this.Id = value; return this; }
public String getGssnId() { return GssnId; }
public Retailer setGssnId(String value) { this.GssnId = value; return this; }
public String getDescription() { return Description; }
public Retailer setDescription(String value) { this.Description = value; return this; }
public String getStreet() { return Street; }
public Retailer setStreet(String value) { this.Street = value; return this; }
public String getCity() { return City; }
public Retailer setCity(String value) { this.City = value; return this; }
public String getPostcode() { return Postcode; }
public Retailer setPostcode(String value) { this.Postcode = value; return this; }
public String getGoogleMapPostcode() { return GoogleMapPostcode; }
public Retailer setGoogleMapPostcode(String value) { this.GoogleMapPostcode = value; return this; }
public String getPhone() { return Phone; }
public Retailer setPhone(String value) { this.Phone = value; return this; }
public String getFax() { return Fax; }
public Retailer setFax(String value) { this.Fax = value; return this; }
public String getEmail() { return Email; }
public Retailer setEmail(String value) { this.Email = value; return this; }
public String getWebsite() { return Website; }
public Retailer setWebsite(String value) { this.Website = value; return this; }
public String getRetailerGroupId() { return RetailerGroupId; }
public Retailer setRetailerGroupId(String value) { this.RetailerGroupId = value; return this; }
public String getRetailerGroupName() { return RetailerGroupName; }
public Retailer setRetailerGroupName(String value) { this.RetailerGroupName = value; return this; }
public Boolean getIsOnline() { return IsOnline; }
public Retailer setIsOnline(Boolean value) { this.IsOnline = value; return this; }
public Boolean getIsNewCarRetailer() { return IsNewCarRetailer; }
public Retailer setIsNewCarRetailer(Boolean value) { this.IsNewCarRetailer = value; return this; }
public Boolean getIsUsedCarRetailer() { return IsUsedCarRetailer; }
public Retailer setIsUsedCarRetailer(Boolean value) { this.IsUsedCarRetailer = value; return this; }
public Boolean getIsCentralRetailer() { return IsCentralRetailer; }
public Retailer setIsCentralRetailer(Boolean value) { this.IsCentralRetailer = value; return this; }
public Boolean isChatEnabled() { return ChatEnabled; }
public Retailer setChatEnabled(Boolean value) { this.ChatEnabled = value; return this; }
public Boolean isTradeInEnabled() { return TradeInEnabled; }
public Retailer setTradeInEnabled(Boolean value) { this.TradeInEnabled = value; return this; }
public Boolean isSmart() { return smart; }
public Retailer setSmart(Boolean value) { this.smart = value; return this; }
public String getDisplayPhoneNumberNew() { return DisplayPhoneNumberNew; }
public Retailer setDisplayPhoneNumberNew(String value) { this.DisplayPhoneNumberNew = value; return this; }
public String getDisplayPhoneNumberUsed() { return DisplayPhoneNumberUsed; }
public Retailer setDisplayPhoneNumberUsed(String value) { this.DisplayPhoneNumberUsed = value; return this; }
public BigDecimal getLatitude() { return Latitude; }
public Retailer setLatitude(BigDecimal value) { this.Latitude = value; return this; }
public BigDecimal getLongitude() { return Longitude; }
public Retailer setLongitude(BigDecimal value) { this.Longitude = value; return this; }
public String getSmartDescription() { return smartDescription; }
public Retailer setSmartDescription(String value) { this.smartDescription = value; return this; }
public String getSmartWebsite() { return smartWebsite; }
public Retailer setSmartWebsite(String value) { this.smartWebsite = value; return this; }
public String getSmartPhone() { return smartPhone; }
public Retailer setSmartPhone(String value) { this.smartPhone = value; return this; }
public String getLegacyId() { return LegacyId; }
public Retailer setLegacyId(String value) { this.LegacyId = value; return this; }
public Boolean isAgent() { return Agent; }
public Retailer setAgent(Boolean value) { this.Agent = value; return this; }
public Integer getMarketAreaId() { return MarketAreaId; }
public Retailer setMarketAreaId(Integer value) { this.MarketAreaId = value; return this; }
public String getDigitalLoungeParentGssnId() { return DigitalLoungeParentGssnId; }
public Retailer setDigitalLoungeParentGssnId(String value) { this.DigitalLoungeParentGssnId = value; return this; }
public Boolean isSendLeadsToDigitalLoungeParent() { return SendLeadsToDigitalLoungeParent; }
public Retailer setSendLeadsToDigitalLoungeParent(Boolean value) { this.SendLeadsToDigitalLoungeParent = value; return this; }
public RetailerOpeningTimes getOpeningTimes() { return OpeningTimes; }
public Retailer setOpeningTimes(RetailerOpeningTimes value) { this.OpeningTimes = value; return this; }
}
public static class RetailerOpeningTimes
{
public ArrayList<RetailerOpeningTime> New = new ArrayList<RetailerOpeningTime>();
public ArrayList<RetailerOpeningTime> Used = new ArrayList<RetailerOpeningTime>();
public ArrayList<RetailerOpeningTime> getNew() { return New; }
public RetailerOpeningTimes setNew(ArrayList<RetailerOpeningTime> value) { this.New = value; return this; }
public ArrayList<RetailerOpeningTime> getUsed() { return Used; }
public RetailerOpeningTimes setUsed(ArrayList<RetailerOpeningTime> value) { this.Used = value; return this; }
}
public static class RetailerOpeningTime
{
public String Day = null;
public String OpenFrom = null;
public String OpenTo = null;
public String Special = null;
public String getDay() { return Day; }
public RetailerOpeningTime setDay(String value) { this.Day = value; return this; }
public String getOpenFrom() { return OpenFrom; }
public RetailerOpeningTime setOpenFrom(String value) { this.OpenFrom = value; return this; }
public String getOpenTo() { return OpenTo; }
public RetailerOpeningTime setOpenTo(String value) { this.OpenTo = value; return this; }
public String getSpecial() { return Special; }
public RetailerOpeningTime setSpecial(String value) { this.Special = value; return this; }
}
public static class PaymentDetail
{
public String PaymentType = null;
public String PaymentLink = null;
public String getPaymentType() { return PaymentType; }
public PaymentDetail setPaymentType(String value) { this.PaymentType = value; return this; }
public String getPaymentLink() { return PaymentLink; }
public PaymentDetail setPaymentLink(String value) { this.PaymentLink = value; return this; }
}
}
Java GetOrderCustomerRequest 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/order/customer/{CustomerId} HTTP/1.1 Host: prod-api-agency-orch-mb-dhc.rapp-customers.co.uk Accept: text/jsv
HTTP/1.1 200 OK Content-Type: text/jsv 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 } ] } ] }