# Cars24 — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Search and browse used car listings across Indian cities with complete details including prices, specifications, and features. Find the perfect car by filtering options and comparing vehicle information all in one place.

**Category:** Automotive | **Website:** [cars24.com/](https://cars24.com/) | **Docs:** [parse.bot/marketplace/9b80332e-9123-482e-8801-e4001a6672d7/cars24-com-api](https://parse.bot/marketplace/9b80332e-9123-482e-8801-e4001a6672d7/cars24-com-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-cars24-com-api-9b80332e/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_car_details

Fetch comprehensive details for a single car using its unique appointmentId. Returns the full listing object including price, specs, features, images, EMI details, and assurance information. The appointmentId is obtained from search_cars results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `appointment_id` | string | Yes | Unique car identifier from search_cars results |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-cars24-com-api-9b80332e/get_car_details \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"appointment_id":"<string>"}'
```

### get_cities

Fetch all available cities with their IDs and SEO slugs. Each city includes a count of available cars and the top brands stocked there. Use city IDs and slugs to scope car searches.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-cars24-com-api-9b80332e/get_cities \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### search_cars

Search for used cars with filters like city, brand, model, fuel type, transmission, year range, and price range. Returns paginated results ordered by best match or newest listings. Pagination uses a cursor (search_after) returned from the previous page; pass it as a JSON-encoded array to fetch the next page.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `brand` | string | No | Car brand name such as Maruti, Hyundai, Tata, Honda, Mahindra, Renault, Toyota, Kia, Ford, Volkswagen |
| `city_id` | integer | No | City ID from get_cities endpoint |
| `city_slug` | string | No | SEO slug for the city from get_cities url field, or 'buy-used-car' for generic search |
| `fuel` | string | No | Fuel type filter |
| `limit` | integer | No | Number of results per page (max 100) |
| `model` | string | No | Car model name such as Swift, i20, Nexon, City, Creta |
| `price_max` | integer | No | Maximum price in INR |
| `price_min` | integer | No | Minimum price in INR |
| `search_after` | string | No | JSON-encoded pagination cursor array [score, appointmentId] from previous result's search_after field |
| `sort` | string | No | Sort order for results |
| `transmission` | string | No | Transmission type filter |
| `year_max` | integer | No | Maximum registration year |
| `year_min` | integer | No | Minimum registration year |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-cars24-com-api-9b80332e/search_cars \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"brand":"<string>","city_id":"<integer>","city_slug":"<string>","fuel":"<string>","limit":"<integer>","model":"<string>","price_max":"<integer>","price_min":"<integer>","search_after":"<string>","sort":"<string>","transmission":"<string>","year_max":"<integer>","year_min":"<integer>"}'
```
