MCPcopy Create free account
hub / github.com/TraderAlice/OpenAlice / getGitLog

Function getGitLog

ui/src/components/workspace/api.ts:462–469  ·  view source on GitHub ↗
(id: string, limit = 30)

Source from the content-addressed store, hash-verified

460}
461
462export async function getGitLog(id: string, limit = 30): Promise<GitLogEntry[]> {
463 const res = await fetch(
464 `/api/workspaces/${encodeURIComponent(id)}/git/log?limit=${limit}`,
465 );
466 if (!res.ok) throw new Error(`git log failed: ${res.status}`);
467 const body = (await res.json()) as { entries: GitLogEntry[] };
468 return body.entries;
469}
470
471export async function getGitStatus(id: string): Promise<GitStatus> {
472 const res = await fetch(`/api/workspaces/${encodeURIComponent(id)}/git/status`);

Callers 1

WorkspaceListPageFunction · 0.90

Calls 1

fetchFunction · 0.50

Tested by

no test coverage detected