MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / convertStatusMessage

Function convertStatusMessage

source code/remote/sdkMessageAdapter.ts:90–106  ·  view source on GitHub ↗

* Convert an SDKStatusMessage to a SystemMessage

(msg: SDKStatusMessage)

Source from the content-addressed store, hash-verified

88 * Convert an SDKStatusMessage to a SystemMessage
89 */
90function convertStatusMessage(msg: SDKStatusMessage): SystemMessage | null {
91 if (!msg.status) {
92 return null
93 }
94
95 return {
96 type: 'system',
97 subtype: 'informational',
98 content:
99 msg.status === 'compacting'
100 ? 'Compacting conversation…'
101 : `Status: ${msg.status}`,
102 level: 'info',
103 uuid: msg.uuid,
104 timestamp: new Date().toISOString(),
105 }
106}
107
108/**
109 * Convert an SDKToolProgressMessage to a SystemMessage.

Callers 1

convertSDKMessageFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected