danog / MadelineProto
git clone https://github.com/danog/MadelineProto.git
8.11.1 · 1d ago
🔥 on GitHub Trending today
Async PHP client API for the telegram MTProto protocol
—
stars, 24h
+10
stars, 7 days · #1,579
—
stars, 30 days
3.5k
★ total · +0% this week
927
forks · 31 open issues
Star history starts 2026-10-20; the chart appears after the second daily snapshot.
LanguagePHP
LicenseAGPL-3.0
Created2016-06-23 (10y ago)
Last pushtoday
Watchers201
OwnerUser
Seen on GitHub Trending
- 2026-10-20 — #12 weekly in php · +10 ★
GitHub topics
amphpasyncbotcallseasyhacktoberfestinline-botsmadelineprotomtprotomtproto-apiphpproxysecret-chatsstickerstdlibtdlib-phptelegramtelegram-apivoip
Links
- GitHub: github.com/danog/MadelineProto
- Homepage: https://docs.madelineproto.xyz
- Releases · Issues · Hacker News mentions
README excerpt
# MadelineProto, a PHP MTProto telegram client Created by Daniil Gentili `#StandWithUkraine 🇺🇦` Do join the official channel, @MadelineProto and the support groups! Approved by Telegram! ## What's this? This library can be used to easily interact with Telegram **without** the bot API, just like the official apps. It can login with a phone number (MTProto API), or with a bot token (MTProto API, **no bot API involved!**). It is now fully async! ## Getting started (now fully async!) [code] Try running this code in a browser or in a console! Tip: if you receive an error (or nothing), send us the error message and the `MadelineProto.log` file that was created in the same directory (if running from a browser). ## Made with MadelineProto The following open source projects were created using MadelineProto: you can directly install them, or explore the source code as direct examples on how to use MadelineProto's many features! * magnaluna webradio - Multifeatured Telegram VoIP webradio * `simpleBot.php` - Extremely basic example * `tgstories_dl_bot.php` - Source code of @tgstories_dl_bot - Bot to download any Telegram Story! * `downloadRenameBot.php` - Download files by URL and rename Telegram files using this async parallelized bot! * `secret_bot.php` - Secret chat bot! * `pipesbot.php` - Creating inline bots and using other inline bots via a userbot! * `bot.php` - Examples for how to use filters, updates, get download links for any file, Telegram Stories and much more! Want to add your own open-source project to this list? Click here! Some of MadelineProto's core components are also available as separate, standalone libraries: - danog/async-orm - Async ORM based on AMPHP v3 and fibers. - danog/telegram-entities - A library to work with Telegram UTF-16 styled text entities. - danog/tg-file-decoder - A library to work with Telegram bot API file IDs. - danog/tg-dialog-id - A library to work with Telegram bot API dialog IDs. - danog/loop - Loop/actor model abstraction for AMPHP. - danog/better-prometheus - A better Prometheus library for PHP applications. - danog/ipc - Async IPC component for AMPHP. - danog/dns-over-https - Async DNS-over-HTTPS resolution for AMPHP. ## Documentation * Creating a client - This page explains how to create a MadelineProto instance. * Login - There are many ways you can login with MadelineProto. * Getting permission to use the telegram API * Automatic * Manual (user) * API ID * Manual (bot) * QR code login (user) * Features - MadelineProto can do everything official clients can do, and more! * Requirements - MadelineProto requires the mbstring, xml, json, fileinfo, gmp, openssl, iconv, gd extensions to function properly. * MadelineProto on Docker - MadelineProto offers an official MadelineProto docker image for the linux/amd64, linux/arm64 and linux/riscv64 platforms @ hub.madelineproto.xyz/danog/madelineproto. * Getting started * CLI bot (recommended) * Databases on docker * Web docker * Custom extensions