add the query and suggest api