Giter VIP home page Giter VIP logo

Comments (7)

levlam avatar levlam commented on July 18, 2024

There are no bugs with link_preview_options in Bot API. show_above_text works correctly in InlineQueryResultArticle. TDLib-based apps like Unigram or Telegram X immediately show the message correctly for the sender. Android app shows it correctly after the message is sent and the chat is reopened. Telegram Desktop shows it correctly after app restart. You can create an issue for specific app at https://bugs.telegram.org/.

in InlineQueryResultArticle it always shows me the "expired" image.

This is intended behavior. Content of URLs is cached for a long time. You can't expect Telegram to redownload all files sent by URLs all the time.

from telegram-bot-api.

Sarisan avatar Sarisan commented on July 18, 2024

This is intended behavior. Content of URLs is cached for a long time. You can't expect Telegram to redownload all files sent by URLs all the time.

It seems you didn't get it right.

Static URL without "&expires=xxx"

2024-04-09.15-28-36_t.mp4

Dynamic URL with "&expires=xxx" that changes each request

2024-04-09.15-29-06_t.mp4

Sankaku Channel refuses to show an image and redirects to "expired" if you change anything in the URL or if you have a bad User-Agent.

from telegram-bot-api.

levlam avatar levlam commented on July 18, 2024

The photo is shown as received by Telegram from the specified URL.

from telegram-bot-api.

Sarisan avatar Sarisan commented on July 18, 2024

So this is Telegram servers issue?

from telegram-bot-api.

levlam avatar levlam commented on July 18, 2024

All photos are fetched from the specified URL by Telegram servers. But if the site returns "Expired link" to any request with Telegram's User-Agent, then there is no issue.

from telegram-bot-api.

Sarisan avatar Sarisan commented on July 18, 2024

May there be a chance that telegram-bot-api edits link_preview_options URL when it's used in InlineQueryResult?

from telegram-bot-api.

levlam avatar levlam commented on July 18, 2024

No, URL is passed exactly as provided to the server.

from telegram-bot-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.