feat(FN-4739): complete Step 4 — add room clear API helper

Fusion-Task-Id: FN-4739
Fusion-Task-Lineage: fc120dfa-d1b2-4065-9595-d0bc6304d2af
This commit is contained in:
Fusion (runfusion.ai)
2026-05-16 09:36:05 -07:00
committed by gsxdsm
parent 698e8c272a
commit 207b62a31d
2 changed files with 16 additions and 0 deletions

View File

@@ -8525,6 +8525,16 @@ export function deleteChatRoomMessage(
);
}
export function clearChatRoomMessages(
id: string,
projectId?: string,
): Promise<{ success: boolean; deletedCount: number }> {
return api<{ success: boolean; deletedCount: number }>(
withProjectId(`/chat/rooms/${encodeURIComponent(id)}/messages`, projectId),
{ method: "DELETE" },
);
}
/**
* Room POST /messages in FN-3808 is persist-only (201 JSON response).
* Do not add streamChatRoomResponse until FN-3810 introduces AI invocation/streaming.