### Example GET Request for Deals Source: https://developers.autotrader.co.uk/api This example demonstrates how to list deals for a specific advertiser, with pagination and date filtering. ```http GET /deals?advertiserId=123456&page=1&from=2023-05-05 ``` -------------------------------- ### List Advertisers Request Example Source: https://developers.autotrader.co.uk/api Example of a GET request to list advertisers with pagination parameters. The default page size is 20, but can be increased up to 40. ```http GET /advertisers?page=1&pageSize=50 ``` -------------------------------- ### Get Finance Application GET Response Source: https://developers.autotrader.co.uk/api Example response for retrieving a finance application. The status can be 'Approved' or other relevant statuses. ```json { "applicationId": "22f47a7d-c46a-4a5e-9e62-230f05466865", "status": "Approved", "applicant": { "title": "MR", "firstName": "Cam", "lastName": "Smith", "email": "cam@gmail.com", "mobile": "0759004xxx", "dateOfBirth": "1989-07-18", "gender": "Male", "nationalityCode": "LTU", "maritalStatus": "Single", "drivingLicenceType": "Full", "changeInCircumstances": false, "numberOfDependants": null, "monthlyChildcare": { "amountGBP": 0 }, "monthlyRentOrMortgage": { "amountGBP": 0 }, "bankAccountHolderName": "C J Smith", "bankAccountNumber": "****5678", "bankSortCode": "NOT EXPOSED YET", "monthsAtBank": 60, "replacingExistingLoan": false, "currentAddress": { "buildingNameOrNumber": "7", "street": "Church Street", "town": "CANNOCK", "county": "STAFFORDSHIRE", "postcode": "WS11 1DE", "months": 50, "status": "Private Tenant" }, "previousAddresses": [ ], "currentEmployment": { "employerName": "Test", "status": "Full Time", "jobTitle": "Middle manager", "monthlyIncome": { "amountGBP": 4800 }, "months": 36, "buildingNameOrNumber": "3", "street": "Church Street", "town": "CANNOCK", "county": "STAFFORDSHIRE", "postcode": "WS11 1DE" }, "previousEmployments": [ ] }, "financeTerms": { "productType": "HP", "termMonths": 24, "estimatedAnnualMileage": 6000, "cashPrice": { "amountGBP": 20000.0 }, "deposit": { "amountGBP": 3000.0 }, "partExchange": { "amountGBP": 0.0 }, "outstandingFinance": { "amountGBP": 0.0 } }, "consent": { "softCheck": "2024-03-04T13:36:24.042Z" } } ``` -------------------------------- ### Finance Application Resource Example Source: https://developers.autotrader.co.uk/api A complete finance application resource with example data, illustrating the structure for applicant and financeTerms. ```json { "applicationId": "22f47a7d-c46a-4a5e-9e62-230f05466865", "status": "Approved", "applicant": { "title": "MR", "firstName": "Cam", "lastName": "Smith,", "email": "cam@gmail.com", "mobile": "0759004xxx", "dateOfBirth": "1989-07-18", "gender": "Male", "nationalityCode": "LTU", "maritalStatus": "Single", "drivingLicenceType": "Full", "changeInCircumstances": false, "numberOfDependants": null, "monthlyChildcare": { "amountGBP": 0 }, "monthlyRentOrMortgage": { "amountGBP": 0 }, "bankAccountHolderName": "C J Smith", "bankAccountNumber": "****5678", "bankSortCode": "NOT EXPOSED YET", "monthsAtBank": 36, "replacingExistingLoan": false, "currentAddress": { "buildingNameOrNumber": "7", "street": "Church Street", "town": "CANNOCK", "county": "STAFFORDSHIRE", "postcode": "WS11 1DE", "months": 50, "status": "Private Tenant" }, "previousAddresses": [ ], "currentEmployment": { "employerName": "Test", "status": "Full Time", "jobTitle": "Middle manager", "monthlyIncome": { "amountGBP": 4800 }, "months": 42, "buildingNameOrNumber": "3", "street": "Church Street", "town": "CANNOCK", "county": "STAFFORDSHIRE", "postcode": "WS11 1DE" }, "previousEmployments": [ ] }, "financeTerms": { "productType": "HP", "termMonths": 24, "estimatedAnnualMileage": 6000, "cashPrice": { "amountGBP": 20000.0 }, "deposit": { "amountGBP": 3000.0 }, "partExchange": { "amountGBP": 0.0 }, "outstandingFinance": { "amountGBP": 0.0 } }, "consent": { "softCheck": "2024-03-04T13:36:24.042Z" } } ``` -------------------------------- ### Successful POST Request Example Source: https://developers.autotrader.co.uk/api This example demonstrates the structure of a successful POST request to the Trended Valuations API, including the endpoint and advertiser ID. ```http POST /valuations/trends?advertiserId=123456 HTTP/1.1 ``` -------------------------------- ### Finance Proposal Response Example Source: https://developers.autotrader.co.uk/api This is an example of the JSON response when retrieving finance proposals. It includes detailed information about the proposal, such as status, terms, and financial breakdown. ```json { "results": [ { "proposalId": "35d969a4-a435-4673-b1de-5c798c782e4c", "status": "Approved", "lastUpdated": "2023-06-23T14:00:03Z", "created": "2023-06-13T11:00:43Z", "lender": "Lender Name", "productType": "HP", "termMonths": 60, "contractLengthMonths": 62, "estimatedAnnualMileage": 45000, "cashPrice": { "amountGBP": 19000.0 }, "deposit": { "amountGBP": 0.0 }, "partExchange": { "amountGBP": 0.0 }, "outstandingFinance": { "amountGBP": 0.0 }, "balanceToFinance": { "amountGBP": 0.0 }, "monthlyRepayment": { "amountGBP": 1000.0 }, "totalPayments": { "amountGBP": 516.0 }, "totalAmountPayable": { "amountGBP": 2750.0 }, "totalChargesPayable": { "amountGBP": 0.0 }, "firstPayment": { "amountGBP": 29758.0 }, "finalPayment": { "amountGBP": 19000.0 }, "residualValue": { "amountGBP": 5896.0 }, "commission": { "amountGBP": 5896.0 }, "totalInterest": { "amountGBP": 5896.0 }, "apr": 0, "flatRate": 0, "fixedRateOfInterest": 0, "paidOutDate": "2023-07-13", "active": true, "fees": [ { "name": "Completion Fee", "cost": { "amountGBP": 50.0 }, "frequency": "In Final Payment", "type": "Document" } ], "conditions": [ { "condition": "A stipulation" } ], "allowsResend": false } ] } ``` -------------------------------- ### Future Valuations POST Request Example Source: https://developers.autotrader.co.uk/api Example of a POST request to the Future Valuations API, including the advertiserId query parameter. ```http POST /future-valuations?advertiserId=123456 HTTP/1.1 ``` -------------------------------- ### Competitor Search URL Example Source: https://developers.autotrader.co.uk/api An example URL for searching competitor adverts, including various search parameters. ```url "https://api.autotrader.co.uk/search?advertiserId=12345&&minPlate=67&maxPlate=67&standardMake=Volkswagen&standardModel=Passat&standardTrim=SE%20Business&minEnginePowerBHP=140&maxEnginePowerBHP=156&standardTransmissionType=Manual&standardFuelType=Diesel&standardBodyType=Estate&standardDrivetrain=Front%20Wheel%20Drive&doors=5&minBadgeEngineSizeLitres=2.0&maxBadgeEngineSizeLitres=2.0" ``` -------------------------------- ### Historic Valuations API POST Request Example Source: https://developers.autotrader.co.uk/api This example shows a successful POST request to the historic valuations API, including the advertiser ID. ```http POST /historic-valuations?advertiserId=123456 HTTP/1.1 ``` -------------------------------- ### GET Search Request Source: https://developers.autotrader.co.uk/api This is a sample GET request for searching vehicles. It includes an advertiser ID. ```http GET /search&advertiserId=123456 ``` -------------------------------- ### Vehicle Metrics POST Request Example Source: https://developers.autotrader.co.uk/api Example of a POST request to the Vehicle Metrics API, including the advertiserId query parameter. ```http POST /vehicle-metrics?advertiserId=123456 ``` -------------------------------- ### Example Makes Response Source: https://developers.autotrader.co.uk/api A successful response for listing makes includes make IDs and names. Common misspellings are handled. ```json { "makes": [ { "makeId": "2c9299d1712af419017130a7163969f4", "name": "Fiat" }, { "makeId": "2c9299017130a7163969f4d1712af419", "name": "Ford" } ... ] } ``` -------------------------------- ### Integrations API Request Example Source: https://developers.autotrader.co.uk/api A GET request to the Integrations API to retrieve a list of available integrations. This endpoint can be filtered by integration type using the 'types' parameter. ```http GET /integrations ``` -------------------------------- ### Image Resizing Example Source: https://developers.autotrader.co.uk/api Image URLs include a {resize} placeholder that can be replaced with desired dimensions (width x height) in pixels. Specifying a resize is best practice. ```text https://m-qa.atcdn.co.uk/a/media/w260h195/xxxx.jpg ``` ```text https://m-qa.atcdn.co.uk/a/media/w800h600/xxxx.jpg ``` -------------------------------- ### Get Valuation with Features Source: https://developers.autotrader.co.uk/api POST request to get a vehicle valuation adjusted with specific features. ```APIDOC ## POST /valuations?advertiserId={advertiserId} ### Description Retrieves a vehicle valuation adjusted by supplying specific vehicle features. ### Method POST ### Endpoint /valuations?advertiserId={advertiserId} ### Parameters #### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. #### Request Body - **vehicle** (object) - Required - Contains vehicle details. - **derivativeId** (string) - Required - The derivative ID of the vehicle. - **firstRegistrationDate** (string) - Required - The first registration date of the vehicle (YYYY-MM-DD). - **odometerReadingMiles** (integer) - Required - The odometer reading in miles. - **features** (array) - Optional - A list of features for the vehicle. - Each item in the array is an object with a **name** property (string). ### Request Example ```json { "vehicle": { "derivativeId": "c1ABC1231651635wxb", "firstRegistrationDate": "2014-09-08", "odometerReadingMiles": 8000 }, "features": [ { "name": "60/40 Split Back and Fixed Cushion" }, { "name": "Air Conditioning - Manual" }, { "name": "DAB Radio/CD and Ford SYNC" }, { "name": "16in 12 - Spoke Alloy Wheels" } ] } ``` ### Response #### Success Response (200) - **valuations** (object) - Contains valuation data for different categories (same structure as basic valuation). ### Response Example ```json { "valuations": { "trade": { "amountGBP": 2217, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "partExchange": { "amountGBP": 2120, "amountExcludingVatGBP": null }, "retail": { "amountGBP": 4007, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "private": { "amountGBP": 3100 } } } ``` ``` -------------------------------- ### Example Successful Prices Response Source: https://developers.autotrader.co.uk/api A successful response includes a list of prices with effective dates, basic prices, VAT prices, and delivery prices. ```json { "prices": [ { "effectiveFrom": "2020-06-01", "effectiveTo": "2020-10-01", "basicPrice": 23345.83, "vatPrice": 4669.17, "deliveryPrice": 550.0, "vatDeliveryPrice": 110.0 }, { "effectiveFrom": "2020-10-01", "effectiveTo": null, "basicPrice": 23345.83, "vatPrice": 4669.17, "deliveryPrice": 550.0, "vatDeliveryPrice": 110.0 } ] } ``` -------------------------------- ### Get Basic Valuation Source: https://developers.autotrader.co.uk/api POST request to get a basic vehicle valuation using derivativeId, firstRegistrationDate, and odometerReadingMiles. ```APIDOC ## POST /valuations?advertiserId={advertiserId} ### Description Retrieves a basic vehicle valuation. ### Method POST ### Endpoint /valuations?advertiserId={advertiserId} ### Parameters #### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. #### Request Body - **vehicle** (object) - Required - Contains vehicle details. - **derivativeId** (string) - Required - The derivative ID of the vehicle. - **firstRegistrationDate** (string) - Required - The first registration date of the vehicle (YYYY-MM-DD). - **odometerReadingMiles** (integer) - Required - The odometer reading in miles. ### Request Example ```json { "vehicle": { "derivativeId": "ABC1234DEF", "firstRegistrationDate": "2013-03-30", "odometerReadingMiles": 14122 } } ``` ### Response #### Success Response (200) - **valuations** (object) - Contains valuation data for different categories. - **trade** (object) - Trade valuation. - **amountGBP** (number) - The trade amount in GBP. - **amountExcludingVatGBP** (number | null) - The trade amount excluding VAT in GBP. - **amountNoVatGBP** (number | null) - The trade amount with no VAT in GBP. - **partExchange** (object) - Part exchange valuation. - **amountGBP** (number) - The part exchange amount in GBP. - **amountExcludingVatGBP** (number | null) - The part exchange amount excluding VAT in GBP. - **retail** (object) - Retail valuation. - **amountGBP** (number) - The retail amount in GBP. - **amountExcludingVatGBP** (number | null) - The retail amount excluding VAT in GBP. - **amountNoVatGBP** (number | null) - The retail amount with no VAT in GBP. - **private** (object) - Private valuation. - **amountGBP** (number) - The private amount in GBP. ### Response Example ```json { "valuations": { "trade": { "amountGBP": 2217, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "partExchange": { "amountGBP": 2120, "amountExcludingVatGBP": null }, "retail": { "amountGBP": 4007, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "private": { "amountGBP": 3100 } } } ``` ``` -------------------------------- ### Example Models Response Source: https://developers.autotrader.co.uk/api A successful response for listing models includes model IDs and names. Common misspellings are handled. ```json { "models": [ { "modelId": "2c9299d1712af419017130a7163969f4", "name": "Fiesta" }, { "modelId": "2c9299017130a7163969f4d1712af419", "name": "Mondeo" } ... ] } ``` -------------------------------- ### Get Finance Application GET Request Source: https://developers.autotrader.co.uk/api Retrieve the details of a specific finance application using its ID. Ensure to include the advertiserId. ```http GET /finance/applications/{applicationId}?advertiserId=123456 ``` -------------------------------- ### Complete Stock Resource Example Source: https://developers.autotrader.co.uk/api This JSON object represents a complete stock resource with realistically populated values. It includes all sections like vehicle, advertiser, adverts, metadata, features, media, history, and check. ```json { "stock": [ { "vehicle": { "odometerReadingMiles": 10000, "ownershipCondition": "Used", "registration": "AB12 CDE", "vin": "WAUZXXXXXXXXX12345", "engineNumber": "CZDA098683", "make": "Audi", "model": "A3", "generation": "Saloon (2020 - )", "derivative": "2.0 TDI 35 Sport Saloon 4dr Diesel S Tronic Euro 6 (s/s) (150 ps)", "derivativeId": "c8be64b89ccb445391c1c3c6d5e57fe5", "vehicleType": "Car", "trim": "Black Edition", "bodyType": "Saloon", "fuelType": "Diesel", "cabType": null, "transmissionType": "Automatic", "wheelbaseType": "LWB", "roofHeightType": "H2", "drivetrain": "Four Wheel Drive", "wheelchairAccessible": "Y", "seats": 5, "doors": 3, "valves": 16, "engineTorqueNM": 400, "co2EmissionGPKM": 102, "topSpeedMPH": 125, "zeroToSixtyMPHSeconds": 8.7, "zeroToOneHundredKPHSeconds": 8.9, "badgeEngineSizeLitres": 2.0, "badgeEngineSizeCC": 750, "engineCapacityCC": 1998, "enginePowerBHP": 129, "enginePowerPS": 129, "fuelCapacityLitres": 58, "batteryRangeMiles": 160, "batteryCapacityKWH": 160, "batteryUsableCapacityKWH": 160 }, "advertiser": { "referenceId": "a1b2c3d4-e5f6-7890-1234-567890abcdef" }, "adverts": [ { "price": { "amount": 15000, "currency": "GBP" }, "type": "Retail", "options": { "delivery": true, "finance": true } } ], "metadata": { "id": "f0e9d8c7-b6a5-4321-0987-654321fedcba", "dateCreated": "2023-01-01T10:00:00Z", "dateUpdated": "2023-01-01T10:00:00Z" }, "features": [ { "type": "Standard", "name": "Air Conditioning" }, { "type": "Optional", "name": "Sunroof" } ], "media": [ { "type": "Image", "url": "http://example.com/image.jpg" } ], "history": { "previousOwners": 1 }, "check": { "exported": false, "privateFinance": null, "tradeFinance": null, "highRisk": null, "mileageDiscrepancy": null, "colourChanged": null, "registrationChanged": null, "previousOwners": 1 } } ], "totalResults": 1 } ``` -------------------------------- ### GET Search Features Request Source: https://developers.autotrader.co.uk/api This is a sample GET request to retrieve features for a specific search ID. It requires an advertiser ID. ```http GET /search/{searchId}/features?advertiserId=1234 ``` -------------------------------- ### Production Environment URL Source: https://developers.autotrader.co.uk/api Use this URL for live operations in the production environment. ```text https://api.autotrader.co.uk/stock ``` -------------------------------- ### Production Environment URL Source: https://developers.autotrader.co.uk/api Use this URL for live operations in the production environment. ```text https://api.autotrader.co.uk/deals ``` -------------------------------- ### Get Messages Source: https://developers.autotrader.co.uk/api Retrieve all messages for a specific deal using a GET request to the /messages/{messagesId} endpoint. The response includes read statuses and message history. ```http GET /messages/{messagesId}?advertiserId=123456 ``` ```json { "messagesId": "4ae0fc61-f92f-4fa6-9cd5-a8f31a2616c7", "consumerLastRead": "2023-05-02T18:58:39.608Z", "consumerLastReadStatus": "Read", "advertiserLastRead": "2023-05-02T18:58:54.398Z", "advertiserLastReadStatus": "Unread", "messages": [ { "from": "Consumer", "at": "2023-04-27T13:49:46.624Z", "message": "I'll decide later on delivery. Please could you contact me back?" }, { "from": "Advertiser", "at": "2023-05-02T18:55:26.469Z", "message": "I've called and left a message. Will try again after lunch." }, { "from": "Consumer", "at": "2023-05-02T19:00:49.194Z", "message": "What time do you close tonight?" } ] } ``` -------------------------------- ### Sandbox Environment URL Source: https://developers.autotrader.co.uk/api Use this URL for testing and development in the sandbox environment. ```text https://api-sandbox.autotrader.co.uk/stock ``` -------------------------------- ### Sandbox Environment URL Source: https://developers.autotrader.co.uk/api Use this URL for testing and development in the sandbox environment. ```text https://api-sandbox.autotrader.co.uk/deals ``` -------------------------------- ### Get Valuation with Price Indicator Rating Source: https://developers.autotrader.co.uk/api POST request to get a vehicle valuation including a price indicator rating by providing retail advert price. ```APIDOC ## POST /valuations?advertiserId={advertiserId} ### Description Retrieves a vehicle valuation and includes a price indicator rating if retail advert price is provided. ### Method POST ### Endpoint /valuations?advertiserId={advertiserId} ### Parameters #### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. #### Request Body - **vehicle** (object) - Required - Contains vehicle details. - **derivativeId** (string) - Required - The derivative ID of the vehicle. - **firstRegistrationDate** (string) - Required - The first registration date of the vehicle (YYYY-MM-DD). - **odometerReadingMiles** (integer) - Required - The odometer reading in miles. - **adverts** (object) - Optional - Contains advert details. - **retailAdverts** (object) - Optional - Contains retail advert details. - **price** (object) - Required if price indicator rating is desired. - **amountGBP** (number) - Required - The retail price in GBP. ### Request Example ```json { "vehicle": { "derivativeId": "9f46a95611bb42aa8e0750b6b673351a", "firstRegistrationDate": "2024-03-30", "odometerReadingMiles": 14122 }, "adverts": { "retailAdverts": { "price": { "amountGBP": 14817 } } } } ``` ### Response #### Success Response (200) - **valuations** (object) - Contains valuation data for different categories. - **trade** (object) - Trade valuation. - **amountGBP** (number) - The trade amount in GBP. - **amountExcludingVatGBP** (number | null) - The trade amount excluding VAT in GBP. - **amountNoVatGBP** (number | null) - The trade amount with no VAT in GBP. - **partExchange** (object) - Part exchange valuation. - **amountGBP** (number) - The part exchange amount in GBP. - **amountExcludingVatGBP** (number | null) - The part exchange amount excluding VAT in GBP. - **retail** (object) - Retail valuation. - **amountGBP** (number) - The retail amount in GBP. - **amountExcludingVatGBP** (number | null) - The retail amount excluding VAT in GBP. - **amountNoVatGBP** (number | null) - The retail amount with no VAT in GBP. - **priceIndicatorRating** (string) - The price indicator rating (e.g., LOW, GREAT, GOOD, FAIR, HIGH). - **priceIndicatorRatingBands** (object) - Bands for the price indicator rating. - **LOW** (object) - Band for LOW rating. - **from** (number) - Minimum value for the LOW band. - **to** (number) - Maximum value for the LOW band. - **GREAT** (object) - Band for GREAT rating. - **from** (number) - Minimum value for the GREAT band. - **to** (number) - Maximum value for the GREAT band. - **GOOD** (object) - Band for GOOD rating. - **from** (number) - Minimum value for the GOOD band. - **to** (number) - Maximum value for the GOOD band. - **FAIR** (object) - Band for FAIR rating. - **from** (number) - Minimum value for the FAIR band. - **to** (number) - Maximum value for the FAIR band. - **HIGH** (object) - Band for HIGH rating. - **from** (number) - Minimum value for the HIGH band. - **to** (number) - Maximum value for the HIGH band. - **private** (object) - Private valuation. - **amountGBP** (number) - The private amount in GBP. ### Response Example ```json { "valuations": { "trade": { "amountGBP": 19204, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "partExchange": { "amountGBP": 19105, "amountExcludingVatGBP": null, "amountNoVatGBP": null }, "retail": { "amountGBP": 22121, "amountExcludingVatGBP": null, "amountNoVatGBP": null, "priceIndicatorRating": "LOW", "priceIndicatorRatingBands": { "LOW": { "from": 1500, "to": 21015 }, "GREAT": { "from": 21015, "to": 21679 }, "GOOD": { "from": 21679, "to": 22785 }, "FAIR": { "from": 22785, "to": 23891 }, "HIGH": { "from": 23891, "to": 70000 } } }, "private": { "amountGBP": 20020 } } } ``` ``` -------------------------------- ### Integrations API Response Example Source: https://developers.autotrader.co.uk/api This JSON response shows a list of integrations, including their IDs, names, types, and capabilities. The 'capabilities.name' field indicates specific features like 'Stock Sync' or 'Availability Updates'. ```json { "results": [ { "integrationId": "E32ACB32-0819-4FC1-9C0F-C5CA7E2xxxxx", "name": "API Test", "type": "API", "capabilities": [ { "name": "Stock Sync" }, { "name": "Availability Updates" } ] }, { "integrationId": "4701ce43a7b94db8a74d52924c0aaxxx", "name": "Data Feed Test", "type": "Datafeed", "datafeedType": "Advert" }, { "integrationId": "4745ce43a7b94db8a74d52924c0xxx", "name": "Stock Export Test", "type": "Stock Export", "stockExportType": null } ] } ``` -------------------------------- ### Example Successful Features Response Source: https://developers.autotrader.co.uk/api A successful response includes a list of features with their names, types, categories, and pricing details. ```json { "features": [ { "name": "1 x SDXC Card Reader", "type": "Standard", "category": "Audio and Communications", "genericName": "Audio and Communications", "basicPrice": 0.0, "vatPrice": 0.0, "factoryCodes": [ ], "rarityRating": null, "valueRating": null }, { "name": "Apex Grey", "genericName": "Grey", "type": "Optional", "category": "Paint", "basicPrice": 3062.5, "vatPrice": 612.5, "factoryCodes": [ "P7P7" ], "rarityRating": null, "valueRating": null, "genericFinish": "Special Solid Paint", "finish": "Racing Line" }, { "name": "16in Alloy Wheels - 10-Spoke Design", "type": "Optional", "category": "Exterior", "genericName": "Wheels & Tyres", "basicPrice": 208.33, "vatPrice": 41.67, "factoryCodes": [ "IW3" ], "rarityRating": null, "valueRating": "High Value" } ] } ``` -------------------------------- ### GET Electric Vehicle Charge Times Request Source: https://developers.autotrader.co.uk/api This is a sample GET request to retrieve charge times for an electric vehicle. It requires a search ID and advertiser ID. ```http GET /search/{searchId}/charge-times?advertiserId=1234 ``` -------------------------------- ### Getting Call Information Source: https://developers.autotrader.co.uk/api Retrieves details of a call on a deal. ```APIDOC ## GET /calls/{callId}?advertiserId=123456 ### Description Retrieves details of a call on a deal on the Autotrader platform. ### Method GET ### Endpoint /calls/{callId} ### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. ### Response #### Success Response (200) - **callsId** (string) - Unique Id associated with the calls details. - **calls** (array) - A list of call objects. - **at** (string) - The date time of the call. - **status** (string) - Status of the call. Possible values: ANSWERED, NOT ANSWERED. - **hasRecording** (boolean) - Indicates if the call has been recorded. - **durationSeconds** (integer) - Duration of the call in seconds. ### Response Example ```json { "callsId": "ad07cfda-4d02-4068-b7a4-9af6132311a0", "calls": [ { "at": "2025-01-13T12:54:27Z", "status": "ANSWERED", "hasRecording": true, "durationSeconds": 14 } ] } ``` ``` -------------------------------- ### Create Stock Record Source: https://developers.autotrader.co.uk/api Use POST to create a new stock record. The complete stock model is returned in the response. ```http POST /stock?advertiserId=123456 ``` -------------------------------- ### Getting Messages Source: https://developers.autotrader.co.uk/api Retrieves all messages associated with a specific deal. ```APIDOC ## Getting Messages ### Method GET ### Endpoint /messages/{messagesId}?advertiserId={advertiserId} ### Description Retrieves messages for a given deal. ### Response #### Success Response (200) - **messagesId** (string) - The ID of the message thread. - **consumerLastRead** (string) - Timestamp when the consumer last read messages. - **consumerLastReadStatus** (string) - Status of consumer read (e.g., "Read", "Unread"). - **advertiserLastRead** (string) - Timestamp when the advertiser last read messages. - **advertiserLastReadStatus** (string) - Status of advertiser read (e.g., "Read", "Unread"). - **messages** (array) - An array of message objects. - **from** (string) - Sender of the message (e.g., "Consumer", "Advertiser"). - **at** (string) - Timestamp when the message was sent. - **message** (string) - Content of the message. ``` -------------------------------- ### Adding a Finance Application Source: https://developers.autotrader.co.uk/api POST a finance application to a deal. The request must include at least the DealId, Title, First Name, Last Name, Email, Product Type, Term Months, Estimated Annual Mileage, Cash Price, and Deposit. Additional fields can be included. ```APIDOC ## POST /finance/applications?advertiserId=123456 ### Description Adds a finance application to a deal. ### Method POST ### Endpoint /finance/applications ### Parameters #### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. ### Request Body - **dealId** (string) - Required - The ID of the deal. - **applicant** (object) - Required - Information about the applicant. - **title** (string) - Required - The applicant's title (e.g., MR, MS). - **firstName** (string) - Required - The applicant's first name. - **lastName** (string) - Required - The applicant's last name. - **email** (string) - Required - The applicant's email address. - **financeTerms** (object) - Required - Details of the finance terms. - **productType** (string) - Required - The type of finance product (e.g., HP). - **termMonths** (integer) - Required - The finance term in months. - **estimatedAnnualMileage** (integer) - Required - The estimated annual mileage. - **cashPrice** (object) - Required - The cash price of the item. - **amountGBP** (number) - Required - The amount in GBP. - **deposit** (object) - Required - The deposit amount. - **amountGBP** (number) - Required - The amount in GBP. ### Request Example ```json { "dealId": "21f9f643-2251-49da-8b0a-5ee578882a30", "applicant": { "title": "MR", "firstName": "James", "lastName": "Smith", "email": "Jamessmith@aol.co.uk" }, "financeTerms": { "productType": "HP", "termMonths": 24, "estimatedAnnualMileage": 6000, "cashPrice": { "amountGBP": 20000 }, "deposit": { "amountGBP": 3000 } } } ``` ### Response #### Success Response (200) - **applicationId** (string) - The ID of the created finance application. - **status** (string) - The status of the finance application (e.g., "Not Proposed"). - **applicant** (object) - Details of the applicant. - **financeTerms** (object) - Details of the finance terms. - **consent** (object) - Consent details. #### Response Example ```json { "applicationId": "4c21a14d-e7eb-436c-bcaf-39d07c324b64", "status": "Not Proposed", "applicant": { "title": "MR", "firstName": "James", "lastName": "Smith", "email": "Jamessmith@aol.co.uk", "mobile": null, "dateOfBirth": null, "gender": null, "nationalityCode": null, "maritalStatus": null, "drivingLicenceType": null, "changeInCircumstances": null, "numberOfDependants": null, "monthlyChildcare": { "amountGBP": null }, "monthlyRentOrMortgage": { "amountGBP": null }, "bankAccountHolderName": null, "bankAccountNumber": null, "bankSortCode": "NOT EXPOSED YET", "monthsAtBank": null, "replacingExistingLoan": false, "currentAddress": null, "previousAddresses": [], "currentEmployment": null, "previousEmployments": [] }, "financeTerms": { "productType": "HP", "termMonths": 24, "estimatedAnnualMileage": 6000, "cashPrice": { "amountGBP": 20000.0 }, "deposit": { "amountGBP": 3000.0 }, "partExchange": { "amountGBP": 0.0 }, "outstandingFinance": { "amountGBP": 0.0 } }, "consent": { "softCheck": null } } ``` ``` -------------------------------- ### Getting Delivery Information Source: https://developers.autotrader.co.uk/api Retrieves the complete delivery resource for a given delivery ID. ```APIDOC ## GET /delivery/{deliveryId}?advertiserId=123456 ### Description Retrieves the complete delivery resource with realistically populated values. ### Method GET ### Endpoint /delivery/{deliveryId} ### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. ### Response #### Success Response (200) - **deliveryId** (string) - Unique Id associated with the delivery details of an item. - **method** (string) - Method of delivering the stock item. Supported methods: Home Delivery, Click and Collect, and Decide Later. - **postcode** (string) - Postcode of delivery/pickup. ### Response Example ```json { "deliveryId": "ad07cfda-4d02-4068-b7a4-9af6132311a1", "method": "Home Delivery", "postcode": "M154FN" } ``` ``` -------------------------------- ### Get Part Exchange Source: https://developers.autotrader.co.uk/api Retrieves the complete part exchange resource for a given partExchangeId. ```APIDOC ## GET /part-exchange/{partExchangeId}?advertiserId=123456 ### Description Retrieves the complete part exchange resource. ### Method GET ### Endpoint /part-exchange/{partExchangeId} ### Parameters #### Query Parameters - **advertiserId** (string) - Required - The ID of the advertiser. ### Response #### Success Response (200) - **partExchangeId** (string) - Unique id of part exchange. - **updated** (string) - Date and time of the last update. - **vehicle** (object) - Details of the part exchange vehicle. - **registration** (string) - Registration number of part exchange vehicle. - **make** (string) - Make of part exchange vehicle. - **model** (string) - Model of part exchange vehicle. - **derivative** (string) - Derivation of part exchange vehicle. - **derivativeId** (string) - The Autotrader derivativeId. - **firstRegistrationDate** (string) - The date vehicle was registered in the UK at DVLA. - **odometerReadingMiles** (number) - The current odometer reading in miles of part exchange vehicle. - **colour** (string) - The part exchange vehicle colour. - **modifications** (string) - The after market modifications identified on the part exchange vehicle. This field is valid only for commercial vehicles. - **features** (array) - The optional extra features identified on the part exchange vehicle. - **outstandingFinance** (object) - The amount of outstanding finance on the part exchange vehicle. - **lender** (string) - The lender of the outstanding finance. - **amountGBP** (number) - The amount of outstanding finance in GBP. - **consumer** (object) - Consumer-related information. - **conditionRating** (string) - The condition rating of the part exchange vehicle. - **partExchangeValuation** (object) - The part exchange valuation provided to the consumer. - **amountGBP** (number) - Autotrader part exchange valuation that the consumer received. - **expires** (string) - The expiry date and time of the valuation. - **advertiser** (object) - Advertiser-related information. - **conditionRating** (string) - The condition rating of the part exchange vehicle. - **offer** (object) - The advertiser's offer for the part exchange. - **amountGBP** (number) - The advertiser's offer amount in GBP. ### Response Example ```json { "partExchangeId": "87fd5f48-56bc-47f3-b5ac-f722c271687c", "updated": "2023-04-27T13:49:46.624Z", "vehicle": { "registration": "YY12RRR", "make": "Ford", "model": "Mondeo", "derivative": "130 TDCI Zetec", "derivativeId": "7af67f955cbf4f14b8adfa3c5c1c4f9f", "firstRegistrationDate": "2018-04-30", "odometerReadingMiles": 12000, "colour": "White", "features": [ { "name": "Adaptive LED Headlights with High-Beam Assistant" }, { "name": "Drive Performance Control with ECO PRO - Comfort and Sport Modes" } ], "outstandingFinance": { "lender": "Advantage", "amountGBP": 5555 }, "modifications": "null" }, "consumer": { "conditionRating": "Good", "partExchangeValuation": { "amountGBP": 25625, "expires": "2023-05-27T11:48:46.624Z" } }, "advertiser": { "conditionRating": "Poor", "offer": { "amountGBP": 24900 } } } ``` ```