How to create your own Telegram bot

From PlanFix
Jump to: navigation, search

You can create your own Telegram bot than you can then link to Planfix. Messages sent to this bot by your clients or colleagues will become tasks in Planfix. Comments added to the task that notifies an outside party will be sent to them in Telegram from the bot. This lets you arrange several aspects of your work, from how client messages from mobile devices are processed, to how your support team works, and more.


Creating a Telegram bot

To create your own Telegram bot:

  • tap this link (Telegram must be launched on this device)
  • in the welcome window, tap the "Start" button.


7Oxc2A.png


  • in the chat window with @BotFather, enter the /newbot command
  • enter the name of the new bot when prompted. The name must end with "bot" or "_bot." It's advisable to choose a name that's somehow associated with your company or line of work. For example, the company BrainStorm could choose the name BrainstormAgencyBot or BrainstormAgency_bot. Once you've entered a name, tap Enter.


vCb2LF.png


  • then BotFather will ask you to enter a username for the bot. Unlike the bot's name, the username must be unique, which could cause issues for more common names. No two Telegram bots can have the same username. BotFather will tell you if the username you chose is already in use and will prompt you to enter another name until you find one that is unique and unused. Once you have entered your username, the bot creation process is complete, and you will see the following message:


WgZYFl.png


Linking the Telegram bot to Planfix

To link the bot you've created to Planfix, go to the section Account management / Integrations / Messengers / Telegram and tap Add bot:


rHmUpv.png


  • in the window that opens, enter the name of the bot, the list of employees using the bot, and the key you got when you created the bot (it was outlined in red in the last screenshot with the BotFather chat):


Ave5VC.png


  • Once the bot has been added, you can choose the template to use to create tasks for messages the bot receives and which template to use for new contacts created from people who send the bot messages:


a3xdh1.png


Important: When setting up an integration, you can make it so that a new task is created if there is no active task (with any active status) for communication from a client who messages the bot:


Qa1cxM.png


By default, this checkbox is checked. When the checkbox is checked, a new task will be created if the previous task with this client has been deleted or completed, or is inactive. Conversation history will automatically be added to the description of the task created:


NaVOOO.png


When the checkbox is unchecked, all messages from the client will be sent to the original task with this client, regardless of its current status.


Go To