markdowntelegramtelegram-bot

Can I make the link bold in markdown when sending messages using the Telegram Bot API?


I'm using the sendMessage() method to send messages in markdown mode. I tried different ways of sending a link with bold style on it but it doesn't work.

This is my markdown:

[*demo*](www.google.com)
*[demo](www.google.com)*
* [demo](www.google.com) *

Besides, bold & italic also doesn't work when combined:

_*Bold+Italic*_
*_Bold+Italic_*

I'm wondering that is it possible to do what I mentioned?


Solution

  • markdown is the old parse-mode, you should use MarkdownV2 if you want to style links.

    For example, a normal, bold, and italic/bold link can be send like so:

    Link: [Google](https://google.com)
    Link: *[Google](https://google.com)*
    Link: *_[Google](https://google.com)_*
    

    Results in

    enter image description here