updated Api and DB scheme