api: addLog now uses the source param as source instead of 'app'

Please review carefully, this is my first go code. I'm not completely sure if that's how the test should be done.