NLog Telegram doesn't work on lambda function

I have a lambda function in asp net core 3.1 that logs some of the logs during execution, as well as a nlog.config file "Copy always", with target xsi: type = "Telegram" configured with a bot, but, no, it can't send messages through the function logs. but it works the same way perfectly out of it.