Skip to main content
Best answer

Is it possible to attach an image on Telegram?


Bobonez

I am Tring to create a telegram post with image, but what I get is a link to the image file + the image, but clearly I would like to see only the image attached to the post, not the link to the airtable hosting as well

All the data are taken from an airtable sheet.

Any ideas on how to solve it?

 

 

 

Best answer by ken.aBest answer by ken.a

Hi there @Bobonez,

I did some digging into this, and it seems like attaching an image to a message in Telegram is not possible at the moment. However, we do have an open feature request for this exact functionality.

I have added you as another interested member to the feature request. That does a few things:

  • Bring this to the attention of the integration developers
  • Help track interest in this feature being implemented
  • Allows us to notify you via email if this feature becomes available in the future

While I don't have an ETA on when this feature might be implemented, we will notify you via email if it is!

Hopefully, this helps.

View original
Did this topic help you find an answer to your question?

21 replies

ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • Answer
  • September 26, 2023

Hi there @Bobonez,

I did some digging into this, and it seems like attaching an image to a message in Telegram is not possible at the moment. However, we do have an open feature request for this exact functionality.

I have added you as another interested member to the feature request. That does a few things:

  • Bring this to the attention of the integration developers
  • Help track interest in this feature being implemented
  • Allows us to notify you via email if this feature becomes available in the future

While I don't have an ETA on when this feature might be implemented, we will notify you via email if it is!

Hopefully, this helps.


Bobonez
  • Author
  • Beginner
  • 6 replies
  • September 26, 2023

Thank you very much!

 


ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • September 27, 2023

You are most welcome @Bobonez! Glad I was able to add you to the feature request.

If you have any other questions, please don’t hesitate to reach out to the Community. We’re always happy to help! 🤗


  • New
  • 1 reply
  • October 17, 2023

@ken.a I would like to be added to this feature request too, please. 


ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • October 18, 2023

Hi there @pablog,

I have added you as another interested member to the open feature request. While we can’t provide an exact timeframe for the feature’s implementation. We will keep you in the loop via email once the feature has been shipped.

Thank you for your patience and understanding!


@ken.a can i be added also, thanks


ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • January 8, 2024

Hi @organicpaul,

I have added you to the open feature request. We will let you know via email once the feature has been implemented.

Thank you!


  • New
  • 2 replies
  • January 24, 2024

@ken.a can i be added also, thanks


ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • January 25, 2024

Hi @vleopardi,

I have added you as well to the open feature request. We will keep you in the loop via email once the feature has been shipped.

Thanks!


  • New
  • 2 replies
  • February 8, 2024

Hi There,

I noticed that the image url in the telegram post with image, is not working after two/three time zap is running.  The url opens a 404error page. I am not sure why this is happening.

thanks  for help

Valeria


Forum|alt.badge.img
  • Beginner
  • 20 replies
  • August 27, 2024

Please implement this. We need this. Thanks 

 

URGENT, URGENT, URGENT


JammerS
Forum|alt.badge.img+6
  • Zapier Staff
  • 2331 replies
  • August 28, 2024

Hi @vleopardi and @horacechan,

 

I have added your votes for this feature request, and we’ll email you once an update is readily available. Thank you.


Forum|alt.badge.img
  • Beginner
  • 20 replies
  • August 28, 2024

How to see the votes?

 


JammerS
Forum|alt.badge.img+6
  • Zapier Staff
  • 2331 replies
  • August 29, 2024

Hi @horacechan,

 

Votes are being sent internally with the developers but rest assured that your vote was casted and sent to the app developer. 


Forum|alt.badge.img
  • Beginner
  • 9 replies
  • September 11, 2024

@JammerS Please upvote this for me and add me to the email list! This feature would be very useful.


JammerS
Forum|alt.badge.img+6
  • Zapier Staff
  • 2331 replies
  • September 12, 2024

Hi @darvinm,

 

I’ve added your vote for this feature request, and we’ll notify you via email once an update is readily available. Thanks.


jakobaa
  • New
  • 6 replies
  • January 21, 2025

same here, please add me as well

 


ken.a
Forum|alt.badge.img+6
  • Zapier Staff
  • 6368 replies
  • January 23, 2025

Hi ​@jakobaa,

I have added you to the feature request. We will keep you updated via email once the feature has been implemented.

Thank you!


jakobaa
  • New
  • 6 replies
  • January 23, 2025

FYI I have found a solution how to post a photo directly via the API (and not the Telegram Zapier Integration). 

Setup:

  • App: Code by Zapier
  • Event: Run Javascript

Configure:

  • Input Data:
    • botToken = ...
    • channelId = … 
    • photoUrl = …

  • Code:

// Get values from input
const BOT_TOKEN = inputData.botToken;
const CHANNEL_ID = inputData.channelId;
const PHOTO_URL = inputData.photoUrl;

async function testPhotoUpload() {
  const url = `https://api.telegram.org/bot${BOT_TOKEN}/sendPhoto`;

  try {
    // First method: Using form-encoded parameters
    const params = new URLSearchParams();
    params.append('chat_id', CHANNEL_ID);
    params.append('photo', PHOTO_URL);

    const response = await fetch(url + '?' + params.toString());

    return await response.json();
  } catch (error) {
    return {error: error.message};
  }
}

return testPhotoUpload();

 


JammerS
Forum|alt.badge.img+6
  • Zapier Staff
  • 2331 replies
  • January 24, 2025

Wow ​@jakobaa,

 

Thank you so much for this work around. This will significantly help our Community that was dealing with the same issue.


jakobaa
  • New
  • 6 replies
  • January 24, 2025

Happy to help, but I have to give the credit to Claude :) 

I have slightly improved it since to also post a text message as photo caption (so it is one message and not two separate messages, which makes it easier for people to share and just looks cleaner).
I also disabled the link-preview as for my use case. 

Additional Input Data:

Updated Code;

// Get values from input
const BOT_TOKEN = inputData.botToken;
const CHANNEL_ID = inputData.channelId;
const PHOTO_URL = inputData.photoUrl;
const MESSAGE = inputData.message;

async function sendTelegramContent() {
  try {
    const params = new URLSearchParams();
    params.append('chat_id', CHANNEL_ID);
    params.append('parse_mode', 'HTML');
    params.append('disable_web_page_preview', 'true');

    // Check for a valid photo URL (not empty string)
    let endpoint;
    if (PHOTO_URL && PHOTO_URL.trim().length > 0) {
      endpoint = 'sendPhoto';
      params.append('photo', PHOTO_URL);
      params.append('caption', MESSAGE);
    } else {
      endpoint = 'sendMessage';
      params.append('text', MESSAGE);
    }

    const url = `https://api.telegram.org/bot${BOT_TOKEN}/${endpoint}`;
    const response = await fetch(url + '?' + params.toString());

    return await response.json();
  } catch (error) {
    return {error: error.message};
  }
}

return sendTelegramContent();