update to new API structure