Move api models to main library