feat: summarize codex app server turns

This commit is contained in:
AI Bot
2026-06-03 10:17:07 +08:00
parent 74b333ba2f
commit 1ae81fa3af
11 changed files with 200 additions and 5 deletions

View File

@@ -431,6 +431,60 @@ rl.on("line", (line) => {
return;
}
if (message.method === "thread/turns/list") {
const threadId = message.params?.threadId;
if (threadId === "thr-active") {
send({
id: message.id,
result: {
data: [
{
id: "turn-active-2",
status: "running",
createdAt: "2026-06-03T08:18:00.000Z",
updatedAt: "2026-06-03T08:21:00.000Z",
userInput: "private active turn text should not leak",
items: [{ type: "message", content: "private item content should not leak" }],
},
{
id: "turn-active-1",
status: "completed",
createdAt: "2026-06-03T08:00:00.000Z",
updatedAt: "2026-06-03T08:10:00.000Z",
},
],
nextCursor: null,
backwardsCursor: null,
},
});
return;
}
if (threadId === "thr-idle") {
send({
id: message.id,
result: {
data: [
{
id: "turn-idle-1",
status: { type: "completed" },
createdAt: "2026-06-03T07:00:00.000Z",
updatedAt: "2026-06-03T07:30:00.000Z",
userInput: "private idle turn text should not leak",
},
],
nextCursor: null,
backwardsCursor: null,
},
});
return;
}
send({
id: message.id,
result: { data: [], nextCursor: null, backwardsCursor: null },
});
return;
}
if (message.method === "thread/resume") {
send({
id: message.id,