updated the api