Pure-PHP TON (The Open Network) SDK — TLB Cell/BOC primitives, Ed25519 wallets, mnemonic, and a typed toncenter client in one composer require.
amashukov/ton-php is a standalone TON SDK for PHP — a single umbrella package that pulls the whole pure-PHP TON stack: TLB Cell / Builder / Slice with a canonical BOC encoder, Ed25519 KeyPair with TON-flavoured mnemonic derivation, a WalletV4R2 contract wrapper with an Address parser, and a typed toncenter v2 JSON-RPC client. Zero blockchain-library dependencies, no Symfony, no native extensions beyond the standard gmp / sodium / bcmath trio. Install it and the full TON wallet + toncenter stack is on your autoloader.
Cell / Builder / Slice with a byte-exact bag-of-cells encoder (matches @ton/core).KeyPair signing/verification plus TON-flavoured PBKDF2 Mnemonic derivation (not BIP-39).WalletV4R2 contract wrapper, InternalMessage builder, and a full TON Address parser (UQ/EQ, raw, bounceable flags).ToncenterWalletRpc implements the wallet's WalletRpcInterface, so a wallet reads its seqno and broadcasts a signed transfer through toncenter with no glue.composer require.olifanton/ton is the best-known PHP TON SDK (~300★), but it ships partial wallet coverage and no canonical bag-of-cells encoder, so cells you serialise may not round-trip byte-for-byte against @ton/core. amashukov/ton-php gives you a byte-exact canonical BOC encoder, a complete WalletV4R2 + Address surface, and a typed toncenter client — the entire stack behind one composer require, each layer separately versioned and individually installable.
composer require amashukov/ton-php
Each layer keeps its own namespace; import what you need:
use Amashukov\TonCell\Builder;
use Amashukov\TonWallet\WalletV4R2;
use Amashukov\Toncenter\ToncenterClient;
use Amashukov\Toncenter\ToncenterWalletRpc;
// Build cells, derive a wallet, broadcast through toncenter — see each
// sub-package README for the full API.
The packages compose cleanly: Amashukov\Toncenter\ToncenterWalletRpc implements the Amashukov\TonWallet\WalletRpcInterface port, so a wallet can read its seqno and broadcast a signed transfer through toncenter with no glue.
ext-gmp (bigint cell / address math)ext-sodium (Ed25519)ext-bcmathamashukov/http-client-php + nyholm/psr7)| Package | Layer |
|---|---|
| amashukov/ton-cell-php | TLB Cell / Builder / Slice + canonical BOC encoder |
| amashukov/ton-crypto-php | Ed25519 KeyPair + TON-flavoured PBKDF2 Mnemonic |
| amashukov/ton-wallet-php | WalletV4R2 wrapper, InternalMessage builder, Address parser |
| amashukov/toncenter-client-php | Typed toncenter v2 client over any PSR-18 transport |
| amashukov/http-client-php | PSR-18 cURL HTTP client |
| amashukov/eth-php | Sister umbrella SDK for Ethereum / EVM |
| amashukov/blockchain-context-bundle | Symfony 7 bundle wiring the TON + EVM stacks |
@PER-CS ruleset.@ton/core.MIT — see LICENSE. Each bundled package is MIT-licensed in its own repository.
How can I help you explore Laravel packages today?