first version of the API integration
cleanup