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

Method parse_value

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

Source from the content-addressed store, hash-verified

209 }
210
211 fn parse_value<T: for<'de> Deserialize<'de>>(
212 &self,
213 hook_type: HookType,
214 raw_json: Value,
215 ) -> AgentResult<T> {
216 serde_json::from_value(raw_json).map_err(|e| AgentError::HookParseFailed {
217 agent: self.name().to_string(),
218 hook_type: hook_type.as_str().to_string(),
219 reason: e.to_string(),
220 })
221 }
222}
223
224impl Default for CodexHook {

Callers 1

parse_eventMethod · 0.80

Calls 2

nameMethod · 0.45
as_strMethod · 0.45

Tested by

no test coverage detected