No description, website, or topics provided.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
README.md
composer.json

README.md

SabaNovin PHP

Installation

Use in these ways :

composer require sabanovin/php

Usage

Send Simple SMS by SabaNovin API:

require __DIR__ . '/vendor/autoload.php';

try{
	$api = new \SabaNovin\SabaNovinApi( "API-Key" );
	$gateway = "100020500";
	$text = "متن تست";
	$to = array("09370000000", "09120000000");
	$result = $api->Send($gateway, $to, $text);
	if($result){
		foreach($result as $res) {
			echo "reference_id = $res->reference_id";
			echo "status   = $res->status";
			echo "mobile   = $res->mobile";
			echo "datetime = $res->datetime";
		}		
	}
}
catch(\SabaNovin\Exceptions\ApiException $e){
	echo $e->errorMessage();
}