call from python
fix url quoting hex fmt; add serialization helpers to/from text