To access Edmunds content, REST APIs are used to retrieve a JSON data object that contains
a rich set of content elements that can be parsed and integrated into your website. The APIs are
located at a web address that begins with https://api.edmunds.com/
and ends with a text string
containing the unique API key provided for your dealership, e.g,
&api_key=ar355ajjgkz5pxxv5g3dfakx
. It is important that every URL you construct contains
this key string otherwise no content will be returned.
The process for using the API is as follows:
Properly formatted URL:
https://api.edmunds.com/api/editorial/v3/makes/{make}/models/{model}/years/{year}/expertcontent?api_key={api key}
The tokens in yellow should be replaced with actual values for the content you are looking for:
Parameter | Description | Example |
---|---|---|
{make} |
make of the vehicle | honda |
{model} |
model of the vehicle | civic |
{year} |
model year of the vehicle | 2019 |
{api key} |
custom api key provided for your dealership | ar355ajjgkz5pxxv5g3dfakx |
https://api.edmunds.com/api/editorial/v3/makes/mercedes-benz/models/amg-gt/years/2020/expertcontent?api_key=ar355ajjgkz5pxxv5g3dfakx
Example URL to retrieve content for a 2020 Mercedes-Benz AMG GT (note: replace the api key value with your dealership api key that was provided to get this sample URL to work)
The correct values to use for {make}
(e.g., Honda = “honda”) and {model}
(e.g., Civic = “civic”) can generally be intuited but, if you are uncertain about the correct value to use, you can look up the precise value for any make and model by using the following URL which returns the “niceName” values for make & model:
URL for getting the correct makes and models values for a given year:
https://api.edmunds.com/api/vehicle/v2/makes?fmt=json&year={year}&api_key={api key}
… where {year} represents the year in which you would like to see all active models of a make:
Snippet of the response returned when using
|
The desired content is contained in the JSON object that is returned from the URL you constructed. The JSON object contains 4 nested JSON objects for the make-model’s (1) review summary, (2) vehicle scorecard, (3) pros and cons, (4) safety information.
{
"vehicleReview": {object},
"youTubeVideo": {object},
"safety": {object},
"featuresSpecs": {object},
"edmundsBackLink": "https://www.edmunds.com/mercedes-benz/amg-gt/2020/#subnav-consumer-reviews"
}
Once the content elements have been retrieved, the data can be integrated into your website. The following sections describe how the content might be used:
The review summary is the intro to the Edmunds review of a vehicle. This summary includes highlights of the vehicle and other make/model information.
{
"id": "/toyota/camry/2019/review",
"title": "2019 Toyota Camry Review",
"subtitle": "",
"updated": "2018-09-28T12:00:00",
"published": "2018-09-28T12:00:00",
"metaDescription": "",
"review": {
"summary": "<p>Crossover SUVs might be all the rage, but there is still something to be said for the tried-and-true midsize sedan. Exhibit A: the 2019 Toyota Camry. Coming off a redesign just last year, the Camry is a spacious, fuel-efficient sedan with lots of standard safety equipment and plenty of options to choose from. </p><p>As has been the case for a while, you can get the Camry with a four-cylinder engine or a more powerful V6, or you can get the miserly <a href=\"/toyota/camry-hybrid/2019/sedan/\">Camry Hybrid</a>. On the highway, the Camry is comfortable and compliant. Toyota also offers two sporty versions that infuse the Camry with a bit of extra personality. Inside, the Camry offers a simple yet feature-packed cabin, especially if you go with one of the upper trim levels. There are plenty of options to choose from along the way. </p><p>The 2019 Toyota Camry is as competent as they come. It's well-priced on the whole, and modern feature content makes it supremely easy to drive. If you're looking for something with a bit more class and space than a small sedan, the Toyota Camry might just be the sedan for you.</p><p>Notably, we picked the 2019 Camry as one of Edmunds' <a href=\"/sedan/articles/best-midsize-sedans/\" title=\"Best Midsize Sedans\">Best Midsize Sedans</a> for this year.</p>",
"summarySnippet": "",
"pros": [
"Strong fuel economy from four-cylinder engine",
"Plenty of cabin and cargo space",
"Impressively easy car to drive"
],
"cons": [
"Subpar infotainment and smartphone integration ",
"Engine noise is prominent during acceleration",
"Advanced driver aids can be overly sensitive"
]
}
}
As part of the Edmunds review, we provide a scorecard for a vehicle. This scorecard gives a value for important categories including driving, comfort, interior, utility and more.
|
This section of the API contains the pros and cons of a make/model.
|
The safety information within the API highlights certain key safety features of a make/model.
{
...
"misc": {
"id": "misc",
"title": "",
"summary": "",
"promoBlurb": "",
"calloutQuote": "Practical, fuel-efficient and spacious: The 2019 Camry is a seriously well-rounded midsize sedan. ",
"whatsNew": "",
"safetyFeatures": [
{
"title": "Pre-Collision System ",
"description": "Mitigates or helps avoid a potential crash via audio and visual alerts and brake assistance. "
},
{
"title": "Lane Departure Alert",
"description": "Sounds an audio alert when it thinks the car is going to drift out of its lane."
},
{
"title": "Automatic High Beams",
"description": "Switches the headlights' high beams on and off when the system deems appropriate."
}
],
...
},
...
}
Videos for a Year Make Model may be embedded through the API. Each year Make Model call will present you with “all” videos Edmunds has uploaded to YouTube.
API Code Example:
{
...
"youTubeVideo": {
"embedCode": "<iframe allowfullscreen=\"1\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" title=\"YouTube video player\" src=\"https://www.youtube.com/embed/pGUHiggeU2c?rel=0\" width=\"100%\" height=\"100%\" frameborder=\"0\"></iframe>"
},
...
}
The dealer ratings and reviews integration will allow you to pull Edmunds’ rating for a dealership along with it’s reviews.
https://api.edmunds.com/v1/api/drrrepository/getdrrbydealerid?dealerid={dealership ID}&fmt=json&api_key={api key}
API Code Example:
<html>
<head>
<meta charset=utf-8>
<title>Edmunds API Example</title>
</head>
<body>
<div id="results-body"></div>
<script>
window.sdkAsyncInit = function() {
// Instantiate the SDK
var res = new EDMUNDSAPI('YOUR API KEY');
// Optional parameters
var options = {
"dealerid": "26811",
"limit": "0,5"
};
// Callback function to be called when the API response is returned
function success(res) {
var body = document.getElementById('results-body');
body.innerHTML = "This dealer's name is : " + res.dealerName;
}
// Oops, Houston we have a problem!
function fail(data) {
console.log(data);
}
// Fire the API call
res.api('/v1/api/drrrepository/getdrrbydealerid', options, success, fail);
// Additional initialization code such as adding Event Listeners goes here
};
// Load the SDK asynchronously
(function(d, s, id) {
var js, sdkjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) {return;}
js = d.createElement(s); js.id = id;
js.src = "path/to/sdk/file";
sdkjs.parentNode.insertBefore(js, sdkjs);
}(document, 'script', 'edmunds-jssdk'));
</script>
</body>
</html>
Edmunds is making the above content available to you, as a dealer partner to whom we have provided a unique API key, to assist you in enhancing your dealership’s website through the display of our content to consumers. By using our API and the content it returns, you agree to use it only for that purpose and as described in these terms of use, and not to sell, lease, license, sublicense, share or otherwise transfer your API key or any content returned by the API to any third party without our prior written consent.
You understand and agree that it is a condition of your access to our API and your use of our content that you do not change, alter or modify our content, including any related attribution (such as our name or logo) or link, returned to you by the API. You agree that you will not include rel-“nofollow” when rendering hyperlinked content returned by our API. We may immediately terminate your access, and require you to cease all use of our content, if you fail to comply with these requirements or otherwise fail to comply with these terms of use or applicable law. You agree to defend, indemnify and hold us harmless against any claims, losses, liabilities, costs or expenses arising out of your failure to comply with these terms of use or applicable law.
You may cache and thus store the content returned through our API for up to 30 days for the purpose described in these terms of use, after which such content must be purged. Subject to that exception, you may not copy, store or archive our content.
Edmunds reserves the right to modify the functionality of our API, and to change the content returned by it, at any time without notice to you. You acknowledge and agree that Edmunds may limit the number of queries to our API that may be submitted by your dealership per day.
EDMUNDS EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES OF ANY KIND OR NATURE, WHETHER EXPRESS, IMPLIED OR STATUTORY, RELATING TO THE EDMUNDS API OR CONTENT, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. In addition, Edmunds makes no representation or warranty that our API, our content, including any attribution or links, or the operation of our website will be uninterrupted or error-free, or that the content will be complete, accurate or error-free, and Edmunds will not be liable for the consequences of any interruptions or errors.
EDMUNDS WILL NOT BE LIABLE FOR ANY LOST PROFITS, OR FOR ANY INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, INCLUDING DAMAGES FOR LOST DATA, HOWEVER CAUSED AND UNDER ANY THEORY OF LIABILITY, INCLUDING BUT NOT LIMITED TO CONTRACT, PRODUCTS LIABILITY, STRICT LIABILITY AND NEGLIGENCE, AND WHETHER OR NOT EDMUNDS WAS OR SHOULD HAVE BEEN AWARE OR ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
You acknowledge and agree that Edmunds is the exclusive owner of, and we are not granting you any right, title or interest in or to, any of our intellectual property (including our API, name, logo, content and the links we provide through the API), and you may not access or use it except as described in these terms of use. Without limiting the foregoing, you may not use our name or logo to suggest that we endorse, recommend or are otherwise responsible for your or any third party’s products, services or content. You also acknowledge and agree that your purchase of traffic involving key words that are identical or similar to our name or any of our trade names, trademarks, etc. constitute trademark infringement.