Changes to improve the API