encarapi-mcp 1.6.3 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  [Model Context Protocol](https://modelcontextprotocol.io) server for
4
4
  [EnCarAPI](https://encarapi.com/?utm_source=readme&utm_medium=encarapi-mcp). Lets Claude, Cursor, ChatGPT and other MCP clients search
5
5
  **live used car listings from South Korea** (Encar, KB Chachacha, K Car) and **China**
6
- (Dongchedi, Che168), and pull full details, inspection reports and accident records.
6
+ (Dongchedi, Che168), and pull full details, inspection reports, Encar diagnoses and accident records.
7
7
 
8
8
  > **An API key is required.** Get one (5-day trial) at [encarapi.com](https://encarapi.com/?utm_source=readme&utm_medium=encarapi-mcp).
9
9
  > Chinese data works with a [ChinaCarAPI](https://chinacarapi.com/?utm_source=readme&utm_medium=encarapi-mcp) key or an EnCarAPI key
@@ -18,8 +18,10 @@
18
18
  | `search_korean_trucks` | Search Korean trucks, buses and special vehicles (body type, payload in tons, use, region; Business/Scale key) |
19
19
  | `find_korean_car_by_vin` | All Encar / K Car listings of one VIN, incl. removed ones (Business/Scale key) |
20
20
  | `get_korean_truck` | Full record for one truck: detail, inspection report, cargo box, VIN and plate (Business/Scale key) |
21
- | `get_korean_car` | Full detail for one listing (specs, options, photos, price history, seller; `lang`: en, ru or de) |
22
- | `get_korean_inspection` | Official Korean inspection report |
21
+ | `get_korean_car` | Full detail for one listing (specs, options, photos, price history, seller, `diagnosisReport` on Encar listings; `lang`: en, ru or de) |
22
+ | `get_korean_inspection` | Official Korean inspection report; Encar ids and `kbc:` ids (KB Chachacha sheet in the same format, where `InspectionAvailable` is true) |
23
+ | `get_korean_diagnosis` | Encar diagnosis (엔카진단): which outer panels were replaced, inspector verdict incl. frame result (Encar listings only) |
24
+ | `get_korean_history` | Encar vehicle history (차량이력): inspections, repairs, owner changes, insurance claims, recalls, odometer over time (Encar listings only) |
23
25
  | `get_korean_accident_record` | Insurance accident history and ownership changes |
24
26
  | `find_korean_models` | Model name autocomplete across brands |
25
27
  | `korean_filter_values` | Valid filter values |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "encarapi-mcp",
3
- "version": "1.6.3",
3
+ "version": "1.8.0",
4
4
  "description": "MCP server for EnCarAPI and ChinaCarAPI: live Korean (Encar, KB Chachacha, K Car) and Chinese (Dongchedi, Che168) used car listings for Claude, Cursor and other AI assistants.",
5
5
  "type": "module",
6
6
  "main": "src/server.js",
@@ -49,7 +49,7 @@
49
49
  },
50
50
  "dependencies": {
51
51
  "@modelcontextprotocol/sdk": "^1.32.0",
52
- "encarapi": "^1.5.0",
52
+ "encarapi": "^1.9.1",
53
53
  "express": "^5.2.1",
54
54
  "zod": "^4.1.0"
55
55
  }
package/src/server.js CHANGED
@@ -4,7 +4,7 @@ import encarapi from "encarapi";
4
4
 
5
5
  const { KoreaClient, ChinaClient } = encarapi;
6
6
 
7
- export const VERSION = "1.6.3";
7
+ export const VERSION = "1.8.0";
8
8
  const MAX_TEXT = 40000;
9
9
 
10
10
  const asText = (data) => {
@@ -308,7 +308,9 @@ export function createServer({ apiKey, chinaKey, fetchImpl, transport = "stdio",
308
308
  "get_korean_car",
309
309
  {
310
310
  title: "Get a Korean car",
311
- description: "Full details for one Korean listing: specs, options, photos, price history, seller. Id: Encar id, 'kbc:<id>' or 'kcar:<id>'.",
311
+ description:
312
+ "Full details for one Korean listing: specs, options, photos, price history, seller. Id: Encar id, 'kbc:<id>' or 'kcar:<id>'. " +
313
+ "Encar listings also carry diagnosisReport: Encar's own outer-panel diagnosis (see get_korean_diagnosis), null when Encar has no diagnosis for the car.",
312
314
  inputSchema: {
313
315
  id: z.string().describe("Listing id from search_korean_cars"),
314
316
  lang: z.enum(["en", "ru", "de"]).optional().describe("Language of the spec, category and option names: en (default), ru = Russian, de = German"),
@@ -322,13 +324,55 @@ export function createServer({ apiKey, chinaKey, fetchImpl, transport = "stdio",
322
324
  "get_korean_inspection",
323
325
  {
324
326
  title: "Get a Korean inspection report",
325
- description: "Official Korean inspection report (performance check) for one car: panels, frame, mechanical condition.",
326
- inputSchema: { id: z.string() },
327
+ description:
328
+ "Official Korean inspection report (performance check) for one car: panels, frame, mechanical condition. " +
329
+ "Ids: an Encar id, or kbc:<id> for a KB Chachacha listing whose sheet we read (InspectionAvailable true in " +
330
+ "get_korean_car, about two in five KB Chachacha listings that link a sheet) - same format as Encar's plus a " +
331
+ "source block. Other kbc: ids return 404: detailPending true = sheet not read yet (retry later), " +
332
+ "inspectionAvailable false = no structured sheet (original link in inspectionReportUrl). K Car ids are not supported.",
333
+ inputSchema: { id: z.string().describe("Encar id, or kbc:<id> for a KB Chachacha listing") },
327
334
  annotations: readOnly,
328
335
  },
329
336
  run(({ id }) => needKorea().inspection(id))
330
337
  );
331
338
 
339
+ server.registerTool(
340
+ "get_korean_diagnosis",
341
+ {
342
+ title: "Get an Encar diagnosis",
343
+ description:
344
+ "Encar's own body diagnosis (엔카진단) for one Encar listing, done at an Encar center: the 8 outer panels " +
345
+ "(doors, front fenders, hood, trunk lid; resultCode NORMAL or REPLACEMENT) plus the inspector's verdict " +
346
+ "CHECKER_COMMENT (also states the frame result; Encar does not diagnose cars with a damaged frame) and " +
347
+ "OUTER_PANEL_COMMENT, both Korean free text. About three in four active Encar listings have one; it is " +
348
+ "separate from the official inspection report. A 404 with diagnosisAvailable false means Encar has no " +
349
+ "diagnosis for the car, detailPending true means not collected yet. Encar ids only (no kbc:/kcar:). " +
350
+ "get_korean_car carries the same data as diagnosisReport.",
351
+ inputSchema: { id: z.string().describe("Encar listing id from search_korean_cars") },
352
+ annotations: readOnly,
353
+ },
354
+ run(({ id }) => needKorea().diagnosis(id))
355
+ );
356
+
357
+ server.registerTool(
358
+ "get_korean_history",
359
+ {
360
+ title: "Get an Encar vehicle history",
361
+ description:
362
+ "Encar's vehicle history (차량이력) for one Encar listing: the timeline of inspections, repairs, owner " +
363
+ "changes, insurance claims and recalls, with every dated odometer reading (mileageReadings, oldest " +
364
+ "first - a reading lower than an earlier one is worth a closer look), ownership periods, summary flags " +
365
+ "and a Korean one-line summary (summaryKo). Encar collects it from the Ministry of Land, Infrastructure " +
366
+ "and Transport and the Korea Insurance Development Institute; about 8 in 10 Encar listings have one. " +
367
+ "Keys and enums are English, Korean source text stays in the *Ko fields. A 404 with historyAvailable " +
368
+ "false means Encar shows no public history for the listing, historyPending true means not collected " +
369
+ "yet. Encar ids only (no kbc:/kcar:). Separate from get_korean_inspection and get_korean_accident_record.",
370
+ inputSchema: { id: z.string().describe("Encar listing id from search_korean_cars") },
371
+ annotations: readOnly,
372
+ },
373
+ run(({ id }) => needKorea().history(id))
374
+ );
375
+
332
376
  server.registerTool(
333
377
  "get_korean_accident_record",
334
378
  {