Search code examples
telegram-botnode-red

How to set up telegram bot's name from an environment variable in node-red?


Using node-red-contrib-telegrambot palette it is possible to set up bot's token from an env variable using the following syntax {env.get("BOT_TOKEN")}.

enter image description here

But is it possible to do the same for the bot's name?


Solution

  • To populate any fields of a node in the editor from environment variables you need to use the following syntax:

    ${BOT_TOKEN}
    

    You can find the docs here