make plugin usable as simple rewrite API