PHP code example of pishehgostar / exchange-melipayamak
1. Go to this page and download the library: Download pishehgostar/exchange-melipayamak library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
pishehgostar / exchange-melipayamak example snippets
return [
/*
|--------------------------------------------------------------------------
| Third Party Services
|--------------------------------------------------------------------------
|
| This file is for storing the credentials for third party services such
| as Mailgun, Postmark, AWS and more. This file provides the de facto
| location for this type of information, allowing packages to have
| a conventional file to locate the various service credentials.
|
// ...
'melipayamak'=>[
'username'=>'###',
'password'=>'###',
'from'=>'###',
]
];
class YourModel extends Eloquent
{
use Notifiable;
public function routeNotificationForMelipayamak(Notification $notification): array|string
{
return $this->mobile;
}
}
class InvoicePaidNotification extends Notification
{
public function via(object $notifiable): array
{
return ['melipayamak'];
}
// send sms using patterns
public function toMelipayamak(object $notifiable): MelipayamakSmsMessage
{
$pattern_code = '######';
$pattern_parameters = ['first','second'];
return (new MelipayamakSmsMessage)
->pattern($pattern_code,$pattern_parameters);
}
// send simple sms
public function toMelipayamak(object $notifiable): MelipayamakSmsMessage
{
return (new MelipayamakSmsMessage)
->simple('salam');
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.