separated api and logging functionality