MCPcopy
hub / github.com/7836246/cursor2api / fetchLogs

Function fetchLogs

vue-ui/src/api.ts:21–27  ·  view source on GitHub ↗
(params?: { requestId?: string; since?: number })

Source from the content-addressed store, hash-verified

19}
20
21export function fetchLogs(params?: { requestId?: string; since?: number }): Promise<LogEntry[]> {
22 const q = new URLSearchParams();
23 if (params?.requestId) q.set('requestId', params.requestId);
24 if (params?.since != null) q.set('since', String(params.since));
25 const qs = q.toString() ? '?' + q.toString() : '';
26 return apiFetch<LogEntry[]>(`/api/logs${qs}`);
27}
28
29export function fetchRequests(limit = 50): Promise<RequestSummary[]> {
30 return apiFetch<RequestSummary[]>(`/api/requests?limit=${limit}`);

Callers 2

loadRequestsFunction · 0.90
selectRequestFunction · 0.90

Calls 1

apiFetchFunction · 0.85

Tested by

no test coverage detected