MCPcopy Create free account
hub / github.com/codeaashu/claude-code / deriveShortMessageId

Function deriveShortMessageId

src/utils/messages.ts:200–205  ·  view source on GitHub ↗
(uuid: string)

Source from the content-addressed store, hash-verified

198 * Deterministic: same UUID always produces the same short ID.
199 */
200export function deriveShortMessageId(uuid: string): string {
201 // Take first 10 hex chars from the UUID (skipping dashes)
202 const hex = uuid.replace(/-/g, '').slice(0, 10)
203 // Convert to base36 for shorter representation, take 6 chars
204 return parseInt(hex, 16).toString(36).slice(0, 6)
205}
206
207export const INTERRUPT_MESSAGE = '[Request interrupted by user]'
208export const INTERRUPT_MESSAGE_FOR_TOOL_USE =

Callers 1

Calls 1

toStringMethod · 0.65

Tested by

no test coverage detected