MCPcopy Create free account
hub / github.com/arctic-cli/interface / readJsonFile

Function readJsonFile

packages/arctic/src/auth/index.ts:215–222  ·  view source on GitHub ↗
(filePath: string)

Source from the content-addressed store, hash-verified

213 }
214
215 async function readJsonFile<T>(filePath: string): Promise<T | null> {
216 try {
217 const contents = await fs.readFile(filePath, "utf8")
218 return JSON.parse(contents) as T
219 } catch {
220 return null
221 }
222 }
223
224 function extractCodexIdToken(raw: unknown): string | undefined {
225 if (!raw) return undefined

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected