MCPcopy Index your code
hub / github.com/simstudioai/sim / parseDaytonaJson

Function parseDaytonaJson

apps/sim/tools/daytona/utils.ts:30–38  ·  view source on GitHub ↗
(response: Response)

Source from the content-addressed store, hash-verified

28 * empty 200 responses from lifecycle endpoints).
29 */
30export async function parseDaytonaJson(response: Response): Promise<Record<string, any>> {
31 const text = await response.text()
32 if (!text) return {}
33 try {
34 return JSON.parse(text)
35 } catch {
36 return {}
37 }
38}
39
40/**
41 * Extracts a human-readable error message from a Daytona API error response.

Callers 3

stop_sandbox.tsFile · 0.90
delete_sandbox.tsFile · 0.90
start_sandbox.tsFile · 0.90

Calls 2

textMethod · 0.80
parseMethod · 0.80

Tested by

no test coverage detected