Skip to content

Conversation

@Husniddin06
Copy link

@Husniddin06 Husniddin06 commented Jan 23, 2025

spam

import telebot
import requests

# Sizning tokeningiz
TOKEN = "7992899599:AAEt1pDbuNG-F6f0FBSqTL6I3MrT0U7kWt0"
bot = telebot.TeleBot(TOKEN)

# Instagram video yuklash uchun funksiyani aniqlaymiz
def get_instagram_video_url(url):
    try:
        api_url = f"https://savefrom.net/api/convert?url={url}"
        response = requests.get(api_url)
        if response.status_code == 200:
            result = response.json()
            return result.get("url")  # Haqiqiy yuklab olish havolasi
    except Exception as e:
        print(f"Xatolik yuz berdi: {e}")
    return None

# Botning /start komandasi uchun xabar
@bot.message_handler(commands=['start'])
def send_welcome(message):
    bot.reply_to(message, "Salom! Instagram video havolasini yuboring, men uni yuklab olish uchun havola qaytaraman.")

# Instagram havolasini qabul qilish va javob qaytarish
@bot.message_handler(func=lambda message: True)
def download_instagram_video(message):
    url = message.text.strip()
    if "instagram.com" not in url:
        bot.reply_to(message, "Iltimos, Instagram video havolasini yuboring.")
        return

    bot.reply_to(message, "Videoni yuklab olish uchun havola tayyorlanmoqda...")
    video_url = get_instagram_video_url(url)
    if video_url:
        bot.reply_to(message, f"Video tayyor! Yuklab olish uchun havola: {video_url}")
    else:
        bot.reply_to(message, "Kechirasiz, videoni yuklab bo'lmadi. Havola to'g'riligini tekshiring.")

# Botni ishga tushirish
bot.polling()
@ghost
Copy link

ghost commented Jan 23, 2025

The following commit authors need to sign the Contributor License Agreement:

Click the button to sign:
CLA not signed

@encukou
Copy link
Member

encukou commented Jan 23, 2025

This looks like spam.
If you have a contribution, could you describe it in English?

@encukou encukou closed this Jan 23, 2025
@AA-Turner AA-Turner changed the title Rename index.rst to pip install pyTelegramBotAPI requests <spam> Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants