Skip to content

Display the referral link to a user

You can allow users of your bot to obtain and share their referral link using the native variable {ref_link} in a message. Follow these steps to set it up:


  1. Go to the bot where you want to configure the referral link.
  2. Click 🛠 Edit.
  3. Select the button or command that will send the referral link:

    • Buttons: Click the desired button, and it will be highlighted with < >.
    • Commands: Write the command directly in the bot's chat.
  4. Click on 💬 Messages.

  5. Click ➕ Message and write a message like this:
    Your referral link is:
    
    {ref_link}
    
  6. Return to the bot menu and tap 💢 Stop editor.
  7. Test by tapping the button or sending the command. You should receive a message similar to this:

    Example of referral link in Telegram


When a user shares their link and someone uses it to start the bot for the first time, the new user will automatically be added as a referral.


More information about variables

  • {ref_link}: This is a native variable specific to referrals. Learn more about these variables here.
  • Variables: Standard variables can be used to manage dynamic data such as balances or statistics. Discover more here.

IMPORTANT

Keep in mind that only referrals who start the bot for the first time and complete all the actions in the /start command (if configured) will be counted.