Added a simple api for testing.