MCPcopy Create free account
hub / github.com/bearlyai/OpenADE / paramsRecord

Function paramsRecord

projects/runtime-protocol/src/protocol.ts:410–414  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

408])
409
410function paramsRecord(value: unknown): RuntimeValidationResult<Record<string, unknown>> {
411 if (value === undefined) return { ok: true, value: {} }
412 if (!isRecord(value)) return paramsError("$", "Runtime params must be an object")
413 return { ok: true, value }
414}
415
416function optionalString(record: Record<string, unknown>, key: string): RuntimeValidationResult<string | undefined> {
417 const value = record[key]

Calls 2

isRecordFunction · 0.70
paramsErrorFunction · 0.70

Tested by

no test coverage detected