A simple format for car listings
One file a dealership publishes and any marketplace or aggregator can read.
One file
Dealer, facilities and cars travel together in a single JSON dataset any consumer can read out of the box.
Multi-location
Showrooms, service centers, warehouses, delivery points and offices, with cars linked to the facility that holds them.
Built on Fairspec
Every cardealer dataset is also a valid Fairspec dataset, validated by JSON Schema Draft 2020-12.
Versioned
Published profiles and schemas never change; each release gets its own immutable URL.
dataset.json
{
"$schema": "https://datisthq.github.io/cardealer/profiles/latest/dataset.json",
"resources": [
{
"name": "dealer",
"tableSchema": "https://datisthq.github.io/cardealer/schemas/latest/dealer.json",
"data": [
{
"title": "Premium Auto Sales",
"country": "United States",
"region": "California",
"city": "Los Angeles",
"address": "1234 Sunset Boulevard",
"url": "https://www.premiumauto.com"
}
]
},
{
"name": "car",
"tableSchema": "https://datisthq.github.io/cardealer/schemas/latest/car.json",
"data": [
{
"title": "2023 Tesla Model 3 Long Range",
"brand": "Tesla",
"model": "Model 3",
"year": 2023,
"price": 45990,
"currency": "USD"
}
]
}
]
}Libraries for every stack
Three hand-written twins on the Fairspec base libraries, kept equal by one conformance suite.
Conformance
Language-neutral JSON cases every library runs, so the three never drift apart.
Write in one language. Read in another.
A dataset published from TypeScript validates the same way in Python and Rust.
publish.ts
import { writeFile } from "node:fs/promises"
import { Dataset, VERSION } from "cardealer"
const dataset = Dataset.parse({
$schema: `https://datisthq.github.io/cardealer/profiles/${VERSION}/dataset.json`,
resources: [
{
name: "dealer",
tableSchema: `https://datisthq.github.io/cardealer/schemas/${VERSION}/dealer.json`,
data: [{ title: "Premium Auto Sales", city: "Los Angeles" }],
},
],
})
await writeFile("dataset.json", JSON.stringify(dataset, null, 2))consume.py
import json
from cardealer import Dataset
with open("dataset.json") as file:
dataset = Dataset.model_validate(json.load(file))
for resource in dataset.resources:
print(resource.name)Publish your listings. Start with one JSON file.
Read the format, drop in an example, and have your dealer feed shareable in minutes.