Exported event loop to api