adding api module reduce complexity dependencies