-
To the project file
composer.jsonadd to therequiresection:"idfly/yii2-sms-devinotele": "dev-master" -
To the
repositoriessection:{ "type": "git", "url": "git@bitbucket.org:idfly/yii2-sms-devinotele.git" } -
Run
composer update -
Place to the project's configuration file:
'components' => [
...
'sms' => [
'class' => 'sms\devinotele\Provider',
'from' => '%from%', // one of the senders addresses in the account: https://my.devinotele.com
'login' => '%login%',
'password' => '%passowrd%',
'send_sms' => true,
'message_lifetime' => 0, // lifetime of the message in minutes
// (if the message is not delivered within lifetime the message is deleted); 0 - infinite
],
...
]
\Yii::$app->sms->send($to, $text);