MCPcopy
hub / github.com/HisMax/RedInk / getHistory

Function getHistory

frontend/src/api/history.ts:73–87  ·  view source on GitHub ↗
(recordId: string)

Source from the content-addressed store, hash-verified

71}
72
73export async function getHistory(recordId: string): Promise<{
74 success: boolean
75 record?: HistoryDetail
76 error?: AppError | string
77 error_message?: string
78}> {
79 try {
80 const response = await axios.get(`${API_BASE_URL}/history/${recordId}`, {
81 timeout: 10000
82 })
83 return response.data
84 } catch (error: any) {
85 return { success: false, ...getApiErrorPayload(error, '获取历史记录详情失败') }
86 }
87}
88
89export async function updateHistory(
90 recordId: string,

Callers 1

restoreFromHistoryFunction · 0.90

Calls 2

getApiErrorPayloadFunction · 0.90
getMethod · 0.80

Tested by

no test coverage detected