First version of the API and changes to the architecture