Update Quote Endpoints: PatchQuote - Options tab

API endpoints for patching and updating quotes

PatchQuote - Options tab

The fields listed on this page are all found primarily on the Quotes / Options tab.

Refer to main page for full details of patchQuote functionality.

Supplementary SWAGGER documentation is available here: api.catch-e.com/docs/#/Quotes/patchQuote

Body - JSON

JSON FieldFormatNotesMandatory
included_flagstringIf 'yes', the corresponding Optional Equipment (optionalequipmentid) will be added to the quote. If 'no', the Optional Equipment (optionalequipmentid) will be removed from the quote.Yes
optionalequipmentidstringThe optionalequipmentid to be added or removed depending on the included_flag value.Yes
descriptionnumberAllows you to over ride the system default description for the Optional Equipment record.No
costpricenetnumberAllows you to over ride the system default costpricenet for the Optional Equipment record.No
listpricenetnumberAllows you to over ride the system default listpricenet for the Optional Equipment record.No
discount_netnumberAllows you to over ride the system default discount_net for the Optional Equipment record.No
gstnumberAllows you to over ride the system default gst for the Optional Equipment record.No
residual_ratenumberAllows you to over ride the system default residual_rate for the Optional Equipment record.No

Sample JSON content

Adding one Optional Equipment record

"optional_equipment": [ { "included_flag": "yes", "optional_equipment_id": "100000" }]

Adding two Optional Equipment records

"optional_equipment": [ { "included_flag": "yes", "optional_equipment_id": "100000" }, { "included_flag": "yes", "optional_equipment_id": "100001" }]

Removing one Optional Equipment record

"optional_equipment": [ { "included_flag": "no", "optional_equipment_id": "100000" }]

Removing multiple Optional Equipment records

"optional_equipment": [ { "included_flag": "no", "optional_equipment_id": "100000" }, { "included_flag": "no", "optional_equipment_id": "100001" }, { "included_flag": "no", "optional_equipment_id": "100002" }]NOTE: Repeat for each optional_equipment_id you want removed.

Example for modifying an Optional Equipment

"optional_equipment": [ { "included_flag": "yes", "optional_equipment_id": "100000", "description": "This is an alternative description for the option", "cost_price_net": "545.45", "list_price_net": "545.45", "discount_net": "0", "gst": "54.55", "residual_rate": "0" }]

PatchQuote - Other tab

The fields listed on this page are all found on the Quotes:Other tab.

Note: Not all fields are supported yet. If a field is listed below it is supported.

Refer to main page for full details of patchQuote functionality.

Supplementary SWAGGER documentation is available here: api.catch-e.com/docs/#/Quotes/patchQuote

Body - JSON

JSON FieldFormatNotesMandatory
Column 1

| bespokefieldvalues | string | **Nominate the required for each field. A range of different input values can be used for bespoke fields, see the notes below for the requirements of each input type. 6 input types are appropriate for use here. Not all input types are validated in the API, so test fully when setting up your calls. The API will also validate supplied values against a (if present). Settings for are not validated. Settings for are not validated.
** | input_type | Description | Validation |
| number | Right justified numeric character entry | Yes. See 422 Response Details. | | | |
| listbox | For the nominated , pass the required as the API value. | Yes. See 422 Response Details. | | | |
| textarea | Will allow alpha, numeric and character text content | No | | | |
| text | Will allow alpha, numeric and character text content | No | | | |
| date | Will allow date content and will pop a date selector | No. Any value can be passed and will be displayed. | | | |
| checkbox | Checked = yes, unchecked = no | No. Any value can be passed and will be displayed. | | | |
| blank | Will insert a blank row on screen (used for aesthetics only) | Input type should not be used here. | | | |
| label | Used to contain the section heading label | Input type should not be used here. | No | | |

Sample JSON content

This example displays a section of content if bespoke fields were being used in the API

https://api.catch-e.com/qt/quotes/
{ "after_hours_assistance_flag": "no", "allowances": 0, "annual_kms": 0, "annual_salary": 0, "application_date": "YYYY-MM-DD", "application_reference": "string", "bespoke_field_values": { "bespoke_field_name": "Bespoke Field Value" }}

Response Details

