created seperate API