expose search as API