Sharing my thoughts, discussing my projects, and traveling the world.
Contact: @borz
Last updated 1 week, 2 days ago
Telegram stands for freedom and privacy and has many easy to use features.
Last updated 1 day, 2 hours ago
Official Graph Messenger (Telegraph) Channel
Download from Google Play Store:
https://play.google.com/store/apps/details?id=ir.ilmili.telegraph
Donation:
https://graphmessenger.com/donate
Last updated 5 months, 2 weeks ago
Dear User,
Sitara Music again active but i disabled video play feature from source
```
VideoSourceNotFound
```
this will. Be shown as error message when you try playing video
Dear User,
Sitara Music is down due to the following issue I facing with all my servers...
Sign in to confirm you’re not a bot. This helps protect our community. Learn more
Idk when will be fixed but will be notified if done thanks
ᴜᴘᴅᴀᴛᴇ sɪᴛᴀʀᴀᴍᴜsɪᴄ ᴡᴇʟᴄᴏᴍᴇ ᴄᴏᴍᴍᴀɴᴅ ɪs ɴᴏᴡ ᴇɴᴀʙʟᴇᴅ ᴀɴᴅ ᴅɪsᴀʙʟᴇᴅ ғᴏʟʟᴏᴡɪɴɢ ᴀʀᴇ ᴄᴏᴍᴍᴀɴᴅs /wel on [to enable welcome] /wel off [to disable welcome] sᴏᴏɴ ᴡᴇ ᴡɪʟʟ ᴅᴏ ᴛʜᴇ sᴀᴍᴇ ғᴏʀ ʟᴇғᴛ ᴍᴇᴍʙᴇʀs ᴛᴏᴏ....
ᴜᴘᴅᴀᴛᴇ
sɪᴛᴀʀᴀᴍᴜsɪᴄ ᴡᴇʟᴄᴏᴍᴇ ᴄᴏᴍᴍᴀɴᴅ ɪs ɴᴏᴡ ᴇɴᴀʙʟᴇᴅ ᴀɴᴅ ᴅɪsᴀʙʟᴇᴅ
ғᴏʟʟᴏᴡɪɴɢ ᴀʀᴇ ᴄᴏᴍᴍᴀɴᴅs
/wel on [to enable welcome]
/wel off [to disable welcome]
sᴏᴏɴ ᴡᴇ ᴡɪʟʟ ᴅᴏ ᴛʜᴇ sᴀᴍᴇ ғᴏʀ ʟᴇғᴛ ᴍᴇᴍʙᴇʀs ᴛᴏᴏ....
Bot down with ytdlp issue soon active please wait
Bot down with ytdlp issue soon active please wait
sɪᴛᴀʀᴀ ᴍᴜsɪᴄ ᴜᴘᴅᴀᴛᴇ
ᴘᴏʀɴᴘʟᴀʏ ᴄᴏᴍᴍᴀɴᴅ ғɪxᴇᴅ ɴᴏᴡ
ᴜsᴇ ᴄᴏᴍᴍᴀɴᴅ /ᴘᴏʀɴ <ʏᴏᴜʀ ǫᴜᴇʀʏ> ᴏʀ /xɴxx <ʏᴏᴜʀ ǫᴜᴇʀʏ> ᴛᴏ ɢᴇᴛ ᴠɪᴅᴇᴏ ᴀɴᴅ ʀᴇᴘʟʏ ɪᴛ ᴡɪᴛʜ /ᴘʟᴀʏ ᴄᴏᴍᴍᴀɴᴅ ᴛʀʏ ᴛʜɪs ᴀɴᴅ ɢɪᴠᴇ ғᴇᴇᴅʙᴀᴄᴋ
Our Server Banned Only SomeBots Are On
```
import logging
from pyrogram import Client, filters
import yt_dlp
import asyncio
# Initialize Pyrogram client asynchronously
async def initialize_client():
async with Client("pinterest_bot") as app:
await app.start()
# Configure logging
logging.basicConfig(filename='error.log', level=logging.ERROR)
# Define download function
async def download_pin(url, message):
try:
ydl_opts = {
'outtmpl': '%(title)s.%(ext)s',
# Add any other yt-dlp options you need
}
async with yt_dlp.YoutubeDL(ydl_opts) as ydl:
info = await ydl.extract_info(url, download=True)
filename = ydl.prepare_filename(info)
await message.reply_document(document=filename)
except yt_dlp.utils.DownloadError:
await message.reply_text("Failed to download the pin. The URL might be invalid or the pin is not accessible.")
except yt_dlp.utils.ExtractorError:
await message.reply_text("Failed to extract information from the provided URL. Please check if it's a valid Pinterest URL.")
except yt_dlp.utils.UnsupportedError:
await message.reply_text("The provided Pinterest URL contains unsupported content.")
except yt_dlp.utils.NetworkError:
await message.reply_text("A network error occurred. Please check your internet connection and try again.")
except IndexError:
await message.reply_text("Please provide a valid Pinterest URL.")
except Exception as e:
logging.error(f"Error occurred during download: {e}")
await message.reply_text("An unexpected error occurred. Please try again later.")
# Define command handler with rate limiting
@app.on_message(filters.command("download_pin"))
@rate_limit
async def handle_message(client, message):
# Extract the Pinterest URL from the message
try:
url = message.text.split(" ", 1)[1]
except IndexError:
await message.reply_text("Please provide a valid Pinterest URL.")
return
# Call download function
await download_pin(url, message)
await message.reply_text("Pin download process initiated. Please wait...")
# Rate limiting decorator
def rate_limit(f):
async def wrapped(args, kwargs):
# Check if the user has already sent a request in the last 10 seconds
if args[1].from_user.id in rate_limit.users:
await asyncio.sleep(10)
rate_limit.users.add(args[1].from_user.id)
await f(args, **kwargs)
rate_limit.users.remove(args[1].from_user.id)
return wrapped
rate_limit.users = set()
# Start the Pyrogram client
async def main():
await initialize_client()
await app.idle()
if __name__ == "__main__":
app = Client("pinterest_bot")
app.run(main())
```
CHANGE ACCORDING TO USAGE
Sharing my thoughts, discussing my projects, and traveling the world.
Contact: @borz
Last updated 1 week, 2 days ago
Telegram stands for freedom and privacy and has many easy to use features.
Last updated 1 day, 2 hours ago
Official Graph Messenger (Telegraph) Channel
Download from Google Play Store:
https://play.google.com/store/apps/details?id=ir.ilmili.telegraph
Donation:
https://graphmessenger.com/donate
Last updated 5 months, 2 weeks ago