Added update, remove to the API, some fixes