Mintplex-Labs/anything-llm · error
Chat not found.
Error message
Chat not found.
What it means
Existence/ownership guard on PUT /workspace/workspace-chats/:id: no WorkspaceChats row matches the id for the requesting user, so the chat either never existed or belongs to someone else, and a 404 is returned.
Source
Thrown at server/endpoints/workspaces.js:770
response.status(500).json({ message: "Internal server error" });
}
}
);
app.put(
"/workspace/workspace-chats/:id",
[validatedRequest, flexUserRoleValid([ROLES.all])],
async (request, response) => {
try {
const { id } = request.params;
const user = await userFromSession(request, response);
const validChat = await WorkspaceChats.get({
id: Number(id),
user_id: user?.id ?? null,
});
if (!validChat)
return response
.status(404)
.json({ success: false, error: "Chat not found." });
await WorkspaceChats._update(validChat.id, { include: false });
response.json({ success: true, error: null });
} catch (e) {
console.error(e.message, e);
response.status(500).json({ success: false, error: "Server error" });
}
}
);
/** Handles the uploading and embedding in one-call by uploading via drag-and-drop in chat container. */
app.post(
"/workspace/:slug/upload-and-embed",
[
validatedRequest,
flexUserRoleValid([ROLES.admin, ROLES.manager]),
handleFileUpload,View on GitHub (pinned to 3aec848f28)
Solutions
- Verify the chat ID is correct and the chat has not been deleted.
- List workspace chats to find a valid ID.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at server/endpoints/workspaces.js:770 when the library encounters an invalid state.
Common situations: Referencing a chat that does not exist in the workspace.
AI-assisted analysis of Mintplex-Labs/anything-llm@3aec848f28 (2026-08-18).
Data as JSON: /api/errors/9331342e035b4024.
Report an issue: GitHub.