Validation MessagesComments
422 - Unprocessable Entity
 "bespoke_field_values": { "invalidBespokeFieldValue": "input_type_listbox: Unsupported value"

| If the setting is 'listbox' for the target field, the must be passed. | |

 "bespoke_field_values": { "invalidBespokeFieldValue": "input_type_number: Must be a number"

| If the setting is 'number' for the target field, only an number can be passed. |

Useful Queries

select bfv.record_id as quote_id,bf.bespoke_field_id, bf.field_name, bf.input_type, bf.default_value, bf.input_maxlength, coalesce(bl.value, bfv.value) as valuefrom gb_bespoke_fields as bfleft join gb_bespoke_field_values as bfv on bfv.bespoke_field_id = bf.bespoke_field_idleft join gb_bespoke_listboxes as bl on bl.bespoke_field_id = bf.bespoke_field_id and bl.bespoke_listbox_id = bfv.valuewhere bf.table_name = 'qt_quotes' and bfv.record_id = 100009 # quote_id;

PatchQuote - Vehicle tab

The fields listed on this page are primarily found on the Quotes / Vehicle tab.

Note: All Quotes / Vehicle tab fields are supported.

Refer to main page for full details of patchQuote functionality.

Supplementary SWAGGER documentation is available here: api.catch-e.com/docs/#/Quotes/patchQuote

Refer to Options tab for details about adding/removing or editing Optional Equipment.

Body - JSON

JSON FieldFormatNotesMandatory
Column 1
variant_idstringUpdates the VariantNo
plate_yearstringUpdates the Plate YearNo
new_usedstringUpdates the New or Used value. Can be 'new', 'used' or 'demonstrator'.No
procurement_flagcheckboxUpdates the Procurement flagNo
procurement_feenumberUpdates the Procurement FeeNo
disposal_flagcheckboxUpdates the Disposal flagNo
disposal_feenumberUpdates the Disposal FeeNo
odometercheckboxUpdates the Odometer (mandatory when new_used = 'used' or 'demonstrator').No
warranty_monthsstringUpdates the Warranty MthsNo
warranty_kmsstringUpdates the Warranty KMsNo
colour_preferencestringUpdates the ColourNo
colourpreference2stringUpdates the 2nd Colour preferenceNo
colourpreference3stringUpdates the 3rd Colour preferenceNo
colourpreferencenotestringUpdates the Colour preference NoteNo
trim_preferencestringUpdates the TrimNo
Column 2
supplieriddealerstringUpdates the Preferred DealerNo
dealer_commentstringUpdates the CommentsNo
discounttypeidstringUpdates Discount StatusNo
deliverylocationtypestringUpdates the Delivery TypeNo
listpricenetfloatUpdates List Price (Exc GST)No
listpricegstfloatUpdates List Price (GST)No
lockdiscountflagstringUpdates Check box next to Fleet DiscountNo
discount_percentagefloatUpdates Discount %No
discount_netfloatUpdates Fleet Discount (Exc GST)No
discount_gstfloatUpdates Fleet Discount (GST)No
rebate_netfloatUpdates Confidential Rebate (Exc GST)No
rebate_gstfloatUpdates Confidential Rebate (GST)No
dealerrebatenetfloatUpdates Dealer RebateNo
dealerrebategstfloatUpdates Dealer Rebate (GST)No
bonusamountnetfloatUpdates Bonus (Exc GST)No
bonusamountgstfloatUpdates Bonus (GST)No
lockdealerdiscount_flagstringUpdates Check box next to Dealer DiscountNo
dealerdiscountnetfloatUpdates Dealer Discount (Exc GST)No
dealerdiscountgstfloatUpdates Dealer Discount (GST)No
margin_netfloatUpdates Margin (Exc GST)No
margin_gstfloatUpdates Margin (GST)No
dealerdeliverynetfloatUpdates Dealer Delivery Fee (Exc GST)No
dealerdeliverygstfloatUpdates Dealer Delivery Fee (GST)No
lockluxurycartaxflagstringUpdates Check box next to Luxury Car TaxNo
luxurycartaxfloatUpdates Luxury Car TaxNo
ctpinitialnetfloatUpdates Initial CTP (Exc GST)No
ctpinitialgstfloatUpdates Initial CTP (GST)No
reginitialnetfloatUpdates Initial RegistrationNo
premiumplatesnetfloatUpdates Premium PlateNo
lockpurchasestamp_dutystringUpdates Check box Purch. Stamp DutyNo
purchasestampdutyfloatUpdates Purch. Stamp Duty. Note: If this value is included in the request payload, it will overwrite all calculation variations as noted in the Purchase Stamp Duty page.No
lockfbtvalue_flagcheckboxUpdates the Lock FBT ValueNo
fbt_valuefloatUpdates FBT ValueNo
fbttreatmenttypecheckboxUpdates the FBT Treatment TypeNo

| datefirstheld | string | IF: ‘New or Used’ does not equal ‘New’
and
= ‘yes’ (using existing hierarchical logic from then )
and
Quote “Luxury Car Tax” already equals zero or patchQuote payload contains "luxurycartax": "0.00":
and
"datefirstheld" is not in patchQuote payload:
THEN:
"fbttreatmenttype" will be set to 'standard'.
Notes:
A blank date (0000-00-00) is considered to be prior to 2022-07-01.
See FBT Treatment Type for additional explanation of ATO Rules. | No |
| luxurycartaxpaidflag | string | IF: ‘New or Used’ does not equal ‘New’ and = ‘yes’ (using existing hierarchical logic from then ) and Quote “Luxury Car Tax” already equals zero or patchQuote payload contains "luxurycartax": "0.00": and "luxurycartaxpaidflag" is not in patchQuote payload: THEN: "fbttreatmenttype" will be set to 'standard'. Notes: See FBT Treatment Type for additional explanation of ATO Rules. | No |
| pricecomment | string | Updates the Pricing Comments | No || pricingrequested | timestamp | Updates the Pricing Requested | No |
| pricingreceived | timestamp | Updates the Pricing Received | No || pricingreference | string | Updates the Pricing Reference | No |

PatchQuote Supporting APIs

The APIs shown below offer ways of obtaining data required for patchQuote. For example, patchQuote expects paycycleid. Use getPayCycles to get the paycycleid for your chosen Pay Cycle.

Supplementary SWAGGER documentation is available here: api.catch-e.com/docs/#/Quotes/patchQuote

Note: These APIs are not configured for external use but may be made available on request.
Contact your Account Manager to discuss.

Quote / Status & Sub Status

MethodComments
getQuoteStatusesGet a list of Quote Statuses.
getQuoteSubStatusesGet a list of Quote Sub Statuses.

Quote / Competitors

MethodComments
getCompetitorsGet a list of Competitors
getCompetitorMarginsGet a list of Competitor Margins

Quote / Deal Types

MethodCommentsPermission
getDealTypesAllows you to retrieve a list of Deal Types.DealTypes:Get

Quote / (Contract) Type Code

MethodCommentsPermission
getPostingMapsAllows you to retrieve a list of Contract Types (Posting Maps).PostingMaps:Get

Quote / Discount Types

MethodComments
getDiscountTypesGet a list of Discount Types

Quote / Finance Types

MethodComments
getFinanceTypesGet a list of Finance Types

Quote / Fuel Types

MethodComments
getFuelTypesGet a list of Fuel Types
getFuelTypeTranslationsGet a list of Fuel Type Translations

Quote / Inclusions

MethodComments
getInclusionGet the details of a single inclusion
getInclusionsGet a list of inclusions
getInclusionPlanGet the details of a single inclusion plan
getInclusionPlansGet a list of inclusion plans

Quote / Insurance

MethodComments
getInsuranceLoadingTypesGet a list of insurance loading types
getInsuranceLoadingTypeGet the details of a single insurance loading type
getInsuranceTypesGet a list of insurance types
getInsuranceTypeGet the details of a single insurance type
getInsurerLocationsGet a list of insurance locations
getInsurerLocationGet the details of a single insurance location

Quote / Loan Termination Insurance

MethodComments
getLtiPlansGet a list of LTI Plans.
getLtiTopUpBenefitsGet a list of LTI Top Up Benefits.

Quote / Location Rego

MethodComments
getLocationsGet a list of "Location Rego" ID values (Metro, Semi Metro, Country)

Quote / Maintenance and Service

MethodComments
getMaintenanceServiceProfilesGet a list of Maintenance Profiles

Quote / Opportunity Stages

MethodCommentsPermission
getOpportunityStagesGet a list of details of Opportunity Stage IDs used by the Salesforce CRM system.OpportunityStages:Get

Quote / Power Plant Types

MethodComments
getPowerPlantTypesGet a list of Power Plant Types

Quote / Roadside Assistance

MethodComments
getRoadsideAssistancePlansGet a list of Roadside Assistance Plan ID's

Quote / Tyre Rim Insurance

MethodComments
getTyreRimInsurancePlansGet a list of Tyre Rim Insurance Plan ID's

Quote / Tyres

MethodComments
getTyresGet a list of Tyres

Quote / Variants

Details can be found here.

Quote / Vehicle Types

MethodCommentsPermission
getVehicleTypesGet a list of vehicle types.VehicleTypes:Get

Quote / Vehicle Usage Types

MethodCommentsPermission
getVehicleUsageTypesGet a list of "Usage Types".VehicleUsageTypes:Get

Quote / Walkaway

MethodComments
getWalkawayPlansGet a list of Walkaway Plan ID's

Legend

FieldDescription
MethodThe API is available by default.
MethodThis API is not configured for external use by default. If you want to use this API, contact your Account Manager to discuss access.