Improvements to API.