Che168.com API Reference
🔑 Authentication
All API requests require authentication using your API key:
Authorization: Bearer {api_key}
📋 Endpoints
Endpoint | Method | Description |
---|---|---|
/vehicles | GET | Get vehicle listings |
/vehicle/[id] | GET | Get detailed vehicle information |
/dealers | GET | Get dealer listings |
/dealer/[id] | GET | Get dealer information |
/brands | GET | Get available brands |
/models/[brand] | GET | Get models for a specific brand |
/price-history/[id] | GET | Get price history for a vehicle |
/market-stats | GET | Get market statistics |
🚗 Vehicle Endpoints
GET /vehicles
Get a list of vehicle listings with optional filtering.
Parameters:
Parameter | Type | Required | Description |
---|---|---|---|
brand | string | No | Filter by brand |
model | string | No | Filter by model |
year_min | number | No | Minimum year |
year_max | number | No | Maximum year |
price_min | number | No | Minimum price |
price_max | number | No | Maximum price |
location | string | No | Filter by location |
limit | number | No | Number of results (max 100) |
offset | number | No | Pagination offset |
Example Request:
curl -X GET "https://api.carapis.com/che168/vehicles?brand=Toyota&year_min=2020&limit=10" \
-H "Authorization: Bearer {api_key}"
Example Response:
{
"success": true,
"data": {
"vehicles": [
{
"id": "12345",
"title": "Toyota Camry 2022",
"brand": "Toyota",
"model": "Camry",
"year": 2022,
"price": 25000,
"mileage": 15000,
"location": "Beijing",
"dealer_id": "dealer_123",
"images": ["url1", "url2"],
"features": ["Leather Seats", "Navigation"],
"created_at": "2024-01-15T10:30:00Z"
}
],
"total": 150,
"limit": 10,
"offset": 0
}
}
GET /vehicle/[id]
Get detailed information about a specific vehicle.
Example Request:
curl -X GET "https://api.carapis.com/che168/vehicle/12345" \
-H "Authorization: Bearer {api_key}"
Example Response:
{
"success": true,
"data": {
"id": "12345",
"title": "Toyota Camry 2022",
"brand": "Toyota",
"model": "Camry",
"year": 2022,
"price": 25000,
"original_price": 28000,
"mileage": 15000,
"fuel_type": "Gasoline",
"transmission": "Automatic",
"engine_size": "2.5L",
"color": "White",
"location": "Beijing",
"dealer": {
"id": "dealer_123",
"name": "Beijing Auto Center",
"rating": 4.5,
"phone": "+86 10 1234 5678",
"address": "123 Auto Street, Beijing"
},
"images": [
{
"url": "https://example.com/image1.jpg",
"alt": "Front view"
}
],
"features": ["Leather Seats", "Navigation System", "Bluetooth", "Backup Camera"],
"description": "Well-maintained Toyota Camry...",
"history": {
"accidents": 0,
"owners": 1,
"service_records": true
},
"created_at": "2024-01-15T10:30:00Z",
"updated_at": "2024-01-20T14:15:00Z"
}
}
🏢 Dealer Endpoints
GET /dealers
Get a list of dealers with optional filtering.
Parameters:
Parameter | Type | Required | Description |
---|---|---|---|
location | string | No | Filter by location |
rating_min | number | No | Minimum rating |
limit | number | No | Number of results (max 100) |
offset | number | No | Pagination offset |
GET /dealer/[id]
Get detailed information about a specific dealer.
Example Response:
{
"success": true,
"data": {
"id": "dealer_123",
"name": "Beijing Auto Center",
"rating": 4.5,
"reviews_count": 150,
"phone": "+86 10 1234 5678",
"email": "contact@beijingauto.com",
"address": "123 Auto Street, Beijing",
"website": "https://beijingauto.com",
"hours": {
"monday": "9:00-18:00",
"tuesday": "9:00-18:00",
"wednesday": "9:00-18:00",
"thursday": "9:00-18:00",
"friday": "9:00-18:00",
"saturday": "9:00-17:00",
"sunday": "Closed"
},
"services": ["Sales", "Service", "Financing", "Trade-in"],
"vehicles_count": 45,
"created_at": "2020-01-01T00:00:00Z"
}
}
🏷️ Brand & Model Endpoints
GET /brands
Get all available vehicle brands.
Example Response:
{
"success": true,
"data": [
{
"id": "toyota",
"name": "Toyota",
"logo": "https://example.com/toyota-logo.png",
"models_count": 25
},
{
"id": "honda",
"name": "Honda",
"logo": "https://example.com/honda-logo.png",
"models_count": 20
}
]
}
GET /models/[brand]
Get all models for a specific brand.
Example Response:
{
"success": true,
"data": [
{
"id": "camry",
"name": "Camry",
"years": [2018, 2019, 2020, 2021, 2022, 2023, 2024],
"body_type": "Sedan"
},
{
"id": "corolla",
"name": "Corolla",
"years": [2018, 2019, 2020, 2021, 2022, 2023, 2024],
"body_type": "Sedan"
}
]
}
📈 Market Data Endpoints
GET /price-history/[id]
Get price history for a specific vehicle.
Example Response:
{
"success": true,
"data": {
"vehicle_id": "12345",
"price_history": [
{
"date": "2024-01-01",
"price": 28000
},
{
"date": "2024-01-15",
"price": 25000
}
],
"trend": "decreasing",
"price_change": -3000,
"price_change_percent": -10.7
}
}
GET /market-stats
Get market statistics and trends.
Example Response:
{
"success": true,
"data": {
"total_vehicles": 15000,
"average_price": 180000,
"price_trend": "increasing",
"popular_brands": [
{ "brand": "Toyota", "count": 2500 },
{ "brand": "Honda", "count": 2000 }
],
"popular_models": [
{ "model": "Camry", "count": 800 },
{ "model": "Corolla", "count": 750 }
]
}
}
⚠️ Error Handling
All API endpoints return consistent error responses:
Error Response Format:
{
"success": false,
"error": {
"code": "INVALID_API_KEY",
"message": "Invalid or expired API key",
"details": "Please check your API key and try again"
}
}
Common Error Codes:
Code | Description |
---|---|
INVALID_API_KEY | Invalid or expired API key |
RATE_LIMIT_EXCEEDED | Too many requests |
INVALID_PARAMETER | Invalid request parameter |
VEHICLE_NOT_FOUND | Vehicle not found |
DEALER_NOT_FOUND | Dealer not found |
INTERNAL_ERROR | Server error |
📊 Rate Limits
- Standard Plan: 1,000 requests per hour
- Professional Plan: 10,000 requests per hour
- Enterprise Plan: 100,000 requests per hour
Rate limit headers are included in all responses:
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1640995200
🔗 SDKs & Libraries
Integrate Che168.com data into your application with our official SDKs:
- JavaScript SDK - Node.js and browser support
- Python SDK - Python 3.7+ support
- Demo Portal - Ready-to-use Next.js application
📞 Support
Need help with the API?
- Documentation: This reference guide
- SDKs: Official client libraries
- Support: Technical assistance
- Status: API status and uptime