finds.dev← search

// the find

overtrue/easy-sms

★ 3,332 · PHP · MIT · updated May 2026

📲 一款多渠道的短信发送轮子

Easy SMS is a PHP library for sending SMS through multiple Chinese carriers and a handful of international ones (Twilio, Tiniyo). You configure multiple gateways, define a fallback order or random strategy, and the library tries them in sequence until one succeeds. It's aimed squarely at PHP apps that need to send OTPs or notifications in the Chinese market.

The gateway abstraction is clean — you implement one interface and your custom gateway plugs in without touching the core. The per-message gateway override lets you swap providers for specific message types without restructuring config. Error handling is unusually thorough: when all gateways fail, the thrown exception carries the full result set from every attempted gateway so you can actually debug what went wrong. Test coverage is broad and per-gateway, which matters because each carrier has its own quirks.

The gateway list is almost entirely Chinese domestic carriers; if your use case is anything outside China you're basically looking at Twilio and Tiniyo, which isn't much of a multi-gateway story. There are only two strategies — ordered and random — and no built-in retry backoff or circuit breaker per gateway, so a flapping provider will cause repeated failures before failing over. The content abstraction (content vs template + data) is thin: closures per field work but it's awkward boilerplate when you actually need different message shapes per gateway. PHP 8.4 requirement may surprise teams not yet upgraded.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →