refactor(i18n): refactor user language detection, add to api methods