{"slug":"agent-halowerk-com-v1-twin-diff-f3e147","title":"Takes two state documents — target (what the twin should look like) and observed","host":"agent.halowerk.com","method":"POST","resource":"https://agent.halowerk.com/v1/twin-diff","category":"other","description":"Takes two state documents — target (what the twin should look like) and observed (what was measured) — and returns a leaf-by-leaf comparison. Every leaf path carries one of five states: in_tolerance, out_of_tolerance, missing_in_observed, unexpected_in_observed or type_mismatch.","price_listed":0.003,"price_asked":0.003,"state":"answering","state_label":"Answering","checks_7d":1,"answered_7d":1,"latency_ms_median":1189,"reported_calls_30d":2,"reported_payers_30d":2,"networks":["eip155:8453"],"badge":"unverified","paid_checks_7d":0,"paid_ok_7d":0,"example_input":{"body":{"default_tolerance_ratio":0,"observed":{"firmware":"2.3.9","pump":{"pressure_bar":4.15,"running":true},"site":{"radius_km":12.4}},"target":{"firmware":"2.4.1","pump":{"pressure_bar":4,"running":true},"site":{"radius_km":12}},"tolerances":[{"field":"/pump/pressure_bar","tolerance_abs":0.2,"unit":"bar"},{"field":"/site/radius_km","tolerance_ratio":0.01,"unit":"km"}]},"bodyType":"json","method":"POST","type":"http"},"output_schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","properties":{"input":{"additionalProperties":false,"properties":{"body":{"additionalProperties":false,"properties":{"case_insensitive_strings":{"default":false,"description":"Compare string leaves without regard to case.","type":"boolean"},"default_tolerance_ratio":{"default":0,"description":"Relative tolerance for numeric paths without their own entry. 0 means exact equality.","maximum":1,"minimum":0,"type":"number"},"ignore_fields":{"description":"Paths to leave out of the comparison. A trailing /* ignores everything below that prefix.","items":{"maxLength":400,"minLength":1,"type":"string"},"maxItems":200,"type":"array"},"max_fields":{"default":2000,"description":"Reject the request if the two documents together hold more leaf paths than this.","maximum":2000,"minimum":1,"type":"integer"},"observed":{"description":"The observed state document (the measurement).","type":"object"},"target":{"description":"The desired state document (the twin).","type":"object"},"tolerances":{"description":"Per-path tolerances. Give tolerance_abs or tolerance_ratio, not both.","items":{"additionalProperties":false,"properties":{"field":{"description":"Leaf path as it appears in the result, e.g. /pump/pressure_bar. A trailing /* applies the entry to every leaf below that prefix.","maxLength":400,"minLength":1,"type":"string"},"tolerance_abs":{"description":"Absolute tolerance in the unit of this field.","minimum":0,"type":"number"},"tolerance_ratio":{"description":"Relative tolerance as a ratio of the larger of the two values.","maximum":1,"minimum":0,"type":"number"},"unit":{"description":"Unit of this field, echoed into the result. Declared by you, never inferred.","maxLength":32,"type":"string"}},"required":["field"],"type":"object"},"maxItems":200,"type":"array"}},"required":["target","observed"],"type":"object"},"bodyType":{"enum":["json","form-data","text"],"type":"string"},"method":{"enum":["POST","PUT","PATCH"],"type":"string"},"type":{"const":"http","type":"string"}},"required":["type","method","bodyType","body"],"type":"object"}},"required":["input"],"type":"object"},"history":[{"day":"2026-09-24","reachable":true,"status":402,"valid_402":true,"asked_usdc":0.003,"price_match":true,"latency_ms":1189,"error":null}],"description_full":"Takes two state documents — target (what the twin should look like) and observed (what was measured) — and returns a leaf-by-leaf comparison. Every leaf path carries one of five states: in_tolerance, out_of_tolerance, missing_in_observed, unexpected_in_observed or type_mismatch.","last_updated":"2026-09-19T16:02:01.946Z","schemes":["exact"]}