TGViewer
PWRTelegram API channel PWRTelegram API channel @pwrtelegram · 728 subscribers
Post #488 1.32K

Forwarded from MadelineProto | Official Channel (Daniil Gentili)

Instantiation

use danog\MadelineProto\TON\API;

$API = new API(
[
'logger' => [
'logger' => Logger::ECHO_LOGGER
]
]
);


Usage:

$API->async(true);
$API->loop(
function () use ($API) {
yield $API->connect(__DIR__.'/ton-lite-client-test1.config.json');
var_dump(yield $API->liteServer->getTime());
}
);


For a full overview of async in MadelineProtoTon, take a look at the MadelineProto async docs.

For a full list of methods that can be used, simply look at the PHPDOC suggestions in your favorite IDE, or take a look at the ---functions--- section of the lite TL scheme (HTML docs coming soon).

This API can be used to build web-facing HTTP APIs that query the TON blockchain (using the async http-server), off-chain elements for TON applications and so much more!

Since it's in PHP & integrated in MadelineProto, you can also use it in free webhosts (aka use the blockchain on 000webhost AAAAAAAAA ❤️❤️❤️❤️❤️)
docs.madelineproto.xyz Async MadelineProto now features async, for incredible speed improvements, and parallel processing, all powered by amphp.
More from @pwrtelegram
  1. May 11, 2025And then, a long overdue post about my Autonomous System (AS198747), and an over more over…
  2. May 11, 2025The first series of posts I'll be adding here will be some technical deep dives into the p…
  3. May 11, 2025Happy to announce I've launched a blog, where I'll be posting news about all my different…
  4. Aug 25, 2024#FreeDurov.
  5. May 30, 2024MadelineProto was updated! MadelineProto 8.1.0 introduces an official Grafana dashboard fo…
  6. Apr 27, 2024MadelineProto was updated! 8.0.0 is the first stable release of MadelineProto v8! For the…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →