mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-31 04:59:24 +08:00
Feat: Add Explore page (#13043)
### What problem does this PR solve? Feat: Add Explore page ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@@ -126,6 +126,10 @@ const methods = {
|
||||
url: cancelCanvas,
|
||||
method: 'put',
|
||||
},
|
||||
createAgentSession: {
|
||||
url: fetchAgentLogs,
|
||||
method: 'put',
|
||||
},
|
||||
} as const;
|
||||
|
||||
const agentService = registerNextServer<keyof typeof methods>(methods);
|
||||
@@ -140,6 +144,10 @@ export const fetchAgentLogsByCanvasId = (
|
||||
return request.get(methods.fetchAgentLogs.url(canvasId), { params: params });
|
||||
};
|
||||
|
||||
export const fetchAgentLogsById = (canvasId: string, sessionId: string) => {
|
||||
return request.get(api.fetchAgentLogsById(canvasId, sessionId));
|
||||
};
|
||||
|
||||
export const fetchPipeLineList = (params: IPipeLineListRequest) => {
|
||||
return request.get(api.listCanvas, { params: params });
|
||||
};
|
||||
@@ -151,4 +159,12 @@ export const fetchWebhookTrace = (
|
||||
return request.get(api.fetchWebhookTrace(id), { params: params });
|
||||
};
|
||||
|
||||
export function createAgentSession({ id, name }: { id: string; name: string }) {
|
||||
return request.put(api.fetchAgentLogs(id), { data: { name } });
|
||||
}
|
||||
|
||||
export const deleteAgentSession = (canvasId: string, sessionId: string) => {
|
||||
return request.delete(api.fetchAgentLogsById(canvasId, sessionId));
|
||||
};
|
||||
|
||||
export default agentService;
|
||||
|
||||
Reference in New Issue
Block a user