Opus finding
fetch_clob_market_payload rejects valid condition IDs that don't start with 0x
lowapi-contractmedium
- agent/settlement.py:25-27
Polymarket condition IDs are commonly the 0x-prefixed bytes32, but the CLOB /markets/{id} endpoint also accepts other identifiers (market id strings in some flows). The strict `0x` prefix gate is an undocumented validation that silently returns None for otherwise-valid IDs, masking failures. At minimum the docstring should call this out, or the guard relaxed.
Recommendation
Either document the 0x-only contract explicitly in the docstring, or drop the prefix check and rely on the HTTP 404 response.