MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / parse_value

Method parse_value

atomic-agent/src/hooks/codex.rs:195–205  ·  view source on GitHub ↗
(
        &self,
        hook_type: HookType,
        raw_json: Value,
    )

Source from the content-addressed store, hash-verified

193 }
194
195 fn parse_value<T: for<'de> Deserialize<'de>>(
196 &self,
197 hook_type: HookType,
198 raw_json: Value,
199 ) -> AgentResult<T> {
200 serde_json::from_value(raw_json).map_err(|e| AgentError::HookParseFailed {
201 agent: self.name().to_string(),
202 hook_type: hook_type.as_str().to_string(),
203 reason: e.to_string(),
204 })
205 }
206}
207
208impl Default for CodexHook {

Callers 1

parse_eventMethod · 0.80

Calls 2

nameMethod · 0.45
as_strMethod · 0.45

Tested by

no test coverage detected