POST | /v1/VehicleWithOptimal | Get Vehicle by Vin and a more optimal option if available |
---|
import java.math.*
import java.util.*
import java.io.InputStream
import net.servicestack.client.*
open class GetVehicleWithOptimalRequest
{
open var VehicleIdentifier:String? = null
open var IncludeAllocatedToBackOrder:Boolean? = null
open var Gssn:String? = null
open var IsOneAdmin:Boolean? = null
open var MotabilityPricingId:Int? = null
}
open class GetVehicleWithOptimalResponse : GetVehicleResponse()
{
open var OptimumVehicle:VehicleDetailDto? = null
}
open class GetVehicleResponse
{
open var Vehicle:VehicleDetailDto? = null
open var Errors:ArrayList<VehicleError> = ArrayList<VehicleError>()
}
open class VehicleDetailDto
{
open var BodyStyle:String? = null
open var Vin:String? = null
open var Description:String? = null
open var Colour:String? = null
open var ColourCode:String? = null
open var ColourDescription:String? = null
open var ColourGroup:String? = null
open var Model:String? = null
open var CommissionNumber:String? = null
open var BrandId:Int? = null
open var Brand:Brand? = null
open var Engine:Engine? = null
open var EngineBadge:String? = null
open var Media:Media? = null
open var Line:String? = null
open var UpholsteryCode:String? = null
open var UpholsteryType:String? = null
open var Upholstery:String? = null
open var UpholsteryDescription:String? = null
open var AvailablePackages:ArrayList<String> = ArrayList<String>()
open var Packages:ArrayList<String> = ArrayList<String>()
open var P11D:BigDecimal? = null
open var PortArrivalDate:Date? = null
open var Prices:ArrayList<Price> = ArrayList<Price>()
open var TransmissionType:String? = null
open var FuelType:String? = null
open var VehicleClass:String? = null
open var ProductRange:String? = null
open var VehicleType:String? = null
open var Emission:BigDecimal? = null
open var IsAvailableOnline:Boolean? = null
open var UnderOffer:Boolean? = null
open var IsExcluded:Boolean? = null
open var IsSellable:Boolean? = null
open var OnHold:Boolean? = null
open var ElectricConsumption:BigDecimal? = null
open var ElectricRange:BigDecimal? = null
open var ImageUrl:String? = null
open var Baumuster:String? = null
open var Retailer:Retailer? = null
open var Bm7NST:String? = null
open var OTR:BigDecimal? = null
open var ActualPrice:BigDecimal? = null
open var IsDisplayStock:Boolean? = null
open var DisplayRetailerId:Int? = null
open var DisplayRetailer:String? = null
open var DisplayRetailerGssnId:String? = null
open var DisplayRetailerMarketAreaId:String? = null
open var IsSmartDisplayRetailer:Boolean? = null
open var IsSpecialistCar:Boolean? = null
open var Age:Int? = null
open var Secured:Boolean? = null
open var IsHOBackOrderAccountVehicle:Boolean? = null
open var IsAllocatedToBackOrder:Boolean? = null
open var UsageCode:String? = null
open var EmissionCombined:BigDecimal? = null
open var NormalisedEmissionDirective:String? = null
open var HasMildHybridEquipmentCode:Boolean? = null
open var RetailPriceExVat:BigDecimal? = null
open var RetailPrice_IncVAT:BigDecimal? = null
open var RetailPrice_ExVAT:BigDecimal? = null
open var ModelId:Int? = null
open var VID:String? = null
open var ProductionDate:String? = null
open var FullModelYearCode:String? = null
open var ChassisNumber:String? = null
open var EligibleForIntegratedServiceCare:Boolean? = null
open var AccountType:String? = null
open var ConsumptionCombined:VehicleConsumption? = null
open var ConsumptionExtraUrban:VehicleConsumption? = null
open var ConsumptionUrban:VehicleConsumption? = null
open var WltpFuelConsumptionCombined:VehicleConsumption? = null
open var WltpFuelConsumptionExtraHigh:VehicleConsumption? = null
open var WltpFuelConsumptionHigh:VehicleConsumption? = null
open var WltpFuelConsumptionLow:VehicleConsumption? = null
open var WltpFuelConsumptionMedium:VehicleConsumption? = null
open var Equipment:ArrayList<Equipmentv2>? = null
open var EquipmentCategories:ArrayList<VehicleEquipmentCategory>? = null
open var EnergyEfficiencyClass:VehicleEmissionClass? = null
open var VehicleData:ArrayList<VehicleAttribute>? = null
open var IntegratedServiceCareOptions:ArrayList<VehicleIntegratedServiceCareOption> = ArrayList<VehicleIntegratedServiceCareOption>()
open var IspVehicleCustomerDescriptions:ArrayList<String>? = null
}
open class Brand
{
open var Id:Int? = null
open var Description:String? = null
open var DisplayName:String? = null
open var BodyStyles:ArrayList<BodyStyle>? = null
}
open class BodyStyle
{
open var Id:Int? = null
open var Description:String? = null
open var Models:ArrayList<Model>? = null
}
open class Model
{
open var Id:Int? = null
open var Description:String? = null
open var DisplayName:String? = null
open var ImageUrlSmall:String? = null
open var ImageUrlMedium:String? = null
open var ImageUrlLarge:String? = null
open var Specialist:Boolean? = null
open var Priority:Int? = null
open var ExcludeFromOnlineShowroomFilters:Boolean? = null
}
open class Engine
{
open var Id:Int? = null
open var Badge:String? = null
}
open class Media
{
open var NoImage:Boolean? = null
open var MainImageUrl:String? = null
}
open class Price
{
open var Id:String? = null
open var Description:String? = null
open var Net:BigDecimal? = null
open var VAT:BigDecimal? = null
open var Gross:BigDecimal? = null
open var Product:OfferPriceProductType? = null
}
enum class OfferPriceProductType
{
ListPrice,
NumberPlateFee,
DeliveryCharge,
FuelCharge,
ManufacturerOffer,
PersonalisedMoneyoffer,
PersonalisedNonmoneyoffer,
PersonalisedNonmoneyofferNeg,
Service,
ServiceNeg,
GovernmentGrant,
OutrightPurchaseDiscount,
VipOffer,
WallboxOffer,
WallboxOfferNeg,
RoadFundLicence,
FirstRegistrationFee,
NotFound,
AccessoryOffer,
AccessoryOfferNeg,
MotabilityDiscount,
}
open class Retailer
{
open var Id:Int? = null
open var GssnId:String? = null
open var Description:String? = null
open var Street:String? = null
open var City:String? = null
open var Postcode:String? = null
open var GoogleMapPostcode:String? = null
open var Phone:String? = null
open var Fax:String? = null
open var Email:String? = null
open var Website:String? = null
open var RetailerGroupId:String? = null
open var RetailerGroupName:String? = null
open var IsOnline:Boolean? = null
open var IsNewCarRetailer:Boolean? = null
open var IsUsedCarRetailer:Boolean? = null
open var IsCentralRetailer:Boolean? = null
open var ChatEnabled:Boolean? = null
open var TradeInEnabled:Boolean? = null
open var smart:Boolean? = null
open var DisplayPhoneNumberNew:String? = null
open var DisplayPhoneNumberUsed:String? = null
open var Latitude:BigDecimal? = null
open var Longitude:BigDecimal? = null
open var smartDescription:String? = null
open var smartWebsite:String? = null
open var smartPhone:String? = null
open var LegacyId:String? = null
open var Agent:Boolean? = null
open var MarketAreaId:Int? = null
open var DigitalLoungeParentGssnId:String? = null
open var SendLeadsToDigitalLoungeParent:Boolean? = null
open var OpeningTimes:RetailerOpeningTimes? = null
}
open class RetailerOpeningTimes
{
open var New:ArrayList<RetailerOpeningTime> = ArrayList<RetailerOpeningTime>()
open var Used:ArrayList<RetailerOpeningTime> = ArrayList<RetailerOpeningTime>()
}
open class RetailerOpeningTime
{
open var Day:String? = null
open var OpenFrom:String? = null
open var OpenTo:String? = null
open var Special:String? = null
}
open class VehicleConsumption
{
open var Id:Int? = null
open var Lkm:BigDecimal? = null
open var Mpg:BigDecimal? = null
}
open class Equipmentv2 : Equipment()
{
open var Importance:Int? = null
open var IsAdditional:Boolean? = null
}
open class Equipment
{
open var Id:Int? = null
open var Code:String? = null
open var Description:String? = null
}
open class VehicleEquipmentCategory
{
open var Order:Int? = null
open var Code:String? = null
open var Description:String? = null
open var Equipment:ArrayList<Equipmentv2>? = null
}
open class VehicleEmissionClass
{
open var Colour:String? = null
open var Rating:String? = null
}
open class VehicleAttribute
{
open var Description:String? = null
open var Value:String? = null
}
open class VehicleIntegratedServiceCareOption
{
open var OptionCode:String? = null
open var BM7NST:String? = null
open var FullModelYear:String? = null
open var IntegratedProductType:String? = null
open var CustomerDescription:String? = null
open var OneAgentProductType:String? = null
}
open class VehicleError
{
open var Field:String? = null
open var Message:String? = null
}
Kotlin GetVehicleWithOptimalRequest 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.
POST /v1/VehicleWithOptimal HTTP/1.1
Host: prod-api-agency-orch-mb-dhc.rapp-customers.co.uk
Accept: application/json
Content-Type: application/json
Content-Length: length
{"VehicleIdentifier":"String","IncludeAllocatedToBackOrder":false,"Gssn":"String","IsOneAdmin":false,"MotabilityPricingId":0}
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"OptimumVehicle":{"BodyStyle":"String","Vin":"String","Description":"String","Colour":"String","ColourCode":"String","ColourDescription":"String","ColourGroup":"String","Model":"String","CommissionNumber":"String","BrandId":0,"Brand":{"Id":0,"Description":"String","DisplayName":"String","BodyStyles":[{"Id":0,"Description":"String","Models":[{"Id":0,"Description":"String","DisplayName":"String","ImageUrlSmall":"String","ImageUrlMedium":"String","ImageUrlLarge":"String","Specialist":false,"Priority":0,"ExcludeFromOnlineShowroomFilters":false}]}]},"Engine":{"Id":0,"Badge":"String"},"EngineBadge":"String","Media":{"NoImage":false,"MainImageUrl":"String"},"Line":"String","UpholsteryCode":"String","UpholsteryType":"String","Upholstery":"String","UpholsteryDescription":"String","AvailablePackages":["String"],"Packages":["String"],"P11D":0,"PortArrivalDate":"\/Date(-62135596800000-0000)\/","Prices":[{"Id":"String","Description":"String","Net":0,"VAT":0,"Gross":0,"Product":"LIST_PRICE"}],"TransmissionType":"String","FuelType":"String","VehicleClass":"String","ProductRange":"String","VehicleType":"String","Emission":0,"IsAvailableOnline":false,"UnderOffer":false,"IsExcluded":false,"IsSellable":false,"OnHold":false,"ElectricConsumption":0,"ElectricRange":0,"ImageUrl":"String","Baumuster":"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"}]}},"Bm7NST":"String","OTR":0,"ActualPrice":0,"IsDisplayStock":false,"DisplayRetailerId":0,"DisplayRetailer":"String","DisplayRetailerGssnId":"String","DisplayRetailerMarketAreaId":"String","IsSmartDisplayRetailer":false,"IsSpecialistCar":false,"Age":0,"Secured":false,"IsHOBackOrderAccountVehicle":false,"IsAllocatedToBackOrder":false,"UsageCode":"String","EmissionCombined":0,"NormalisedEmissionDirective":"String","HasMildHybridEquipmentCode":false,"RetailPriceExVat":0,"RetailPrice_IncVAT":0,"RetailPrice_ExVAT":0,"ModelId":0,"VID":"String","ProductionDate":"String","FullModelYearCode":"String","ChassisNumber":"String","EligibleForIntegratedServiceCare":false,"AccountType":"String","ConsumptionCombined":{"Id":0,"Lkm":0,"Mpg":0},"ConsumptionExtraUrban":{"Id":0,"Lkm":0,"Mpg":0},"ConsumptionUrban":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionCombined":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionExtraHigh":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionHigh":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionLow":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionMedium":{"Id":0,"Lkm":0,"Mpg":0},"Equipment":[{"Importance":0,"IsAdditional":false,"Id":0,"Code":"String","Description":"String"}],"EquipmentCategories":[{"Order":0,"Code":"String","Description":"String","Equipment":[{"Importance":0,"IsAdditional":false,"Id":0,"Code":"String","Description":"String"}]}],"EnergyEfficiencyClass":{"Colour":"String","Rating":"String"},"VehicleData":[{"Description":"String","Value":"String"}],"IntegratedServiceCareOptions":[{"OptionCode":"String","BM7NST":"String","FullModelYear":"String","IntegratedProductType":"String","CustomerDescription":"String","OneAgentProductType":"String"}],"IspVehicleCustomerDescriptions":["String"]},"Vehicle":{"BodyStyle":"String","Vin":"String","Description":"String","Colour":"String","ColourCode":"String","ColourDescription":"String","ColourGroup":"String","Model":"String","CommissionNumber":"String","BrandId":0,"Brand":{"Id":0,"Description":"String","DisplayName":"String","BodyStyles":[{"Id":0,"Description":"String","Models":[{"Id":0,"Description":"String","DisplayName":"String","ImageUrlSmall":"String","ImageUrlMedium":"String","ImageUrlLarge":"String","Specialist":false,"Priority":0,"ExcludeFromOnlineShowroomFilters":false}]}]},"Engine":{"Id":0,"Badge":"String"},"EngineBadge":"String","Media":{"NoImage":false,"MainImageUrl":"String"},"Line":"String","UpholsteryCode":"String","UpholsteryType":"String","Upholstery":"String","UpholsteryDescription":"String","AvailablePackages":["String"],"Packages":["String"],"P11D":0,"PortArrivalDate":"\/Date(-62135596800000-0000)\/","Prices":[{"Id":"String","Description":"String","Net":0,"VAT":0,"Gross":0,"Product":"LIST_PRICE"}],"TransmissionType":"String","FuelType":"String","VehicleClass":"String","ProductRange":"String","VehicleType":"String","Emission":0,"IsAvailableOnline":false,"UnderOffer":false,"IsExcluded":false,"IsSellable":false,"OnHold":false,"ElectricConsumption":0,"ElectricRange":0,"ImageUrl":"String","Baumuster":"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"}]}},"Bm7NST":"String","OTR":0,"ActualPrice":0,"IsDisplayStock":false,"DisplayRetailerId":0,"DisplayRetailer":"String","DisplayRetailerGssnId":"String","DisplayRetailerMarketAreaId":"String","IsSmartDisplayRetailer":false,"IsSpecialistCar":false,"Age":0,"Secured":false,"IsHOBackOrderAccountVehicle":false,"IsAllocatedToBackOrder":false,"UsageCode":"String","EmissionCombined":0,"NormalisedEmissionDirective":"String","HasMildHybridEquipmentCode":false,"RetailPriceExVat":0,"RetailPrice_IncVAT":0,"RetailPrice_ExVAT":0,"ModelId":0,"VID":"String","ProductionDate":"String","FullModelYearCode":"String","ChassisNumber":"String","EligibleForIntegratedServiceCare":false,"AccountType":"String","ConsumptionCombined":{"Id":0,"Lkm":0,"Mpg":0},"ConsumptionExtraUrban":{"Id":0,"Lkm":0,"Mpg":0},"ConsumptionUrban":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionCombined":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionExtraHigh":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionHigh":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionLow":{"Id":0,"Lkm":0,"Mpg":0},"WltpFuelConsumptionMedium":{"Id":0,"Lkm":0,"Mpg":0},"Equipment":[{"Importance":0,"IsAdditional":false,"Id":0,"Code":"String","Description":"String"}],"EquipmentCategories":[{"Order":0,"Code":"String","Description":"String","Equipment":[{"Importance":0,"IsAdditional":false,"Id":0,"Code":"String","Description":"String"}]}],"EnergyEfficiencyClass":{"Colour":"String","Rating":"String"},"VehicleData":[{"Description":"String","Value":"String"}],"IntegratedServiceCareOptions":[{"OptionCode":"String","BM7NST":"String","FullModelYear":"String","IntegratedProductType":"String","CustomerDescription":"String","OneAgentProductType":"String"}],"IspVehicleCustomerDescriptions":["String"]},"Errors":[{"Field":"String","Message":"String"}]}