Implement the API