Fix breaking rewrite rules starting with ^.

JSON REST API uses a rewrite rule starting with ^. This breaks when using it together with babble. The patch moves it back to the beginning and it does work. Unsure if things can break because of the change.

Also wondered if the API endpoint should be under non_translated_rewrite_rules.