Mercedes.VehicleManagement.API

<back to all web services

CentralVehiclesRequest

Vehicle
Requires Authentication
The following routes are available for this service:
GET/v1/{VehicleType}/Vehicle/CentralGet central vehicle data
<?php namespace dtos;

use DateTime;
use Exception;
use DateInterval;
use JsonSerializable;
use ServiceStack\{IReturn,IReturnVoid,IGet,IPost,IPut,IDelete,IPatch,IMeta,IHasSessionId,IHasBearerToken,IHasVersion};
use ServiceStack\{ICrud,ICreateDb,IUpdateDb,IPatchDb,IDeleteDb,ISaveDb,AuditBase,QueryDb,QueryDb2,QueryData,QueryData2,QueryResponse};
use ServiceStack\{ResponseStatus,ResponseError,EmptyResponse,IdResponse,ArrayList,KeyValuePair2,StringResponse,StringsResponse,Tuple2,Tuple3,ByteArray};
use ServiceStack\{JsonConverters,Returns,TypeContext};


class VehicleDataBase implements JsonSerializable
{
    public function __construct(
        /** @var string */
        public string $vin='',
        /** @var string */
        public string $description='',
        /** @var string */
        public string $model='',
        /** @var string */
        public string $otr='',
        /** @var string */
        public string $retailPriceExVAT='',
        /** @var string */
        public string $actualPrice='',
        /** @var string */
        public string $fuelType='',
        /** @var string */
        public string $transmission='',
        /** @var string */
        public string $transmissionType='',
        /** @var string */
        public string $colour='',
        /** @var string */
        public string $colourCode='',
        /** @var string */
        public string $colourDescription='',
        /** @var string */
        public string $commissionNumber='',
        /** @var bool|null */
        public ?bool $offerAvailable=null,
        /** @var int */
        public int $campaignDiscountOfferTotal=0,
        /** @var int */
        public int $campaignDiscountOfferTotalCurrent=0,
        /** @var int */
        public int $campaignDiscountOfferTotalPending=0,
        /** @var int */
        public int $campaignServiceOfferTotal=0,
        /** @var int */
        public int $campaignServiceOfferTotalCurrent=0,
        /** @var int */
        public int $campaignServiceOfferTotalPending=0,
        /** @var int */
        public int $campaignCustomOfferTotal=0,
        /** @var int */
        public int $campaignPersonalisedOfferTotalCurrent=0,
        /** @var int */
        public int $campaignPersonalisedOfferTotalPending=0,
        /** @var int */
        public int $campaignPersonalisedOfferTotal=0,
        /** @var int */
        public int $campaignCustomOfferTotalCurrent=0,
        /** @var int */
        public int $campaignCustomOfferTotalPending=0,
        /** @var int */
        public int $campaignOtherOfferTotal=0,
        /** @var int */
        public int $campaignOtherOfferTotalCurrent=0,
        /** @var int */
        public int $campaignOtherOfferTotalPending=0,
        /** @var int */
        public int $retailerDiscountOfferTotal=0,
        /** @var int */
        public int $retailerDiscountOfferTotalCurrent=0,
        /** @var int */
        public int $retailerDiscountOfferTotalPending=0,
        /** @var int */
        public int $retailerServiceOfferTotal=0,
        /** @var int */
        public int $retailerServiceOfferTotalCurrent=0,
        /** @var int */
        public int $retailerServiceOfferTotalPending=0,
        /** @var int */
        public int $retailerCustomOfferTotal=0,
        /** @var int */
        public int $retailerCustomOfferTotalCurrent=0,
        /** @var int */
        public int $retailerCustomOfferTotalPending=0,
        /** @var int */
        public int $retailerWarrantyOfferTotal=0,
        /** @var int */
        public int $retailerWarrantyOfferTotalCurrent=0,
        /** @var int */
        public int $retailerWarrantyOfferTotalPending=0,
        /** @var int */
        public int $retailerOfferTotal=0,
        /** @var int */
        public int $retailerOfferTotalCurrent=0,
        /** @var int */
        public int $retailerOfferTotalPending=0,
        /** @var int */
        public int $campaignOfferTotal=0,
        /** @var int */
        public int $campaignOfferTotalCurrent=0,
        /** @var int */
        public int $campaignOfferTotalPending=0,
        /** @var int */
        public int $campaignAndOfferTotal=0,
        /** @var int */
        public int $campaignAndOfferTotalCurrent=0,
        /** @var int */
        public int $campaignAndOfferTotalPending=0,
        /** @var int */
        public int $offerTotal=0,
        /** @var int */
        public int $offerTotalCurrent=0,
        /** @var int */
        public int $offerTotalPending=0,
        /** @var string */
        public string $creation='',
        /** @var string */
        public string $modified='',
        /** @var int */
        public int $electricRange=0,
        /** @var int */
        public int $electricConsumption=0,
        /** @var DateTime|null */
        public ?DateTime $portArrivalDate=null,
        /** @var int|null */
        public ?int $daysSincePortArrival=null,
        /** @var float */
        public float $retailPriceIncVAT=0.0,
        /** @var string */
        public string $bodyStyle='',
        /** @var string */
        public string $upholstery='',
        /** @var string */
        public string $upholsteryCode='',
        /** @var string */
        public string $upholsteryType='',
        /** @var array<string>|null */
        public ?array $packageNames=null,
        /** @var string */
        public string $line='',
        /** @var float */
        public float $currentRetailerOfferPrice=0.0,
        /** @var string */
        public string $retailPrice='',
        /** @var bool|null */
        public ?bool $vatQualifying=null,
        /** @var int */
        public int $retailerId=0,
        /** @var string */
        public string $gssnId='',
        /** @var bool|null */
        public ?bool $noImage=null,
        /** @var string */
        public string $imageUrl='',
        /** @var bool|null */
        public ?bool $isAvailableOnline=null,
        /** @var bool|null */
        public ?bool $isBackOrdered=null,
        /** @var string */
        public string $creationDate='',
        /** @var string */
        public string $maintenanceDate='',
        /** @var string */
        public string $registrationNumber='',
        /** @var DateTime|null */
        public ?DateTime $registrationDate=null,
        /** @var int|null */
        public ?int $mileage=null,
        /** @var DateTime|null */
        public ?DateTime $tradeInDate=null,
        /** @var string */
        public string $source='',
        /** @var string */
        public string $vehicleType='',
        /** @var string */
        public string $offerAmount='',
        /** @var string */
        public string $offerExpiry='',
        /** @var int[] */
        public array $activeOffers=[],
        /** @var int */
        public int $campaignMessagesTotal=0,
        /** @var bool|null */
        public ?bool $underOffer=null,
        /** @var bool|null */
        public ?bool $isDisplayStock=null,
        /** @var string */
        public string $displayRetailer='',
        /** @var string */
        public string $displayRetailerGssnId='',
        /** @var string */
        public string $location='',
        /** @var string */
        public string $account='',
        /** @var string */
        public string $accountType='',
        /** @var string */
        public string $usageCode='',
        /** @var string */
        public string $bm7NST='',
        /** @var bool|null */
        public ?bool $isSellable=null,
        /** @var bool|null */
        public ?bool $secured=null,
        /** @var bool|null */
        public ?bool $specialist=null,
        /** @var bool|null */
        public ?bool $isMotabilityRetailer=null,
        /** @var string */
        public string $upholsteryDescription='',
        /** @var bool|null */
        public ?bool $inBackOrderAccount=null,
        /** @var string|null */
        public ?string $fullModelYearCode=null,
        /** @var DateTime|null */
        public ?DateTime $productionDate=null,
        /** @var string */
        public string $baumuster='',
        /** @var bool|null */
        public ?bool $isMotability=null,
        /** @var float|null */
        public ?float $pipAdvanceRentalGross=null,
        /** @var float|null */
        public ?float $wpmsAdvanceRentalGross=null,
        /** @var array<string>|null */
        public ?array $ispVehicleCustomerDescriptions=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['vin'])) $this->vin = $o['vin'];
        if (isset($o['description'])) $this->description = $o['description'];
        if (isset($o['model'])) $this->model = $o['model'];
        if (isset($o['otr'])) $this->otr = $o['otr'];
        if (isset($o['retailPriceExVAT'])) $this->retailPriceExVAT = $o['retailPriceExVAT'];
        if (isset($o['actualPrice'])) $this->actualPrice = $o['actualPrice'];
        if (isset($o['fuelType'])) $this->fuelType = $o['fuelType'];
        if (isset($o['transmission'])) $this->transmission = $o['transmission'];
        if (isset($o['transmissionType'])) $this->transmissionType = $o['transmissionType'];
        if (isset($o['colour'])) $this->colour = $o['colour'];
        if (isset($o['colourCode'])) $this->colourCode = $o['colourCode'];
        if (isset($o['colourDescription'])) $this->colourDescription = $o['colourDescription'];
        if (isset($o['commissionNumber'])) $this->commissionNumber = $o['commissionNumber'];
        if (isset($o['offerAvailable'])) $this->offerAvailable = $o['offerAvailable'];
        if (isset($o['campaignDiscountOfferTotal'])) $this->campaignDiscountOfferTotal = $o['campaignDiscountOfferTotal'];
        if (isset($o['campaignDiscountOfferTotalCurrent'])) $this->campaignDiscountOfferTotalCurrent = $o['campaignDiscountOfferTotalCurrent'];
        if (isset($o['campaignDiscountOfferTotalPending'])) $this->campaignDiscountOfferTotalPending = $o['campaignDiscountOfferTotalPending'];
        if (isset($o['campaignServiceOfferTotal'])) $this->campaignServiceOfferTotal = $o['campaignServiceOfferTotal'];
        if (isset($o['campaignServiceOfferTotalCurrent'])) $this->campaignServiceOfferTotalCurrent = $o['campaignServiceOfferTotalCurrent'];
        if (isset($o['campaignServiceOfferTotalPending'])) $this->campaignServiceOfferTotalPending = $o['campaignServiceOfferTotalPending'];
        if (isset($o['campaignCustomOfferTotal'])) $this->campaignCustomOfferTotal = $o['campaignCustomOfferTotal'];
        if (isset($o['campaignPersonalisedOfferTotalCurrent'])) $this->campaignPersonalisedOfferTotalCurrent = $o['campaignPersonalisedOfferTotalCurrent'];
        if (isset($o['campaignPersonalisedOfferTotalPending'])) $this->campaignPersonalisedOfferTotalPending = $o['campaignPersonalisedOfferTotalPending'];
        if (isset($o['campaignPersonalisedOfferTotal'])) $this->campaignPersonalisedOfferTotal = $o['campaignPersonalisedOfferTotal'];
        if (isset($o['campaignCustomOfferTotalCurrent'])) $this->campaignCustomOfferTotalCurrent = $o['campaignCustomOfferTotalCurrent'];
        if (isset($o['campaignCustomOfferTotalPending'])) $this->campaignCustomOfferTotalPending = $o['campaignCustomOfferTotalPending'];
        if (isset($o['campaignOtherOfferTotal'])) $this->campaignOtherOfferTotal = $o['campaignOtherOfferTotal'];
        if (isset($o['campaignOtherOfferTotalCurrent'])) $this->campaignOtherOfferTotalCurrent = $o['campaignOtherOfferTotalCurrent'];
        if (isset($o['campaignOtherOfferTotalPending'])) $this->campaignOtherOfferTotalPending = $o['campaignOtherOfferTotalPending'];
        if (isset($o['retailerDiscountOfferTotal'])) $this->retailerDiscountOfferTotal = $o['retailerDiscountOfferTotal'];
        if (isset($o['retailerDiscountOfferTotalCurrent'])) $this->retailerDiscountOfferTotalCurrent = $o['retailerDiscountOfferTotalCurrent'];
        if (isset($o['retailerDiscountOfferTotalPending'])) $this->retailerDiscountOfferTotalPending = $o['retailerDiscountOfferTotalPending'];
        if (isset($o['retailerServiceOfferTotal'])) $this->retailerServiceOfferTotal = $o['retailerServiceOfferTotal'];
        if (isset($o['retailerServiceOfferTotalCurrent'])) $this->retailerServiceOfferTotalCurrent = $o['retailerServiceOfferTotalCurrent'];
        if (isset($o['retailerServiceOfferTotalPending'])) $this->retailerServiceOfferTotalPending = $o['retailerServiceOfferTotalPending'];
        if (isset($o['retailerCustomOfferTotal'])) $this->retailerCustomOfferTotal = $o['retailerCustomOfferTotal'];
        if (isset($o['retailerCustomOfferTotalCurrent'])) $this->retailerCustomOfferTotalCurrent = $o['retailerCustomOfferTotalCurrent'];
        if (isset($o['retailerCustomOfferTotalPending'])) $this->retailerCustomOfferTotalPending = $o['retailerCustomOfferTotalPending'];
        if (isset($o['retailerWarrantyOfferTotal'])) $this->retailerWarrantyOfferTotal = $o['retailerWarrantyOfferTotal'];
        if (isset($o['retailerWarrantyOfferTotalCurrent'])) $this->retailerWarrantyOfferTotalCurrent = $o['retailerWarrantyOfferTotalCurrent'];
        if (isset($o['retailerWarrantyOfferTotalPending'])) $this->retailerWarrantyOfferTotalPending = $o['retailerWarrantyOfferTotalPending'];
        if (isset($o['retailerOfferTotal'])) $this->retailerOfferTotal = $o['retailerOfferTotal'];
        if (isset($o['retailerOfferTotalCurrent'])) $this->retailerOfferTotalCurrent = $o['retailerOfferTotalCurrent'];
        if (isset($o['retailerOfferTotalPending'])) $this->retailerOfferTotalPending = $o['retailerOfferTotalPending'];
        if (isset($o['campaignOfferTotal'])) $this->campaignOfferTotal = $o['campaignOfferTotal'];
        if (isset($o['campaignOfferTotalCurrent'])) $this->campaignOfferTotalCurrent = $o['campaignOfferTotalCurrent'];
        if (isset($o['campaignOfferTotalPending'])) $this->campaignOfferTotalPending = $o['campaignOfferTotalPending'];
        if (isset($o['campaignAndOfferTotal'])) $this->campaignAndOfferTotal = $o['campaignAndOfferTotal'];
        if (isset($o['campaignAndOfferTotalCurrent'])) $this->campaignAndOfferTotalCurrent = $o['campaignAndOfferTotalCurrent'];
        if (isset($o['campaignAndOfferTotalPending'])) $this->campaignAndOfferTotalPending = $o['campaignAndOfferTotalPending'];
        if (isset($o['offerTotal'])) $this->offerTotal = $o['offerTotal'];
        if (isset($o['offerTotalCurrent'])) $this->offerTotalCurrent = $o['offerTotalCurrent'];
        if (isset($o['offerTotalPending'])) $this->offerTotalPending = $o['offerTotalPending'];
        if (isset($o['creation'])) $this->creation = $o['creation'];
        if (isset($o['modified'])) $this->modified = $o['modified'];
        if (isset($o['electricRange'])) $this->electricRange = $o['electricRange'];
        if (isset($o['electricConsumption'])) $this->electricConsumption = $o['electricConsumption'];
        if (isset($o['portArrivalDate'])) $this->portArrivalDate = JsonConverters::from('DateTime', $o['portArrivalDate']);
        if (isset($o['daysSincePortArrival'])) $this->daysSincePortArrival = $o['daysSincePortArrival'];
        if (isset($o['retailPriceIncVAT'])) $this->retailPriceIncVAT = $o['retailPriceIncVAT'];
        if (isset($o['bodyStyle'])) $this->bodyStyle = $o['bodyStyle'];
        if (isset($o['upholstery'])) $this->upholstery = $o['upholstery'];
        if (isset($o['upholsteryCode'])) $this->upholsteryCode = $o['upholsteryCode'];
        if (isset($o['upholsteryType'])) $this->upholsteryType = $o['upholsteryType'];
        if (isset($o['packageNames'])) $this->packageNames = JsonConverters::fromArray('string', $o['packageNames']);
        if (isset($o['line'])) $this->line = $o['line'];
        if (isset($o['currentRetailerOfferPrice'])) $this->currentRetailerOfferPrice = $o['currentRetailerOfferPrice'];
        if (isset($o['retailPrice'])) $this->retailPrice = $o['retailPrice'];
        if (isset($o['vatQualifying'])) $this->vatQualifying = $o['vatQualifying'];
        if (isset($o['retailerId'])) $this->retailerId = $o['retailerId'];
        if (isset($o['gssnId'])) $this->gssnId = $o['gssnId'];
        if (isset($o['noImage'])) $this->noImage = $o['noImage'];
        if (isset($o['imageUrl'])) $this->imageUrl = $o['imageUrl'];
        if (isset($o['isAvailableOnline'])) $this->isAvailableOnline = $o['isAvailableOnline'];
        if (isset($o['isBackOrdered'])) $this->isBackOrdered = $o['isBackOrdered'];
        if (isset($o['creationDate'])) $this->creationDate = $o['creationDate'];
        if (isset($o['maintenanceDate'])) $this->maintenanceDate = $o['maintenanceDate'];
        if (isset($o['registrationNumber'])) $this->registrationNumber = $o['registrationNumber'];
        if (isset($o['registrationDate'])) $this->registrationDate = JsonConverters::from('DateTime', $o['registrationDate']);
        if (isset($o['mileage'])) $this->mileage = $o['mileage'];
        if (isset($o['tradeInDate'])) $this->tradeInDate = JsonConverters::from('DateTime', $o['tradeInDate']);
        if (isset($o['source'])) $this->source = $o['source'];
        if (isset($o['vehicleType'])) $this->vehicleType = $o['vehicleType'];
        if (isset($o['offerAmount'])) $this->offerAmount = $o['offerAmount'];
        if (isset($o['offerExpiry'])) $this->offerExpiry = $o['offerExpiry'];
        if (isset($o['activeOffers'])) $this->activeOffers = JsonConverters::fromArray('int', $o['activeOffers']);
        if (isset($o['campaignMessagesTotal'])) $this->campaignMessagesTotal = $o['campaignMessagesTotal'];
        if (isset($o['underOffer'])) $this->underOffer = $o['underOffer'];
        if (isset($o['isDisplayStock'])) $this->isDisplayStock = $o['isDisplayStock'];
        if (isset($o['displayRetailer'])) $this->displayRetailer = $o['displayRetailer'];
        if (isset($o['displayRetailerGssnId'])) $this->displayRetailerGssnId = $o['displayRetailerGssnId'];
        if (isset($o['location'])) $this->location = $o['location'];
        if (isset($o['account'])) $this->account = $o['account'];
        if (isset($o['accountType'])) $this->accountType = $o['accountType'];
        if (isset($o['usageCode'])) $this->usageCode = $o['usageCode'];
        if (isset($o['bm7NST'])) $this->bm7NST = $o['bm7NST'];
        if (isset($o['isSellable'])) $this->isSellable = $o['isSellable'];
        if (isset($o['secured'])) $this->secured = $o['secured'];
        if (isset($o['specialist'])) $this->specialist = $o['specialist'];
        if (isset($o['isMotabilityRetailer'])) $this->isMotabilityRetailer = $o['isMotabilityRetailer'];
        if (isset($o['upholsteryDescription'])) $this->upholsteryDescription = $o['upholsteryDescription'];
        if (isset($o['inBackOrderAccount'])) $this->inBackOrderAccount = $o['inBackOrderAccount'];
        if (isset($o['fullModelYearCode'])) $this->fullModelYearCode = $o['fullModelYearCode'];
        if (isset($o['productionDate'])) $this->productionDate = JsonConverters::from('DateTime', $o['productionDate']);
        if (isset($o['baumuster'])) $this->baumuster = $o['baumuster'];
        if (isset($o['isMotability'])) $this->isMotability = $o['isMotability'];
        if (isset($o['pipAdvanceRentalGross'])) $this->pipAdvanceRentalGross = $o['pipAdvanceRentalGross'];
        if (isset($o['wpmsAdvanceRentalGross'])) $this->wpmsAdvanceRentalGross = $o['wpmsAdvanceRentalGross'];
        if (isset($o['ispVehicleCustomerDescriptions'])) $this->ispVehicleCustomerDescriptions = JsonConverters::fromArray('string', $o['ispVehicleCustomerDescriptions']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->vin)) $o['vin'] = $this->vin;
        if (isset($this->description)) $o['description'] = $this->description;
        if (isset($this->model)) $o['model'] = $this->model;
        if (isset($this->otr)) $o['otr'] = $this->otr;
        if (isset($this->retailPriceExVAT)) $o['retailPriceExVAT'] = $this->retailPriceExVAT;
        if (isset($this->actualPrice)) $o['actualPrice'] = $this->actualPrice;
        if (isset($this->fuelType)) $o['fuelType'] = $this->fuelType;
        if (isset($this->transmission)) $o['transmission'] = $this->transmission;
        if (isset($this->transmissionType)) $o['transmissionType'] = $this->transmissionType;
        if (isset($this->colour)) $o['colour'] = $this->colour;
        if (isset($this->colourCode)) $o['colourCode'] = $this->colourCode;
        if (isset($this->colourDescription)) $o['colourDescription'] = $this->colourDescription;
        if (isset($this->commissionNumber)) $o['commissionNumber'] = $this->commissionNumber;
        if (isset($this->offerAvailable)) $o['offerAvailable'] = $this->offerAvailable;
        if (isset($this->campaignDiscountOfferTotal)) $o['campaignDiscountOfferTotal'] = $this->campaignDiscountOfferTotal;
        if (isset($this->campaignDiscountOfferTotalCurrent)) $o['campaignDiscountOfferTotalCurrent'] = $this->campaignDiscountOfferTotalCurrent;
        if (isset($this->campaignDiscountOfferTotalPending)) $o['campaignDiscountOfferTotalPending'] = $this->campaignDiscountOfferTotalPending;
        if (isset($this->campaignServiceOfferTotal)) $o['campaignServiceOfferTotal'] = $this->campaignServiceOfferTotal;
        if (isset($this->campaignServiceOfferTotalCurrent)) $o['campaignServiceOfferTotalCurrent'] = $this->campaignServiceOfferTotalCurrent;
        if (isset($this->campaignServiceOfferTotalPending)) $o['campaignServiceOfferTotalPending'] = $this->campaignServiceOfferTotalPending;
        if (isset($this->campaignCustomOfferTotal)) $o['campaignCustomOfferTotal'] = $this->campaignCustomOfferTotal;
        if (isset($this->campaignPersonalisedOfferTotalCurrent)) $o['campaignPersonalisedOfferTotalCurrent'] = $this->campaignPersonalisedOfferTotalCurrent;
        if (isset($this->campaignPersonalisedOfferTotalPending)) $o['campaignPersonalisedOfferTotalPending'] = $this->campaignPersonalisedOfferTotalPending;
        if (isset($this->campaignPersonalisedOfferTotal)) $o['campaignPersonalisedOfferTotal'] = $this->campaignPersonalisedOfferTotal;
        if (isset($this->campaignCustomOfferTotalCurrent)) $o['campaignCustomOfferTotalCurrent'] = $this->campaignCustomOfferTotalCurrent;
        if (isset($this->campaignCustomOfferTotalPending)) $o['campaignCustomOfferTotalPending'] = $this->campaignCustomOfferTotalPending;
        if (isset($this->campaignOtherOfferTotal)) $o['campaignOtherOfferTotal'] = $this->campaignOtherOfferTotal;
        if (isset($this->campaignOtherOfferTotalCurrent)) $o['campaignOtherOfferTotalCurrent'] = $this->campaignOtherOfferTotalCurrent;
        if (isset($this->campaignOtherOfferTotalPending)) $o['campaignOtherOfferTotalPending'] = $this->campaignOtherOfferTotalPending;
        if (isset($this->retailerDiscountOfferTotal)) $o['retailerDiscountOfferTotal'] = $this->retailerDiscountOfferTotal;
        if (isset($this->retailerDiscountOfferTotalCurrent)) $o['retailerDiscountOfferTotalCurrent'] = $this->retailerDiscountOfferTotalCurrent;
        if (isset($this->retailerDiscountOfferTotalPending)) $o['retailerDiscountOfferTotalPending'] = $this->retailerDiscountOfferTotalPending;
        if (isset($this->retailerServiceOfferTotal)) $o['retailerServiceOfferTotal'] = $this->retailerServiceOfferTotal;
        if (isset($this->retailerServiceOfferTotalCurrent)) $o['retailerServiceOfferTotalCurrent'] = $this->retailerServiceOfferTotalCurrent;
        if (isset($this->retailerServiceOfferTotalPending)) $o['retailerServiceOfferTotalPending'] = $this->retailerServiceOfferTotalPending;
        if (isset($this->retailerCustomOfferTotal)) $o['retailerCustomOfferTotal'] = $this->retailerCustomOfferTotal;
        if (isset($this->retailerCustomOfferTotalCurrent)) $o['retailerCustomOfferTotalCurrent'] = $this->retailerCustomOfferTotalCurrent;
        if (isset($this->retailerCustomOfferTotalPending)) $o['retailerCustomOfferTotalPending'] = $this->retailerCustomOfferTotalPending;
        if (isset($this->retailerWarrantyOfferTotal)) $o['retailerWarrantyOfferTotal'] = $this->retailerWarrantyOfferTotal;
        if (isset($this->retailerWarrantyOfferTotalCurrent)) $o['retailerWarrantyOfferTotalCurrent'] = $this->retailerWarrantyOfferTotalCurrent;
        if (isset($this->retailerWarrantyOfferTotalPending)) $o['retailerWarrantyOfferTotalPending'] = $this->retailerWarrantyOfferTotalPending;
        if (isset($this->retailerOfferTotal)) $o['retailerOfferTotal'] = $this->retailerOfferTotal;
        if (isset($this->retailerOfferTotalCurrent)) $o['retailerOfferTotalCurrent'] = $this->retailerOfferTotalCurrent;
        if (isset($this->retailerOfferTotalPending)) $o['retailerOfferTotalPending'] = $this->retailerOfferTotalPending;
        if (isset($this->campaignOfferTotal)) $o['campaignOfferTotal'] = $this->campaignOfferTotal;
        if (isset($this->campaignOfferTotalCurrent)) $o['campaignOfferTotalCurrent'] = $this->campaignOfferTotalCurrent;
        if (isset($this->campaignOfferTotalPending)) $o['campaignOfferTotalPending'] = $this->campaignOfferTotalPending;
        if (isset($this->campaignAndOfferTotal)) $o['campaignAndOfferTotal'] = $this->campaignAndOfferTotal;
        if (isset($this->campaignAndOfferTotalCurrent)) $o['campaignAndOfferTotalCurrent'] = $this->campaignAndOfferTotalCurrent;
        if (isset($this->campaignAndOfferTotalPending)) $o['campaignAndOfferTotalPending'] = $this->campaignAndOfferTotalPending;
        if (isset($this->offerTotal)) $o['offerTotal'] = $this->offerTotal;
        if (isset($this->offerTotalCurrent)) $o['offerTotalCurrent'] = $this->offerTotalCurrent;
        if (isset($this->offerTotalPending)) $o['offerTotalPending'] = $this->offerTotalPending;
        if (isset($this->creation)) $o['creation'] = $this->creation;
        if (isset($this->modified)) $o['modified'] = $this->modified;
        if (isset($this->electricRange)) $o['electricRange'] = $this->electricRange;
        if (isset($this->electricConsumption)) $o['electricConsumption'] = $this->electricConsumption;
        if (isset($this->portArrivalDate)) $o['portArrivalDate'] = JsonConverters::to('DateTime', $this->portArrivalDate);
        if (isset($this->daysSincePortArrival)) $o['daysSincePortArrival'] = $this->daysSincePortArrival;
        if (isset($this->retailPriceIncVAT)) $o['retailPriceIncVAT'] = $this->retailPriceIncVAT;
        if (isset($this->bodyStyle)) $o['bodyStyle'] = $this->bodyStyle;
        if (isset($this->upholstery)) $o['upholstery'] = $this->upholstery;
        if (isset($this->upholsteryCode)) $o['upholsteryCode'] = $this->upholsteryCode;
        if (isset($this->upholsteryType)) $o['upholsteryType'] = $this->upholsteryType;
        if (isset($this->packageNames)) $o['packageNames'] = JsonConverters::toArray('string', $this->packageNames);
        if (isset($this->line)) $o['line'] = $this->line;
        if (isset($this->currentRetailerOfferPrice)) $o['currentRetailerOfferPrice'] = $this->currentRetailerOfferPrice;
        if (isset($this->retailPrice)) $o['retailPrice'] = $this->retailPrice;
        if (isset($this->vatQualifying)) $o['vatQualifying'] = $this->vatQualifying;
        if (isset($this->retailerId)) $o['retailerId'] = $this->retailerId;
        if (isset($this->gssnId)) $o['gssnId'] = $this->gssnId;
        if (isset($this->noImage)) $o['noImage'] = $this->noImage;
        if (isset($this->imageUrl)) $o['imageUrl'] = $this->imageUrl;
        if (isset($this->isAvailableOnline)) $o['isAvailableOnline'] = $this->isAvailableOnline;
        if (isset($this->isBackOrdered)) $o['isBackOrdered'] = $this->isBackOrdered;
        if (isset($this->creationDate)) $o['creationDate'] = $this->creationDate;
        if (isset($this->maintenanceDate)) $o['maintenanceDate'] = $this->maintenanceDate;
        if (isset($this->registrationNumber)) $o['registrationNumber'] = $this->registrationNumber;
        if (isset($this->registrationDate)) $o['registrationDate'] = JsonConverters::to('DateTime', $this->registrationDate);
        if (isset($this->mileage)) $o['mileage'] = $this->mileage;
        if (isset($this->tradeInDate)) $o['tradeInDate'] = JsonConverters::to('DateTime', $this->tradeInDate);
        if (isset($this->source)) $o['source'] = $this->source;
        if (isset($this->vehicleType)) $o['vehicleType'] = $this->vehicleType;
        if (isset($this->offerAmount)) $o['offerAmount'] = $this->offerAmount;
        if (isset($this->offerExpiry)) $o['offerExpiry'] = $this->offerExpiry;
        if (isset($this->activeOffers)) $o['activeOffers'] = JsonConverters::toArray('int', $this->activeOffers);
        if (isset($this->campaignMessagesTotal)) $o['campaignMessagesTotal'] = $this->campaignMessagesTotal;
        if (isset($this->underOffer)) $o['underOffer'] = $this->underOffer;
        if (isset($this->isDisplayStock)) $o['isDisplayStock'] = $this->isDisplayStock;
        if (isset($this->displayRetailer)) $o['displayRetailer'] = $this->displayRetailer;
        if (isset($this->displayRetailerGssnId)) $o['displayRetailerGssnId'] = $this->displayRetailerGssnId;
        if (isset($this->location)) $o['location'] = $this->location;
        if (isset($this->account)) $o['account'] = $this->account;
        if (isset($this->accountType)) $o['accountType'] = $this->accountType;
        if (isset($this->usageCode)) $o['usageCode'] = $this->usageCode;
        if (isset($this->bm7NST)) $o['bm7NST'] = $this->bm7NST;
        if (isset($this->isSellable)) $o['isSellable'] = $this->isSellable;
        if (isset($this->secured)) $o['secured'] = $this->secured;
        if (isset($this->specialist)) $o['specialist'] = $this->specialist;
        if (isset($this->isMotabilityRetailer)) $o['isMotabilityRetailer'] = $this->isMotabilityRetailer;
        if (isset($this->upholsteryDescription)) $o['upholsteryDescription'] = $this->upholsteryDescription;
        if (isset($this->inBackOrderAccount)) $o['inBackOrderAccount'] = $this->inBackOrderAccount;
        if (isset($this->fullModelYearCode)) $o['fullModelYearCode'] = $this->fullModelYearCode;
        if (isset($this->productionDate)) $o['productionDate'] = JsonConverters::to('DateTime', $this->productionDate);
        if (isset($this->baumuster)) $o['baumuster'] = $this->baumuster;
        if (isset($this->isMotability)) $o['isMotability'] = $this->isMotability;
        if (isset($this->pipAdvanceRentalGross)) $o['pipAdvanceRentalGross'] = $this->pipAdvanceRentalGross;
        if (isset($this->wpmsAdvanceRentalGross)) $o['wpmsAdvanceRentalGross'] = $this->wpmsAdvanceRentalGross;
        if (isset($this->ispVehicleCustomerDescriptions)) $o['ispVehicleCustomerDescriptions'] = JsonConverters::toArray('string', $this->ispVehicleCustomerDescriptions);
        return empty($o) ? new class(){} : $o;
    }
}

class VehicleData extends VehicleDataBase implements JsonSerializable
{
    /**
     * @param string $vin
     * @param string $description
     * @param string $model
     * @param string $otr
     * @param string $retailPriceExVAT
     * @param string $actualPrice
     * @param string $fuelType
     * @param string $transmission
     * @param string $transmissionType
     * @param string $colour
     * @param string $colourCode
     * @param string $colourDescription
     * @param string $commissionNumber
     * @param bool|null $offerAvailable
     * @param int $campaignDiscountOfferTotal
     * @param int $campaignDiscountOfferTotalCurrent
     * @param int $campaignDiscountOfferTotalPending
     * @param int $campaignServiceOfferTotal
     * @param int $campaignServiceOfferTotalCurrent
     * @param int $campaignServiceOfferTotalPending
     * @param int $campaignCustomOfferTotal
     * @param int $campaignPersonalisedOfferTotalCurrent
     * @param int $campaignPersonalisedOfferTotalPending
     * @param int $campaignPersonalisedOfferTotal
     * @param int $campaignCustomOfferTotalCurrent
     * @param int $campaignCustomOfferTotalPending
     * @param int $campaignOtherOfferTotal
     * @param int $campaignOtherOfferTotalCurrent
     * @param int $campaignOtherOfferTotalPending
     * @param int $retailerDiscountOfferTotal
     * @param int $retailerDiscountOfferTotalCurrent
     * @param int $retailerDiscountOfferTotalPending
     * @param int $retailerServiceOfferTotal
     * @param int $retailerServiceOfferTotalCurrent
     * @param int $retailerServiceOfferTotalPending
     * @param int $retailerCustomOfferTotal
     * @param int $retailerCustomOfferTotalCurrent
     * @param int $retailerCustomOfferTotalPending
     * @param int $retailerWarrantyOfferTotal
     * @param int $retailerWarrantyOfferTotalCurrent
     * @param int $retailerWarrantyOfferTotalPending
     * @param int $retailerOfferTotal
     * @param int $retailerOfferTotalCurrent
     * @param int $retailerOfferTotalPending
     * @param int $campaignOfferTotal
     * @param int $campaignOfferTotalCurrent
     * @param int $campaignOfferTotalPending
     * @param int $campaignAndOfferTotal
     * @param int $campaignAndOfferTotalCurrent
     * @param int $campaignAndOfferTotalPending
     * @param int $offerTotal
     * @param int $offerTotalCurrent
     * @param int $offerTotalPending
     * @param string $creation
     * @param string $modified
     * @param int $electricRange
     * @param int $electricConsumption
     * @param DateTime|null $portArrivalDate
     * @param int|null $daysSincePortArrival
     * @param float $retailPriceIncVAT
     * @param string $bodyStyle
     * @param string $upholstery
     * @param string $upholsteryCode
     * @param string $upholsteryType
     * @param array<string>|null $packageNames
     * @param string $line
     * @param float $currentRetailerOfferPrice
     * @param string $retailPrice
     * @param bool|null $vatQualifying
     * @param int $retailerId
     * @param string $gssnId
     * @param bool|null $noImage
     * @param string $imageUrl
     * @param bool|null $isAvailableOnline
     * @param bool|null $isBackOrdered
     * @param string $creationDate
     * @param string $maintenanceDate
     * @param string $registrationNumber
     * @param DateTime|null $registrationDate
     * @param int|null $mileage
     * @param DateTime|null $tradeInDate
     * @param string $source
     * @param string $vehicleType
     * @param string $offerAmount
     * @param string $offerExpiry
     * @param int[] $activeOffers
     * @param int $campaignMessagesTotal
     * @param bool|null $underOffer
     * @param bool|null $isDisplayStock
     * @param string $displayRetailer
     * @param string $displayRetailerGssnId
     * @param string $location
     * @param string $account
     * @param string $accountType
     * @param string $usageCode
     * @param string $bm7NST
     * @param bool|null $isSellable
     * @param bool|null $secured
     * @param bool|null $specialist
     * @param bool|null $isMotabilityRetailer
     * @param string $upholsteryDescription
     * @param bool|null $inBackOrderAccount
     * @param string|null $fullModelYearCode
     * @param DateTime|null $productionDate
     * @param string $baumuster
     * @param bool|null $isMotability
     * @param float|null $pipAdvanceRentalGross
     * @param float|null $wpmsAdvanceRentalGross
     * @param array<string>|null $ispVehicleCustomerDescriptions
     */
    public function __construct(
        string $vin='',
        string $description='',
        string $model='',
        string $otr='',
        string $retailPriceExVAT='',
        string $actualPrice='',
        string $fuelType='',
        string $transmission='',
        string $transmissionType='',
        string $colour='',
        string $colourCode='',
        string $colourDescription='',
        string $commissionNumber='',
        ?bool $offerAvailable=null,
        int $campaignDiscountOfferTotal=0,
        int $campaignDiscountOfferTotalCurrent=0,
        int $campaignDiscountOfferTotalPending=0,
        int $campaignServiceOfferTotal=0,
        int $campaignServiceOfferTotalCurrent=0,
        int $campaignServiceOfferTotalPending=0,
        int $campaignCustomOfferTotal=0,
        int $campaignPersonalisedOfferTotalCurrent=0,
        int $campaignPersonalisedOfferTotalPending=0,
        int $campaignPersonalisedOfferTotal=0,
        int $campaignCustomOfferTotalCurrent=0,
        int $campaignCustomOfferTotalPending=0,
        int $campaignOtherOfferTotal=0,
        int $campaignOtherOfferTotalCurrent=0,
        int $campaignOtherOfferTotalPending=0,
        int $retailerDiscountOfferTotal=0,
        int $retailerDiscountOfferTotalCurrent=0,
        int $retailerDiscountOfferTotalPending=0,
        int $retailerServiceOfferTotal=0,
        int $retailerServiceOfferTotalCurrent=0,
        int $retailerServiceOfferTotalPending=0,
        int $retailerCustomOfferTotal=0,
        int $retailerCustomOfferTotalCurrent=0,
        int $retailerCustomOfferTotalPending=0,
        int $retailerWarrantyOfferTotal=0,
        int $retailerWarrantyOfferTotalCurrent=0,
        int $retailerWarrantyOfferTotalPending=0,
        int $retailerOfferTotal=0,
        int $retailerOfferTotalCurrent=0,
        int $retailerOfferTotalPending=0,
        int $campaignOfferTotal=0,
        int $campaignOfferTotalCurrent=0,
        int $campaignOfferTotalPending=0,
        int $campaignAndOfferTotal=0,
        int $campaignAndOfferTotalCurrent=0,
        int $campaignAndOfferTotalPending=0,
        int $offerTotal=0,
        int $offerTotalCurrent=0,
        int $offerTotalPending=0,
        string $creation='',
        string $modified='',
        int $electricRange=0,
        int $electricConsumption=0,
        ?DateTime $portArrivalDate=null,
        ?int $daysSincePortArrival=null,
        float $retailPriceIncVAT=0.0,
        string $bodyStyle='',
        string $upholstery='',
        string $upholsteryCode='',
        string $upholsteryType='',
        ?array $packageNames=null,
        string $line='',
        float $currentRetailerOfferPrice=0.0,
        string $retailPrice='',
        ?bool $vatQualifying=null,
        int $retailerId=0,
        string $gssnId='',
        ?bool $noImage=null,
        string $imageUrl='',
        ?bool $isAvailableOnline=null,
        ?bool $isBackOrdered=null,
        string $creationDate='',
        string $maintenanceDate='',
        string $registrationNumber='',
        ?DateTime $registrationDate=null,
        ?int $mileage=null,
        ?DateTime $tradeInDate=null,
        string $source='',
        string $vehicleType='',
        string $offerAmount='',
        string $offerExpiry='',
        array $activeOffers=[],
        int $campaignMessagesTotal=0,
        ?bool $underOffer=null,
        ?bool $isDisplayStock=null,
        string $displayRetailer='',
        string $displayRetailerGssnId='',
        string $location='',
        string $account='',
        string $accountType='',
        string $usageCode='',
        string $bm7NST='',
        ?bool $isSellable=null,
        ?bool $secured=null,
        ?bool $specialist=null,
        ?bool $isMotabilityRetailer=null,
        string $upholsteryDescription='',
        ?bool $inBackOrderAccount=null,
        ?string $fullModelYearCode=null,
        ?DateTime $productionDate=null,
        string $baumuster='',
        ?bool $isMotability=null,
        ?float $pipAdvanceRentalGross=null,
        ?float $wpmsAdvanceRentalGross=null,
        ?array $ispVehicleCustomerDescriptions=null,
        /** @var string */
        public string $engine=''
    ) {
        parent::__construct($vin,$description,$model,$otr,$retailPriceExVAT,$actualPrice,$fuelType,$transmission,$transmissionType,$colour,$colourCode,$colourDescription,$commissionNumber,$offerAvailable,$campaignDiscountOfferTotal,$campaignDiscountOfferTotalCurrent,$campaignDiscountOfferTotalPending,$campaignServiceOfferTotal,$campaignServiceOfferTotalCurrent,$campaignServiceOfferTotalPending,$campaignCustomOfferTotal,$campaignPersonalisedOfferTotalCurrent,$campaignPersonalisedOfferTotalPending,$campaignPersonalisedOfferTotal,$campaignCustomOfferTotalCurrent,$campaignCustomOfferTotalPending,$campaignOtherOfferTotal,$campaignOtherOfferTotalCurrent,$campaignOtherOfferTotalPending,$retailerDiscountOfferTotal,$retailerDiscountOfferTotalCurrent,$retailerDiscountOfferTotalPending,$retailerServiceOfferTotal,$retailerServiceOfferTotalCurrent,$retailerServiceOfferTotalPending,$retailerCustomOfferTotal,$retailerCustomOfferTotalCurrent,$retailerCustomOfferTotalPending,$retailerWarrantyOfferTotal,$retailerWarrantyOfferTotalCurrent,$retailerWarrantyOfferTotalPending,$retailerOfferTotal,$retailerOfferTotalCurrent,$retailerOfferTotalPending,$campaignOfferTotal,$campaignOfferTotalCurrent,$campaignOfferTotalPending,$campaignAndOfferTotal,$campaignAndOfferTotalCurrent,$campaignAndOfferTotalPending,$offerTotal,$offerTotalCurrent,$offerTotalPending,$creation,$modified,$electricRange,$electricConsumption,$portArrivalDate,$daysSincePortArrival,$retailPriceIncVAT,$bodyStyle,$upholstery,$upholsteryCode,$upholsteryType,$packageNames,$line,$currentRetailerOfferPrice,$retailPrice,$vatQualifying,$retailerId,$gssnId,$noImage,$imageUrl,$isAvailableOnline,$isBackOrdered,$creationDate,$maintenanceDate,$registrationNumber,$registrationDate,$mileage,$tradeInDate,$source,$vehicleType,$offerAmount,$offerExpiry,$activeOffers,$campaignMessagesTotal,$underOffer,$isDisplayStock,$displayRetailer,$displayRetailerGssnId,$location,$account,$accountType,$usageCode,$bm7NST,$isSellable,$secured,$specialist,$isMotabilityRetailer,$upholsteryDescription,$inBackOrderAccount,$fullModelYearCode,$productionDate,$baumuster,$isMotability,$pipAdvanceRentalGross,$wpmsAdvanceRentalGross,$ispVehicleCustomerDescriptions);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['engine'])) $this->engine = $o['engine'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->engine)) $o['engine'] = $this->engine;
        return empty($o) ? new class(){} : $o;
    }
}

