feat(extension): add GetConversation + rawRPC endpoints for full conversation history

This commit is contained in:
2026-03-08 00:15:22 +09:00
parent db70840b7a
commit 215409535b
2 changed files with 21 additions and 0 deletions

View File

@@ -205,6 +205,27 @@ export async function activate(context: vscode.ExtensionContext) {
} }
}); });
// 개별 대화 전체 내용 (스텝, 메시지, 도구 호출 등)
app.get('/api/conversation/:id', async (req: any, res: any) => {
try {
const conversation = await sdk.ls.getConversation(req.params.id);
res.json(conversation);
} catch (err: any) {
res.status(500).json({ error: err.message });
}
});
// 임의 LS RPC 호출 (개발/디버그)
app.post('/api/ls/rpc', async (req: any, res: any) => {
try {
const { method, payload } = req.body;
const result = await sdk.ls.rawRPC(method, payload || {});
res.json(result);
} catch (err: any) {
res.status(500).json({ error: err.message });
}
});
app.post('/api/ls/send', async (req: any, res: any) => { app.post('/api/ls/send', async (req: any, res: any) => {
try { try {
const { cascadeId, text, model } = req.body; const { cascadeId, text, model } = req.body;