tripinned-mcp 1.0.18 → 1.0.19
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/dist/index.js +58 -3
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -49,6 +49,7 @@ Tripinned trip planning rules:
|
|
|
49
49
|
- When adding flight segments, group the full route (origin → stopover → destination) as one item if the user is just passing through.
|
|
50
50
|
- To show an item in the route map, set show_on_route to true. For place items, provide either lat/lng for a single location or locations for up to 10 ordered place stops. For flights, provide origin/destination IATA codes in from_place and to_place; no separate coordinates are needed. For non-flight transport, provide from_place/from_lat/from_lng and/or to_place/to_lat/to_lng.
|
|
51
51
|
- Hotel stays must use icon HOTEL with check-in in start_time, check-out in end_time, and end_day_offset for the check-out day. The API creates a check-in/check-out group with one shared groupId; add_item returns the check-in item and get_trip shows both items.
|
|
52
|
+
- To change an existing item to or from HOTEL, or to change any grouped item's icon, use convert_item_type instead of update_item so every group member changes atomically.
|
|
52
53
|
`.trim(),
|
|
53
54
|
});
|
|
54
55
|
// ── Trips ────────────────────────────────────────────────────────────────────
|
|
@@ -187,13 +188,13 @@ server.tool("add_item", `특정 Day에 일정을 추가합니다. Day당 최대
|
|
|
187
188
|
const data = await call("POST", `/trips/${trip_id}/days/${day_id}/items`, body);
|
|
188
189
|
return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] };
|
|
189
190
|
});
|
|
190
|
-
server.tool("update_item", "일정을 수정합니다. 변경할 필드만 보내면 됩니다.", {
|
|
191
|
+
server.tool("update_item", "일정을 수정합니다. 변경할 필드만 보내면 됩니다. HOTEL 타입 또는 그룹 일정의 icon을 변경할 때는 update_item 대신 convert_item_type을 사용하세요.", {
|
|
191
192
|
trip_id: z.string().describe("플랜 ID"),
|
|
192
193
|
day_id: z.string().describe("Day ID"),
|
|
193
194
|
item_id: z.string().describe("일정 ID"),
|
|
194
195
|
title: z.string().max(50).optional().describe("새 제목"),
|
|
195
196
|
order: z.coerce.number().int().min(0).optional().describe("Day 안에서의 일정 순서 (0부터 시작)"),
|
|
196
|
-
icon: z.string().optional().describe("아이콘 (
|
|
197
|
+
icon: z.string().optional().describe("아이콘 (HOTEL 타입 또는 그룹 일정의 icon 변경은 convert_item_type 사용)"),
|
|
197
198
|
start_time: z.string().optional().describe("시작 시간 (HH:MM)"),
|
|
198
199
|
end_time: z.string().optional().describe("종료 시간 (HH:MM)"),
|
|
199
200
|
end_day_offset: z.coerce.number().int().min(0).optional().describe("도착일 오프셋 (0=당일, 1=다음날)"),
|
|
@@ -274,7 +275,61 @@ server.tool("update_item", "일정을 수정합니다. 변경할 필드만 보
|
|
|
274
275
|
const data = await call("PATCH", `/trips/${trip_id}/days/${day_id}/items/${item_id}`, body);
|
|
275
276
|
return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] };
|
|
276
277
|
});
|
|
277
|
-
server.tool("
|
|
278
|
+
server.tool("convert_item_type", "일정 타입을 안전하게 변경합니다. 일반 일정→HOTEL 또는 HOTEL 그룹→다른 타입처럼 그룹 구조가 달라질 수 있는 icon 변경은 이 도구를 사용하세요. icon=HOTEL이면 start_time, end_time, end_day_offset을 모두 반드시 제공해야 합니다.", {
|
|
279
|
+
trip_id: z.string().describe("플랜 ID"),
|
|
280
|
+
day_id: z.string().describe("변경할 일정이 현재 속한 Day ID"),
|
|
281
|
+
item_id: z.string().describe("변경할 일정 ID (HOTEL 그룹은 어느 멤버 ID든 가능)"),
|
|
282
|
+
icon: z
|
|
283
|
+
.enum([
|
|
284
|
+
"FOOD",
|
|
285
|
+
"CAFE",
|
|
286
|
+
"HOTEL",
|
|
287
|
+
"SIGHTSEEING",
|
|
288
|
+
"SHOPPING",
|
|
289
|
+
"ACTIVITY",
|
|
290
|
+
"ETC",
|
|
291
|
+
"TRANSPORT",
|
|
292
|
+
"PLANE",
|
|
293
|
+
"TRAIN",
|
|
294
|
+
"BUS",
|
|
295
|
+
"CAR",
|
|
296
|
+
"BOAT",
|
|
297
|
+
"WALK",
|
|
298
|
+
"TRANSPORT_ETC",
|
|
299
|
+
])
|
|
300
|
+
.describe("변경할 일정 타입"),
|
|
301
|
+
start_time: z
|
|
302
|
+
.string()
|
|
303
|
+
.optional()
|
|
304
|
+
.describe("숙소 체크인 시간 (HH:MM). icon=HOTEL이면 필수"),
|
|
305
|
+
end_time: z
|
|
306
|
+
.string()
|
|
307
|
+
.optional()
|
|
308
|
+
.describe("숙소 체크아웃 시간 (HH:MM). icon=HOTEL이면 필수"),
|
|
309
|
+
end_day_offset: z
|
|
310
|
+
.coerce.number()
|
|
311
|
+
.int()
|
|
312
|
+
.min(0)
|
|
313
|
+
.optional()
|
|
314
|
+
.describe("숙소 체크아웃 날짜 오프셋. icon=HOTEL이면 필수"),
|
|
315
|
+
}, async ({ trip_id, day_id, item_id, icon, start_time, end_time, end_day_offset, }) => {
|
|
316
|
+
if (icon === "HOTEL" &&
|
|
317
|
+
(start_time === undefined ||
|
|
318
|
+
end_time === undefined ||
|
|
319
|
+
end_day_offset === undefined)) {
|
|
320
|
+
throw new Error("HOTEL 타입으로 변경하려면 start_time, end_time, end_day_offset을 모두 제공해야 합니다.");
|
|
321
|
+
}
|
|
322
|
+
const body = { icon };
|
|
323
|
+
if (start_time !== undefined)
|
|
324
|
+
body.startTime = start_time;
|
|
325
|
+
if (end_time !== undefined)
|
|
326
|
+
body.endTime = end_time;
|
|
327
|
+
if (end_day_offset !== undefined)
|
|
328
|
+
body.endDayOffset = end_day_offset;
|
|
329
|
+
const data = await call("PUT", `/trips/${trip_id}/days/${day_id}/items/${item_id}/type`, body);
|
|
330
|
+
return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] };
|
|
331
|
+
});
|
|
332
|
+
server.tool("delete_item", "일정을 삭제합니다. 그룹 멤버를 지정하면 API가 해당 그룹 전체를 함께 삭제합니다.", {
|
|
278
333
|
trip_id: z.string().describe("플랜 ID"),
|
|
279
334
|
day_id: z.string().describe("Day ID"),
|
|
280
335
|
item_id: z.string().describe("일정 ID"),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tripinned-mcp",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.19",
|
|
4
4
|
"description": "MCP server for Tripinned — manage your travel plans with AI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"start": "node dist/index.js"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@modelcontextprotocol/sdk": "^1.
|
|
20
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
21
21
|
"zod": "^4.3.6"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|