class Equipment implements JsonSerializable
{
    public function __construct(
        /** @var int */
        public int $id=0,
        /** @var string|null */
        public ?string $code=null,
        /** @var string|null */
        public ?string $description=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['code'])) $this->code = $o['code'];
        if (isset($o['description'])) $this->description = $o['description'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->code)) $o['code'] = $this->code;
        if (isset($this->description)) $o['description'] = $this->description;
        return empty($o) ? new class(){} : $o;
    }
}

class VehicleIdentifierData extends VehicleData implements JsonSerializable
{
    /**
     * @param string $vin
     * @param string $description
     * @param string $model
     * @param string $otr
     * @param string $retailPriceExVAT
     * @param string $actualPrice
     * @param string $fuelType
     * @param string $transmission
     * @param string $transmissionType
     * @param string $colour
     * @param string $colourCode
     * @param string $colourDescription
     * @param string $commissionNumber
     * @param bool|null $offerAvailable
     * @param int $campaignDiscountOfferTotal
     * @param int $campaignDiscountOfferTotalCurrent
     * @param int $campaignDiscountOfferTotalPending
     * @param int $campaignServiceOfferTotal
     * @param int $campaignServiceOfferTotalCurrent
     * @param int $campaignServiceOfferTotalPending
     * @param int $campaignCustomOfferTotal
     * @param int $campaignPersonalisedOfferTotalCurrent
     * @param int $campaignPersonalisedOfferTotalPending
     * @param int $campaignPersonalisedOfferTotal
     * @param int $campaignCustomOfferTotalCurrent
     * @param int $campaignCustomOfferTotalPending
     * @param int $campaignOtherOfferTotal
     * @param int $campaignOtherOfferTotalCurrent
     * @param int $campaignOtherOfferTotalPending
     * @param int $retailerDiscountOfferTotal
     * @param int $retailerDiscountOfferTotalCurrent
     * @param int $retailerDiscountOfferTotalPending
     * @param int $retailerServiceOfferTotal
     * @param int $retailerServiceOfferTotalCurrent
     * @param int $retailerServiceOfferTotalPending
     * @param int $retailerCustomOfferTotal
     * @param int $retailerCustomOfferTotalCurrent
     * @param int $retailerCustomOfferTotalPending
     * @param int $retailerWarrantyOfferTotal
     * @param int $retailerWarrantyOfferTotalCurrent
     * @param int $retailerWarrantyOfferTotalPending
     * @param int $retailerOfferTotal
     * @param int $retailerOfferTotalCurrent
     * @param int $retailerOfferTotalPending
     * @param int $campaignOfferTotal
     * @param int $campaignOfferTotalCurrent
     * @param int $campaignOfferTotalPending
     * @param int $campaignAndOfferTotal
     * @param int $campaignAndOfferTotalCurrent
     * @param int $campaignAndOfferTotalPending
     * @param int $offerTotal
     * @param int $offerTotalCurrent
     * @param int $offerTotalPending
     * @param string $creation
     * @param string $modified
     * @param int $electricRange
     * @param int $electricConsumption
     * @param DateTime|null $portArrivalDate
     * @param int|null $daysSincePortArrival
     * @param float $retailPriceIncVAT
     * @param string $bodyStyle
     * @param string $upholstery
     * @param string $upholsteryCode
     * @param string $upholsteryType
     * @param array<string>|null $packageNames
     * @param string $line
     * @param float $currentRetailerOfferPrice
     * @param string $retailPrice
     * @param bool|null $vatQualifying
     * @param int $retailerId
     * @param string $gssnId
     * @param bool|null $noImage
     * @param string $imageUrl
     * @param bool|null $isAvailableOnline
     * @param bool|null $isBackOrdered
     * @param string $creationDate
     * @param string $maintenanceDate
     * @param string $registrationNumber
     * @param DateTime|null $registrationDate
     * @param int|null $mileage
     * @param DateTime|null $tradeInDate
     * @param string $source
     * @param string $vehicleType
     * @param string $offerAmount
     * @param string $offerExpiry
     * @param int[] $activeOffers
     * @param int $campaignMessagesTotal
     * @param bool|null $underOffer
     * @param bool|null $isDisplayStock
     * @param string $displayRetailer
     * @param string $displayRetailerGssnId
     * @param string $location
     * @param string $account
     * @param string $accountType
     * @param string $usageCode
     * @param string $bm7NST
     * @param bool|null $isSellable
     * @param bool|null $secured
     * @param bool|null $specialist
     * @param bool|null $isMotabilityRetailer
     * @param string $upholsteryDescription
     * @param bool|null $inBackOrderAccount
     * @param string|null $fullModelYearCode
     * @param DateTime|null $productionDate
     * @param string $baumuster
     * @param bool|null $isMotability
     * @param float|null $pipAdvanceRentalGross
     * @param float|null $wpmsAdvanceRentalGross
     * @param array<string>|null $ispVehicleCustomerDescriptions
     * @param string $engine
     */
    public function __construct(
        string $vin='',
        string $description='',
        string $model='',
        string $otr='',
        string $retailPriceExVAT='',
        string $actualPrice='',
        string $fuelType='',
        string $transmission='',
        string $transmissionType='',
        string $colour='',
        string $colourCode='',
        string $colourDescription='',
        string $commissionNumber='',
        ?bool $offerAvailable=null,
        int $campaignDiscountOfferTotal=0,
        int $campaignDiscountOfferTotalCurrent=0,
        int $campaignDiscountOfferTotalPending=0,
        int $campaignServiceOfferTotal=0,
        int $campaignServiceOfferTotalCurrent=0,
        int $campaignServiceOfferTotalPending=0,
        int $campaignCustomOfferTotal=0,
        int $campaignPersonalisedOfferTotalCurrent=0,
        int $campaignPersonalisedOfferTotalPending=0,
        int $campaignPersonalisedOfferTotal=0,
        int $campaignCustomOfferTotalCurrent=0,
        int $campaignCustomOfferTotalPending=0,
        int $campaignOtherOfferTotal=0,
        int $campaignOtherOfferTotalCurrent=0,
        int $campaignOtherOfferTotalPending=0,
        int $retailerDiscountOfferTotal=0,
        int $retailerDiscountOfferTotalCurrent=0,
        int $retailerDiscountOfferTotalPending=0,
        int $retailerServiceOfferTotal=0,
        int $retailerServiceOfferTotalCurrent=0,
        int $retailerServiceOfferTotalPending=0,
        int $retailerCustomOfferTotal=0,
        int $retailerCustomOfferTotalCurrent=0,
        int $retailerCustomOfferTotalPending=0,
        int $retailerWarrantyOfferTotal=0,
        int $retailerWarrantyOfferTotalCurrent=0,
        int $retailerWarrantyOfferTotalPending=0,
        int $retailerOfferTotal=0,
        int $retailerOfferTotalCurrent=0,
        int $retailerOfferTotalPending=0,
        int $campaignOfferTotal=0,
        int $campaignOfferTotalCurrent=0,
        int $campaignOfferTotalPending=0,
        int $campaignAndOfferTotal=0,
        int $campaignAndOfferTotalCurrent=0,
        int $campaignAndOfferTotalPending=0,
        int $offerTotal=0,
        int $offerTotalCurrent=0,
        int $offerTotalPending=0,
        string $creation='',
        string $modified='',
        int $electricRange=0,
        int $electricConsumption=0,
        ?DateTime $portArrivalDate=null,
        ?int $daysSincePortArrival=null,
        float $retailPriceIncVAT=0.0,
        string $bodyStyle='',
        string $upholstery='',
        string $upholsteryCode='',
        string $upholsteryType='',
        ?array $packageNames=null,
        string $line='',
        float $currentRetailerOfferPrice=0.0,
        string $retailPrice='',
        ?bool $vatQualifying=null,
        int $retailerId=0,
        string $gssnId='',
        ?bool $noImage=null,
        string $imageUrl='',
        ?bool $isAvailableOnline=null,
        ?bool $isBackOrdered=null,
        string $creationDate='',
        string $maintenanceDate='',
        string $registrationNumber='',
        ?DateTime $registrationDate=null,
        ?int $mileage=null,
        ?DateTime $tradeInDate=null,
        string $source='',
        string $vehicleType='',
        string $offerAmount='',
        string $offerExpiry='',
        array $activeOffers=[],
        int $campaignMessagesTotal=0,
        ?bool $underOffer=null,
        ?bool $isDisplayStock=null,
        string $displayRetailer='',
        string $displayRetailerGssnId='',
        string $location='',
        string $account='',
        string $accountType='',
        string $usageCode='',
        string $bm7NST='',
        ?bool $isSellable=null,
        ?bool $secured=null,
        ?bool $specialist=null,
        ?bool $isMotabilityRetailer=null,
        string $upholsteryDescription='',
        ?bool $inBackOrderAccount=null,
        ?string $fullModelYearCode=null,
        ?DateTime $productionDate=null,
        string $baumuster='',
        ?bool $isMotability=null,
        ?float $pipAdvanceRentalGross=null,
        ?float $wpmsAdvanceRentalGross=null,
        ?array $ispVehicleCustomerDescriptions=null,
        string $engine='',
        /** @var string */
        public string $retailer='',
        /** @var bool|null */
        public ?bool $hasMotabilityError=null,
        /** @var array<Equipment>|null */
        public ?array $equipment=null
    ) {
        parent::__construct($vin,$description,$model,$otr,$retailPriceExVAT,$actualPrice,$fuelType,$transmission,$transmissionType,$colour,$colourCode,$colourDescription,$commissionNumber,$offerAvailable,$campaignDiscountOfferTotal,$campaignDiscountOfferTotalCurrent,$campaignDiscountOfferTotalPending,$campaignServiceOfferTotal,$campaignServiceOfferTotalCurrent,$campaignServiceOfferTotalPending,$campaignCustomOfferTotal,$campaignPersonalisedOfferTotalCurrent,$campaignPersonalisedOfferTotalPending,$campaignPersonalisedOfferTotal,$campaignCustomOfferTotalCurrent,$campaignCustomOfferTotalPending,$campaignOtherOfferTotal,$campaignOtherOfferTotalCurrent,$campaignOtherOfferTotalPending,$retailerDiscountOfferTotal,$retailerDiscountOfferTotalCurrent,$retailerDiscountOfferTotalPending,$retailerServiceOfferTotal,$retailerServiceOfferTotalCurrent,$retailerServiceOfferTotalPending,$retailerCustomOfferTotal,$retailerCustomOfferTotalCurrent,$retailerCustomOfferTotalPending,$retailerWarrantyOfferTotal,$retailerWarrantyOfferTotalCurrent,$retailerWarrantyOfferTotalPending,$retailerOfferTotal,$retailerOfferTotalCurrent,$retailerOfferTotalPending,$campaignOfferTotal,$campaignOfferTotalCurrent,$campaignOfferTotalPending,$campaignAndOfferTotal,$campaignAndOfferTotalCurrent,$campaignAndOfferTotalPending,$offerTotal,$offerTotalCurrent,$offerTotalPending,$creation,$modified,$electricRange,$electricConsumption,$portArrivalDate,$daysSincePortArrival,$retailPriceIncVAT,$bodyStyle,$upholstery,$upholsteryCode,$upholsteryType,$packageNames,$line,$currentRetailerOfferPrice,$retailPrice,$vatQualifying,$retailerId,$gssnId,$noImage,$imageUrl,$isAvailableOnline,$isBackOrdered,$creationDate,$maintenanceDate,$registrationNumber,$registrationDate,$mileage,$tradeInDate,$source,$vehicleType,$offerAmount,$offerExpiry,$activeOffers,$campaignMessagesTotal,$underOffer,$isDisplayStock,$displayRetailer,$displayRetailerGssnId,$location,$account,$accountType,$usageCode,$bm7NST,$isSellable,$secured,$specialist,$isMotabilityRetailer,$upholsteryDescription,$inBackOrderAccount,$fullModelYearCode,$productionDate,$baumuster,$isMotability,$pipAdvanceRentalGross,$wpmsAdvanceRentalGross,$ispVehicleCustomerDescriptions,$engine);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['retailer'])) $this->retailer = $o['retailer'];
        if (isset($o['hasMotabilityError'])) $this->hasMotabilityError = $o['hasMotabilityError'];
        if (isset($o['equipment'])) $this->equipment = JsonConverters::fromArray('Equipment', $o['equipment']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->retailer)) $o['retailer'] = $this->retailer;
        if (isset($this->hasMotabilityError)) $o['hasMotabilityError'] = $this->hasMotabilityError;
        if (isset($this->equipment)) $o['equipment'] = JsonConverters::toArray('Equipment', $this->equipment);
        return empty($o) ? new class(){} : $o;
    }
}

class VehiclesByRetailerResponse implements JsonSerializable
{
    public function __construct(
        /** @var array<VehicleIdentifierData>|null */
        public ?array $vehicles=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['vehicles'])) $this->vehicles = JsonConverters::fromArray('VehicleIdentifierData', $o['vehicles']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->vehicles)) $o['vehicles'] = JsonConverters::toArray('VehicleIdentifierData', $this->vehicles);
        return empty($o) ? new class(){} : $o;
    }
}

class CentralVehiclesRequest implements IGet, IDataShapedRequest, JsonSerializable
{
    public function __construct(
        /** @var string */
        public string $vehicleType='',
        /** @description If specified, the API will shape the data in the response to only include the specified fields */
        // @ApiMember(Description="If specified, the API will shape the data in the response to only include the specified fields", ParameterType="model")
        /** @var string */
        public string $fields=''
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['vehicleType'])) $this->vehicleType = $o['vehicleType'];
        if (isset($o['fields'])) $this->fields = $o['fields'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->vehicleType)) $o['vehicleType'] = $this->vehicleType;
        if (isset($this->fields)) $o['fields'] = $this->fields;
        return empty($o) ? new class(){} : $o;
    }
}

PHP CentralVehiclesRequest 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.

GET /v1/{VehicleType}/Vehicle/Central HTTP/1.1 
Host: uat-api-vehicle-mgt-mb-dhc.rapp-customers.co.uk 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	vehicles: 
	[
		{
			retailer: String,
			hasMotabilityError: False,
			equipment: 
			[
				{
					id: 0,
					code: String,
					description: String
				}
			],
			engine: String,
			vin: String,
			description: String,
			model: String,
			otr: String,
			retailPriceExVAT: String,
			actualPrice: String,
			fuelType: String,
			transmission: String,
			transmissionType: String,
			colour: String,
			colourCode: String,
			colourDescription: String,
			commissionNumber: String,
			offerAvailable: False,
			campaignDiscountOfferTotal: 0,
			campaignDiscountOfferTotalCurrent: 0,
			campaignDiscountOfferTotalPending: 0,
			campaignServiceOfferTotal: 0,
			campaignServiceOfferTotalCurrent: 0,
			campaignServiceOfferTotalPending: 0,
			campaignCustomOfferTotal: 0,
			campaignPersonalisedOfferTotalCurrent: 0,
			campaignPersonalisedOfferTotalPending: 0,
			campaignPersonalisedOfferTotal: 0,
			campaignCustomOfferTotalCurrent: 0,
			campaignCustomOfferTotalPending: 0,
			campaignOtherOfferTotal: 0,
			campaignOtherOfferTotalCurrent: 0,
			campaignOtherOfferTotalPending: 0,
			retailerDiscountOfferTotal: 0,
			retailerDiscountOfferTotalCurrent: 0,
			retailerDiscountOfferTotalPending: 0,
			retailerServiceOfferTotal: 0,
			retailerServiceOfferTotalCurrent: 0,
			retailerServiceOfferTotalPending: 0,
			retailerCustomOfferTotal: 0,
			retailerCustomOfferTotalCurrent: 0,
			retailerCustomOfferTotalPending: 0,
			retailerWarrantyOfferTotal: 0,
			retailerWarrantyOfferTotalCurrent: 0,
			retailerWarrantyOfferTotalPending: 0,
			retailerOfferTotal: 0,
			retailerOfferTotalCurrent: 0,
			retailerOfferTotalPending: 0,
			campaignOfferTotal: 0,
			campaignOfferTotalCurrent: 0,
			campaignOfferTotalPending: 0,
			campaignAndOfferTotal: 0,
			campaignAndOfferTotalCurrent: 0,
			campaignAndOfferTotalPending: 0,
			offerTotal: 0,
			offerTotalCurrent: 0,
			offerTotalPending: 0,
			creation: String,
			modified: String,
			electricRange: 0,
			electricConsumption: 0,
			portArrivalDate: 0001-01-01,
			daysSincePortArrival: 0,
			retailPriceIncVAT: 0,
			bodyStyle: String,
			upholstery: String,
			upholsteryCode: String,
			upholsteryType: String,
			packageNames: 
			[
				String
			],
			line: String,
			currentRetailerOfferPrice: 0,
			retailPrice: String,
			vatQualifying: False,
			retailerId: 0,
			gssnId: String,
			noImage: False,
			imageUrl: String,
			isAvailableOnline: False,
			isBackOrdered: False,
			creationDate: String,
			maintenanceDate: String,
			registrationNumber: String,
			registrationDate: 0001-01-01,
			mileage: 0,
			tradeInDate: 0001-01-01,
			source: String,
			vehicleType: String,
			offerAmount: String,
			offerExpiry: String,
			activeOffers: 
			[
				0
			],
			campaignMessagesTotal: 0,
			underOffer: False,
			isDisplayStock: False,
			displayRetailer: String,
			displayRetailerGssnId: String,
			location: String,
			account: String,
			accountType: String,
			usageCode: String,
			bm7NST: String,
			isSellable: False,
			secured: False,
			specialist: False,
			isMotabilityRetailer: False,
			upholsteryDescription: String,
			inBackOrderAccount: False,
			fullModelYearCode: String,
			productionDate: 0001-01-01,
			baumuster: String,
			isMotability: False,
			pipAdvanceRentalGross: 0,
			wpmsAdvanceRentalGross: 0,
			ispVehicleCustomerDescriptions: 
			[
				String
			]
		}
	]
}