added log in the API