POST | /v1/pricingdetails | Creates a detailed pricing of a vehicle |
---|
export enum Source
{
OnlineShowroom = 1,
OneAdmin = 2,
}
export class Address
{
public Property: string;
public Street: string;
public Town: string;
public County: string;
public Locality: string;
public Postcode: string;
public constructor(init?: Partial<Address>) { (Object as any).assign(this, init); }
}
export enum CustomerMode
{
Private = 1,
Business = 2,
Motability = 3,
}
export class SalesforceCustomer implements ICustomer
{
public CustomerId: string;
public IsCiam: boolean;
public CompanyName: string;
public Title: string;
public Firstname: string;
public Surname: string;
public EmailAddress: string;
public Telephone: string;
public Address: Address;
public Mode: CustomerMode;
public constructor(init?: Partial<SalesforceCustomer>) { (Object as any).assign(this, init); }
}
export class Preferences
{
public OptinEmail: boolean;
public OptinPost: boolean;
public OptinSMS: boolean;
public OptinTelephone: boolean;
public constructor(init?: Partial<Preferences>) { (Object as any).assign(this, init); }
}
export class Customer extends SalesforceCustomer
{
public ProfileId?: string;
public Preferences?: Preferences;
public constructor(init?: Partial<Customer>) { super(init); (Object as any).assign(this, init); }
}
export class Vehicle
{
public Vin?: string;
public constructor(init?: Partial<Vehicle>) { (Object as any).assign(this, init); }
}
export class Option
{
public IsDefault: boolean;
public Value: number;
public constructor(init?: Partial<Option>) { (Object as any).assign(this, init); }
}
export class Term
{
public Options: Option[] = [];
public constructor(init?: Partial<Term>) { (Object as any).assign(this, init); }
}
export class Deposit
{
public Default: string;
public constructor(init?: Partial<Deposit>) { (Object as any).assign(this, init); }
}
export class Mileage
{
public Options: Option[] = [];
public constructor(init?: Partial<Mileage>) { (Object as any).assign(this, init); }
}
export class AdvanceRentals
{
public Options: Option[] = [];
public constructor(init?: Partial<AdvanceRentals>) { (Object as any).assign(this, init); }
}
export enum VehicleType
{
UNASSIGNED = 'UNASSIGNED',
NEW = 'NEW',
USED = 'USED',
}
export class FinanceCriteria
{
public Key: string;
public Name: string;
public Type: string;
public IsDefault: boolean;
public Term: Term;
public Deposit: Deposit;
public Mileage: Mileage;
public AdvanceRentals: AdvanceRentals;
public IsPersonalised: boolean;
public RegularPayment: string;
public PartExchange: string;
public Settlement: string;
public CustomerType: string;
public VehicleType: VehicleType;
public constructor(init?: Partial<FinanceCriteria>) { (Object as any).assign(this, init); }
}
export class OutrightPurchase
{
public IsOutrightPurchase: boolean;
public Reference: string;
public DiscountRate: number;
public Bm7NST: string;
public IsBackOrder: boolean;
public IsCOPConverter: boolean;
public constructor(init?: Partial<OutrightPurchase>) { (Object as any).assign(this, init); }
}
export enum MotabilityType
{
PIP = 1,
WPMS = 2,
UNASSIGNED = 3,
}
export class CreateOrderBase
{
public Source: Source;
public GssnId: string;
public AdditionalInformation: string;
public Cash: boolean;
public Finance: boolean;
public Customer: Customer;
public Vehicle: Vehicle;
public FinanceCriteria: FinanceCriteria;
public BackOrderGuid?: string;
public TagUrl?: string;
public OutrightPurchase?: OutrightPurchase;
public Motability: boolean;
public MotabilityPricingId?: number;
public FinanceApplicationReference: string;
public Specialist: boolean;
public GasId: string;
public PersonalisedItemOfferIds?: number[];
public SuggestedVin?: string;
public NonOptimumReason?: string;
public MotabilityType: MotabilityType;
public EstimatedHandoverDate: string;
public constructor(init?: Partial<CreateOrderBase>) { (Object as any).assign(this, init); }
}
export enum OfferPriceProductType
{
LIST_PRICE = 'LIST_PRICE',
NUMBER_PLATE_FEE = 'NUMBER_PLATE_FEE',
DELIVERY_CHARGE = 'DELIVERY_CHARGE',
FUEL_CHARGE = 'FUEL_CHARGE',
MANUFACTURER_OFFER = 'MANUFACTURER_OFFER',
PERSONALISED_MONEYOFFER = 'PERSONALISED_MONEYOFFER',
PERSONALISED_NONMONEYOFFER = 'PERSONALISED_NONMONEYOFFER',
PERSONALISED_NONMONEYOFFER_NEG = 'PERSONALISED_NONMONEYOFFER_NEG',
SERVICE = 'SERVICE',
SERVICE_NEG = 'SERVICE_NEG',
GOVERNMENT_GRANT = 'GOVERNMENT_GRANT',
OUTRIGHT_PURCHASE_DISCOUNT = 'OUTRIGHT_PURCHASE_DISCOUNT',
VIP_OFFER = 'VIP_OFFER',
WALLBOX_OFFER = 'WALLBOX_OFFER',
WALLBOX_OFFER_NEG = 'WALLBOX_OFFER_NEG',
ROAD_FUND_LICENCE = 'ROAD_FUND_LICENCE',
FIRST_REGISTRATION_FEE = 'FIRST_REGISTRATION_FEE',
NOT_FOUND = 'NOT_FOUND',
ACCESSORY_OFFER = 'ACCESSORY_OFFER',
ACCESSORY_OFFER_NEG = 'ACCESSORY_OFFER_NEG',
MOTABILITY_DISCOUNT = 'MOTABILITY_DISCOUNT',
}
export class Price
{
public Id: string;
public Description: string;
public Net: number;
public VAT: number;
public Gross: number;
public Product: OfferPriceProductType;
public constructor(init?: Partial<Price>) { (Object as any).assign(this, init); }
}
export class GetPricingDetailsResponse
{
public Price: Price;
public constructor(init?: Partial<GetPricingDetailsResponse>) { (Object as any).assign(this, init); }
}
export class GetPricingDetailsRequest extends CreateOrderBase implements IPost
{
public constructor(init?: Partial<GetPricingDetailsRequest>) { super(init); (Object as any).assign(this, init); }
}
TypeScript GetPricingDetailsRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/pricingdetails HTTP/1.1
Host: prod-api-agency-orch-mb-dhc.rapp-customers.co.uk
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"Source":"OnlineShowroom","GssnId":"String","AdditionalInformation":"String","Cash":false,"Finance":false,"Customer":{"ProfileId":"00000000000000000000000000000000","Preferences":{"OptinEmail":false,"OptinPost":false,"OptinSMS":false,"OptinTelephone":false},"CustomerId":"String","IsCiam":false,"CompanyName":"String","Title":"String","Firstname":"String","Surname":"String","EmailAddress":"String","Telephone":"String","Address":{"Property":"String","Street":"String","Town":"String","County":"String","Locality":"String","Postcode":"String"},"Mode":"Private"},"Vehicle":{"Vin":"String"},"FinanceCriteria":{"Key":"String","Name":"String","Type":"String","IsDefault":false,"Term":{"Options":[{"IsDefault":false,"Value":0}]},"Deposit":{"Default":"String"},"Mileage":{"Options":[{"IsDefault":false,"Value":0}]},"AdvanceRentals":{"Options":[{"IsDefault":false,"Value":0}]},"IsPersonalised":false,"RegularPayment":"String","PartExchange":"String","Settlement":"String","CustomerType":"String","VehicleType":"UNASSIGNED"},"BackOrderGuid":"00000000000000000000000000000000","TagUrl":"String","OutrightPurchase":{"IsOutrightPurchase":false,"Reference":"String","DiscountRate":0,"Bm7NST":"String","IsBackOrder":false,"IsCOPConverter":false},"Motability":false,"MotabilityPricingId":0,"FinanceApplicationReference":"String","Specialist":false,"GasId":"String","PersonalisedItemOfferIds":[0],"SuggestedVin":"String","NonOptimumReason":"String","MotabilityType":"PIP","EstimatedHandoverDate":"String"}
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"Price":{"Id":"String","Description":"String","Net":0,"VAT":0,"Gross":0,"Product":"LIST_PRICE"}}