Download the PHP package fibdesign/sms without Composer
On this page you can find all versions of the php package fibdesign/sms. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download fibdesign/sms
More information about fibdesign/sms
Files in fibdesign/sms
Package sms
Short Description a simple way to send your sms with Ghasedak api
License
Informations about the package sms
سرویس پیامکی قاصدک
سلام به روی ماهتون. این یه پکیج لاراوله برای ارسال پیامک از طریق سامانه پیام کوتاه قاصدک.
نصب
برای نصب از کمپوزر استفاده میکنیم:
برای اینکه بتونید تنظیمات شخصی خودتون رو انجام بدین، فایل کانفیگ پکیج رو بیایم انتقال بدیم به پوشه کانفیگ پروژه
بعد از وارد کردن این کامند، پروایدر زیر رو انتخاب کنید:
- Fibdesign\Sms\Providers\SmsProvider
یادتون نره که مقادیر رو توی env هم بزارید
متد های موجود در این نسخه از پکیج
توی نسخه فعلی پکیج میتونید یکی از کارهای زیر رو انجام بدین:
- ارسال تکی پیامک
- ارسال گروهی پیامک
- ارسال با قالب از پیش تعریف شده در سامانه
- دریافت باقی مانده اعتبار
- لیست پیام های دریافتی
مقدار ها
METHOD | SYNTAX | REQURIED | DESCRIPTION | EXAMPLE |
---|---|---|---|---|
to() | array of strings |
بلی | لیستی از تلفن های همراه که میخوای بهشون پیام بدی | $smsService->to(["0915348484"]) |
testers() | array of strings |
خیر | لیستی از تلفن های اضافه. برای مثال وقتی میخوای تلفن خودت توی همه پیام ها باشه، میتونی شماره خودت رو اینجا اضافه کنی. | $smsService->testers(["0915348484"]) |
template() | string |
خیر | مقداری که از قبل توی داشبورد توی سامانه تعریف کردی | $smsService->template('phoneVerification') |
as() | string |
خیر | مقادیر قابل قبول: single , group , credit , receive و template . مقدار پیشفرض: single . |
$smsService->as('single') |
message() | string |
بلی | متن پیام. | $smsService->message("Hi from Ghasedak") |
dispatch() | void | بلی | برای اینکه عمل ارسال انجام بشه، این رو حتما در آخر فراخوانی کنید | $smsService->dispatch() |
نحوه استفاده
بریم با هم چند تا نمونه ببینیم
ارسال پیام تکی
ارسال پیام گروهی
ارسال پیام با استفاده از قالب
دریافت مقدار باقی مانده کیف پول
نکته
توی پیام هاتون حتما کلمه لغو 11
رو قرار بدید وگرنه به مشکل میخورید!