How to send an Embedded Image along with text in a Message via Telegram Bot API

Pierre-Antoine picture Pierre-Antoine · Jul 31, 2016 · Viewed 28.5k times · Source

Using Telegram Bot API,

I'm aware that it is possible to send an image via https://core.telegram.org/bots/api#sendphoto

However, how can I embed a remote image into a formatted message?

The message I am looking to send, can be compared to a news article with a title in bold, an image, and a longer text with links. I figured out how to create bold text and links with markdown, but I'm failing at inserting images. How can we do that?

Answer

barzin.A picture barzin.A · Apr 30, 2017

you must set ParseMode in HTML and set your Image Url in A tag like this:

<a href="' + image + '">&#8205;</a>

&#8205; -> never show in message