final cleanup of patent search api