<br />
<b>Deprecated</b>:  Creation of dynamic property Yoast\WP\SEO\Premium\Generated\Cached_Container::$normalizedIds is deprecated in <b>G:\PleskVhosts\click2call.co.in\msgclub.net\blog\wp-content\plugins\wordpress-seo-premium\src\generated\container.php</b> on line <b>27</b><br />
<br />
<b>Notice</b>:  Function _load_textdomain_just_in_time was called <strong>incorrectly</strong>. Translation loading for the <code>updraftplus</code> domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the <code>init</code> action or later. Please see <a href="https://developer.wordpress.org/advanced-administration/debug/debug-wordpress/">Debugging in WordPress</a> for more information. (This message was added in version 6.7.0.) in <b>G:\PleskVhosts\click2call.co.in\msgclub.net\blog\wp-includes\functions.php</b> on line <b>6131</b><br />
{"id":356,"date":"2016-12-05T13:59:00","date_gmt":"2016-12-05T08:29:00","guid":{"rendered":"http:\/\/www.msgclub.net\/blog\/?p=356"},"modified":"2023-05-16T16:23:29","modified_gmt":"2023-05-16T10:53:29","slug":"send-sms-using-php-api-code","status":"publish","type":"post","link":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/","title":{"rendered":"Bulk SMS PHP API to send SMS via PHP API code"},"content":{"rendered":"\n<p>Along with developer and technocrats, you can also do&nbsp;<a href=\"http:\/\/www.msgclub.net\/sms-api\/php_api.aspx\">API Integration<\/a>&nbsp;into your software easily.<\/p>\n\n\n\n<p>With the help of ready to use&nbsp;<a href=\"http:\/\/www.msgclub.net\/sms-api\/php_api.aspx\">Bulk SMS PHP API<\/a>&nbsp;&nbsp;and source code, you can send information in few Minutes. We have ready PHP code for all kind of customer&#8217;s requirement like &#8211;<\/p>\n\n\n\n<p>1.&nbsp;<strong>Send SMS HTTP PHP source code or API&nbsp;&#8211;<\/strong>&nbsp;Send single number or less than 100-200 numbers with same content.<\/p>\n\n\n\n<p>2.&nbsp;<strong>Bulk SMS XML PHP source code or API&nbsp;&#8211;&nbsp;<\/strong>Send more than 200 numbers in a single click with same content.<\/p>\n\n\n\n<p>3.&nbsp;<strong>JSON PHP source code or Send SMS API&nbsp;&#8211;&nbsp;<\/strong>Send more than 200 numbers in single click with different content.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><img decoding=\"async\" src=\"blob:http:\/\/www.msgclub.net\/0b05ae94-1f3b-4527-ac7d-9d888fd1c4fb\"><\/h3>\n\n\n\n<h5 class=\"wp-block-heading\">The Web based&nbsp;&nbsp;Bulk SMS software&nbsp;enables to take any of API that belongs to its software.<br><\/h5>\n\n\n\n<p><strong>PHP HTTP&nbsp;Send SMS API<\/strong>&nbsp;is here for HTTP users&nbsp;\u2192<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td><a href=\"http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=YourAuthKey&amp;message=message&amp;senderId=dddddd&amp;routeId=1&amp;mobileNos=9999999999&amp;smsContentType=english\">http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSms?<strong>AUTH_KEY<\/strong>=YourAuthKey&amp;<strong>message<\/strong>=<\/a><a href=\"https:\/\/web.archive.org\/web\/20200301100042\/http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=YourAuthKey&amp;message=message&amp;senderId=dddddd&amp;routeId=1&amp;mobileNos=9999999999&amp;smsContentType=english\">message&amp;<strong>senderId<\/strong>=dddddd&amp;<strong>routeId<\/strong>=1&amp;<strong>mobileNos<\/strong>=9999999999&amp;<strong>smsContentType<\/strong>=english<\/a><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>PHP Sample API code in HTTP \u2192<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?php\n\nfunction sendsmsGET($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)\n\n{\n   $getData = 'mobileNos='.$mobileNumber.'&amp;message='.urlencode($message).'&amp;senderId='.$senderId.'&amp;routeId='.\n\n$routeId;\n\n  \/\/API URL\n\n $url=\"http:\/\/\".$serverUrl.\"\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=\".$authKey.\"&amp;\".$getData;\n\n   \/\/ init the resource\n\n   $ch = curl_init();\n   curl_setopt_array($ch, array(\n\n       CURLOPT_URL =&gt; $url,\n       CURLOPT_RETURNTRANSFER =&gt; true,\n       CURLOPT_SSL_VERIFYHOST =&gt; 0,\n       CURLOPT_SSL_VERIFYPEER =&gt; 0\n   ));\n\n   \/\/get response\n\n   $output = curl_exec($ch);\n\n   \/\/Print error if any\n   if(curl_errno($ch))\n\n   {\n      echo 'error:' . curl_error($ch);\n   }\n   curl_close($ch);\n   return $output;\n\n}\n\nfunction sendsmsPOST($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)\n\n{\n  \n   \/\/Prepare you post parameters\n\n   $postData = array(   \n     \n       'mobileNumbers' =&gt; $mobileNumber,       \n       'smsContent' =&gt; $message,\n       'senderId' =&gt; $senderId,\n       'routeId' =&gt; $routeId,       \n       \"smsContentType\" =&gt;'english'\n   );\n\n   $data_json = json_encode($postData);\n   $url=\"http:\/\/\".$serverUrl.\"\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=\".$authKey;\n\n   \/\/ init the resource\n\n   $ch = curl_init();\n\n   curl_setopt_array($ch, array(\n       CURLOPT_URL =&gt; $url,\n       CURLOPT_HTTPHEADER =&gt; array('Content-Type: application\/json','Content-Length: ' . strlen($data_json)),\n\n       CURLOPT_RETURNTRANSFER =&gt; true,\n       CURLOPT_POST =&gt; true,\n       CURLOPT_POSTFIELDS =&gt; $data_json,\n       CURLOPT_SSL_VERIFYHOST =&gt; 0,\n       CURLOPT_SSL_VERIFYPEER =&gt; 0\n   ));\n\n   \/\/get response\n\n   $output = curl_exec($ch);\n\n   \/\/Print error if any\n\n   if(curl_errno($ch))\n\n   {\n       echo 'error:' . curl_error($ch);\n   }\n\n   curl_close($ch);\n   return $output;\n}\n\n?&gt;<\/code><\/pre>\n\n\n\n<p><strong>PHP XML&nbsp;<a href=\"http:\/\/www.msgclub.net\/sms-service\/bulk-sms-api.aspx\">Bulk SMS API<\/a>&nbsp;<\/strong>is here for XML users&nbsp;\u2192<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td><a href=\"http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSmsXmlApi\"><a href=\"https:\/\/web.archive.org\/web\/20200301100042\/http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSmsXmlApi\">http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSmsXmlApi<\/a><br><br><\/a>\u00a0&lt;<strong>Sms<\/strong>><br>&lt;<strong>AUTH_KEY<\/strong>>yourAuthKey&lt;<strong>\/AUTH_KEY<\/strong>><br>&lt;<strong>smsContent<\/strong>>hello how are you&lt;<strong>\/smsContent<\/strong>><br>&lt;<strong>senderId<\/strong>>SMSTST&lt;<strong>\/senderId<\/strong>><br>&lt;<strong>routeId<\/strong>>2&lt;<strong>\/routeId<\/strong>><br>&lt;<strong>mobileNumbers<\/strong>>8888888888,9999999999&lt;<strong>\/mobileNumbers<\/strong>><br>&lt;<strong>smsContentType<\/strong>>english&lt;<strong>\/smsContentType<\/strong>><br>&lt;<strong>groupName<\/strong>>nid,a,groupA&lt;<strong>\/groupName<\/strong>><br>&lt;<strong>signature<\/strong>>abcde&lt;<strong>\/signature<\/strong>><br>&lt;<strong>scheduleddate<\/strong>>12\/05\/2015 12:00&lt;<strong>\/scheduleddate<\/strong>> \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0<br>&lt;<strong>\/Sms<\/strong>> \u00a0<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>PHP Sample &nbsp;API code in XML &nbsp;<\/strong>\u2192<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>&lt;?php<br><br>function sendsmsGET($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)<br>{<br>&nbsp;&nbsp;&nbsp;$getData = &#8216;mobileNos=&#8217;.$mobileNumber.&#8217;&amp;message=&#8217;.urlencode($message).&#8217;&amp;senderId=&#8217;.$senderId.&#8217;&amp;routeId=&#8217;.<br>$routeId;<br><br>&nbsp;&nbsp;&nbsp;\/\/API URL<br>&nbsp;&nbsp;&nbsp;$url=&#8221;http:\/\/&#8221;.$serverUrl.&#8221;\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=&#8221;.$authKey.&#8221;&amp;&#8221;.$getData;<br><br><br>&nbsp;&nbsp;&nbsp;\/\/ init the resource<br>&nbsp;&nbsp;&nbsp;$ch = curl_init();<br>&nbsp;&nbsp;&nbsp;curl_setopt_array($ch, array(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_URL =&gt; $url,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_RETURNTRANSFER =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYHOST =&gt; 0,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYPEER =&gt; 0<br>&nbsp;&nbsp;&nbsp;));<br><br><br>&nbsp;&nbsp;&nbsp;\/\/get response<br>&nbsp;&nbsp;&nbsp;$output = curl_exec($ch);<br><br>&nbsp;&nbsp;&nbsp;\/\/Print error if any<br>&nbsp;&nbsp;&nbsp;if(curl_errno($ch))<br>&nbsp;&nbsp;&nbsp;{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo &#8216;error:&#8217; . curl_error($ch);<br>&nbsp;&nbsp;&nbsp;}<br><br>&nbsp;&nbsp;&nbsp;curl_close($ch);<br>&nbsp;&nbsp;&nbsp;return $output;<br>}<br><br>function sendsmsPOST($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)<br>{<br><br>&nbsp;<br>&nbsp;&nbsp;&nbsp;\/\/Prepare you post parameters<br>&nbsp;&nbsp;&nbsp;$postData = array(&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;mobileNumbers&#8217; =&gt; $mobileNumber, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;smsContent&#8217; =&gt; $message,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;senderId&#8217; =&gt; $senderId,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;routeId&#8217; =&gt; $routeId,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8220;smsContentType&#8221; =&gt;&#8217;english&#8217;<br>&nbsp;&nbsp;&nbsp;);<br><br>&nbsp;&nbsp;&nbsp;$data_json = json_encode($postData);<br>&nbsp;&nbsp;&nbsp;$url=&#8221;http:\/\/&#8221;.$serverUrl.&#8221;\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=&#8221;.$authKey;<br><br>&nbsp;&nbsp;&nbsp;\/\/ init the resource<br>&nbsp;&nbsp;&nbsp;$ch = curl_init();<br><br>&nbsp;&nbsp;&nbsp;curl_setopt_array($ch, array(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_URL =&gt; $url,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_HTTPHEADER =&gt; array(&#8216;Content-Type: application\/json&#8217;,&#8217;Content-Length: &#8216; . strlen($data_json)),<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_RETURNTRANSFER =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_POST =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_POSTFIELDS =&gt; $data_json,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYHOST =&gt; 0,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYPEER =&gt; 0<br>&nbsp;&nbsp;&nbsp;));<br><br>&nbsp;&nbsp;&nbsp;\/\/get response<br>&nbsp;&nbsp;&nbsp;$output = curl_exec($ch);<br><br>&nbsp;&nbsp;&nbsp;\/\/Print error if any<br>&nbsp;&nbsp;&nbsp;if(curl_errno($ch))<br>&nbsp;&nbsp;&nbsp;{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo &#8216;error:&#8217; . curl_error($ch);<br>&nbsp;&nbsp;&nbsp;}<br>&nbsp;&nbsp;&nbsp;curl_close($ch);<br>&nbsp;&nbsp;&nbsp;return $output;<br>}<br><br>?&gt;<br><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>PHP JSON &nbsp;Bulk SMS API&nbsp;<\/strong>is here use&nbsp;\u2192<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>http:\/\/msg.msgclub.net\/rest\/services\/sendSMS\/sendGroupSms?<strong>AUTH_KEY<\/strong>=YourAuthKey<br><br><strong>English &#8211;<\/strong><br>{&#8220;<strong>smsContent<\/strong>&#8220;:&#8221;Hello Test SMS&#8221;,&#8221;<strong>groupId<\/strong>&#8220;:&#8221;0&#8243;,&#8221;<strong>routeId<\/strong>&#8220;:&#8221;1&#8243;,&#8221;<strong>mobileNumbers<\/strong>&#8220;:&#8221;9999999999&#8243;,&#8221;<strong>senderId<\/strong>&#8220;:<br>&#8220;SMSTST&#8221;,&#8221;<strong>signature<\/strong>&#8220;:&#8221;signature&#8221;,&#8221;<strong>smsContentType<\/strong>&#8220;:&#8221;english&#8221;}<br><br><strong>Unicode &#8211;<\/strong><br>{&#8220;<strong>smsContent<\/strong>&#8220;:&#8221;\u00e0\u00a4\u00b9\u00e0\u00a5\u0088\u00e0\u00a4\u00b2\u00e0\u00a5\u008b \u00e0\u00a4\u009f\u00e0\u00a5\u0087\u00e0\u00a4\u00b8\u00e0\u00a5\u008d\u00e0\u00a4\u009f \u00e0\u00a4\u008f\u00e0\u00a4\u00b8\u00e0\u00a4\u008f\u00e0\u00a4\u00ae\u00e0\u00a4\u008f\u00e0\u00a4\u00b8&#8221;,&#8221;<strong>groupId<\/strong>&#8220;:&#8221;0&#8243;,&#8221;<strong>routeId<\/strong>&#8220;:&#8221;1&#8243;,&#8221;<strong>mobileNumbers<\/strong>&#8220;:&#8221;9999999999&#8243;,&#8221;<strong>senderId<\/strong>&#8220;:<br>&#8220;SMSTST&#8221;,&#8221;<strong>signature<\/strong>&#8220;:&#8221;signature&#8221;,&#8221;<strong>smsContentType<\/strong>&#8220;:&#8221;unicode&#8221;},&#8221;<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>PHP Sample API code in JSON&nbsp;<\/strong>\u2192<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>&lt;?php<br><br>function sendsmsGET($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)<br>{<br>&nbsp;&nbsp;&nbsp;&nbsp;$getData = &#8216;mobileNos=&#8217;.$mobileNumber.&#8217;&amp;message=&#8217;.urlencode($message).&#8217;&amp;senderId=&#8217;.$senderId.&#8217;&amp;routeId=&#8217;.<br>$routeId;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/API URL<br>&nbsp;&nbsp;&nbsp;&nbsp;$url=&#8221;http:\/\/&#8221;.$serverUrl.&#8221;\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=&#8221;.$authKey.&#8221;&amp;&#8221;.$getData;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/ init the resource<br>&nbsp;&nbsp;&nbsp;&nbsp;$ch = curl_init();<br>&nbsp;&nbsp;&nbsp;&nbsp;curl_setopt_array($ch, array(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_URL =&gt; $url,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_RETURNTRANSFER =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYHOST =&gt; 0,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYPEER =&gt; 0<br><br>&nbsp;&nbsp;&nbsp;&nbsp;));<br><br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/get response<br>&nbsp;&nbsp;&nbsp;&nbsp;$output = curl_exec($ch);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/Print error if any<br>&nbsp;&nbsp;&nbsp;&nbsp;if(curl_errno($ch))<br>&nbsp;&nbsp;&nbsp;&nbsp;{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo &#8216;error:&#8217; . curl_error($ch);<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br><br>&nbsp;&nbsp;&nbsp;&nbsp;curl_close($ch);<br>&nbsp;&nbsp;&nbsp;&nbsp;return $output;<br>}<br><br>function sendsmsPOST($mobileNumber,$senderId,$routeId,$message,$serverUrl,$authKey)<br>{<br>&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/Prepare you post parameters<br>&nbsp;&nbsp;&nbsp;&nbsp;$postData = array(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;mobileNumbers&#8217; =&gt; $mobileNumber, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;smsContent&#8217; =&gt; $message,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;senderId&#8217; =&gt; $senderId,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8216;routeId&#8217; =&gt; $routeId, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8220;smsContentType&#8221; =&gt;&#8217;english<br>&nbsp;&nbsp;&nbsp;&nbsp;);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;$data_json = json_encode($postData);<br>&nbsp;&nbsp;&nbsp; $url=&#8221;http:\/\/&#8221;.$serverUrl.&#8221;\/rest\/services\/sendSMS\/sendGroupSms?AUTH_KEY=&#8221;.$authKey;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/ init the resource<br>&nbsp;&nbsp;&nbsp;&nbsp;$ch = curl_init();<br>&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;curl_setopt_array($ch, array(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_URL =&gt; $url,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_HTTPHEADER =&gt; array(&#8216;Content-Type: application\/json&#8217;,&#8217;Content-Length: &#8216; . strlen($data_json)),<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_RETURNTRANSFER =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_POST =&gt; true,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_POSTFIELDS =&gt; $data_json,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYHOST =&gt; 0,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CURLOPT_SSL_VERIFYPEER =&gt; 0<br>&nbsp;&nbsp;&nbsp;&nbsp;));<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/get response<br>&nbsp;&nbsp;&nbsp;&nbsp;$output = curl_exec($ch);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;\/\/Print error if any<br>&nbsp;&nbsp;&nbsp;&nbsp;if(curl_errno($ch))<br>&nbsp;&nbsp;&nbsp;&nbsp;{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo &#8216;error:&#8217; . curl_error($ch);<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>&nbsp;&nbsp;&nbsp;&nbsp;curl_close($ch);<br>&nbsp;&nbsp;&nbsp;&nbsp;return $output;<br>}<br>?&gt;<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>Just Integrate API easily into any software.&nbsp;We offer these&nbsp;<strong>Send SMS&nbsp;API<\/strong>&nbsp;in PHP in free of cost to<strong>&nbsp;<\/strong><a href=\"http:\/\/www.msgclub.net\/sms-service\/bulk-sms.aspx\">Send SMS<\/a><strong>&nbsp;<\/strong>directly&nbsp;from website or software. Only you have to pay the small amount for the send SMS services. For more details, you can&nbsp;<a href=\"http:\/\/www.msgclub.net\/contact_us.aspx\">Contact us<\/a>.<\/p>\n\n\n\n<p>To get more services check our <a href=\"http:\/\/www.msgclub.net\">website<\/a> now.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Along with developer and technocrats, you can also do&nbsp;API Integration&nbsp;into your software easily. With the help of ready to use&nbsp;Bulk SMS PHP API&nbsp;&nbsp;and source code, you can send information in few Minutes. We have ready PHP code for all kind of customer&#8217;s requirement like &#8211; 1.&nbsp;Send SMS HTTP PHP source code or API&nbsp;&#8211;&nbsp;Send single number &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"Bulk SMS PHP API to send SMS via PHP API code\" class=\"read-more button\" href=\"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/#more-356\" aria-label=\"Read more about Bulk SMS PHP API to send SMS via PHP API code\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[222,233],"tags":[13,6,42,244,240,242,243,245,241,7,179,239],"class_list":["post-356","post","type-post","status-publish","format-standard","hentry","category-developer-api","category-php","tag-api-integration","tag-bulk-sms","tag-bulk-sms-api","tag-php-api","tag-php-http-send-sms-api","tag-php-json-bulk-sms-api","tag-php-sample-api-code-in-http","tag-php-sample-api-code-in-json","tag-php-source-code","tag-send-sms","tag-send-sms-api","tag-send-sms-php-api","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-50"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v20.2.1 (Yoast SEO v27.3) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\r\n<title>Bulk SMS PHP API to send SMS via PHP API code - MSGCLUB Blog<\/title>\r\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\r\n<link rel=\"canonical\" href=\"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/\" \/>\r\n<meta property=\"og:locale\" content=\"en_US\" \/>\r\n<meta property=\"og:type\" content=\"article\" \/>\r\n<meta property=\"og:title\" content=\"Bulk SMS PHP API to send SMS via PHP API code\" \/>\r\n<meta property=\"og:description\" content=\"Along with developer and technocrats, you can also do&nbsp;API Integration&nbsp;into your software easily. With the help of ready to use&nbsp;Bulk SMS PHP API&nbsp;&nbsp;and source code, you can send information in few Minutes. We have ready PHP code for all kind of customer&#8217;s requirement like &#8211; 1.&nbsp;Send SMS HTTP PHP source code or API&nbsp;&#8211;&nbsp;Send single number ... Read more\" \/>\r\n<meta property=\"og:url\" content=\"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/\" \/>\r\n<meta property=\"og:site_name\" content=\"MSGCLUB Blog\" \/>\r\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/msgclubdotnet\/\" \/>\r\n<meta property=\"article:published_time\" content=\"2016-12-05T08:29:00+00:00\" \/>\r\n<meta property=\"article:modified_time\" content=\"2023-05-16T10:53:29+00:00\" \/>\r\n<meta name=\"author\" content=\"MSGCLUB Team\" \/>\r\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\r\n<meta name=\"twitter:creator\" content=\"@MSGCLUB\" \/>\r\n<meta name=\"twitter:site\" content=\"@MSGCLUB\" \/>\r\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"MSGCLUB Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\r\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/\"},\"author\":{\"name\":\"MSGCLUB Team\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#\\\/schema\\\/person\\\/bf3b82b3f61b1dc1487a1206b8ad8775\"},\"headline\":\"Bulk SMS PHP API to send SMS via PHP API code\",\"datePublished\":\"2016-12-05T08:29:00+00:00\",\"dateModified\":\"2023-05-16T10:53:29+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/\"},\"wordCount\":1330,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#organization\"},\"keywords\":[\"API Integration\",\"Bulk SMS\",\"Bulk SMS API\",\"PHP API\",\"PHP HTTP Send SMS API\",\"PHP JSON BUlk SMS API\",\"PHP sample API code In HTTP\",\"PHP sample API CODE in JSON\",\"PHP source code\",\"Send SMS\",\"Send SMS API\",\"Send SMS PHP API\"],\"articleSection\":[\"Developer API\",\"PHP\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/\",\"url\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/\",\"name\":\"Bulk SMS PHP API to send SMS via PHP API code - MSGCLUB Blog\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#website\"},\"datePublished\":\"2016-12-05T08:29:00+00:00\",\"dateModified\":\"2023-05-16T10:53:29+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/send-sms-using-php-api-code\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Bulk SMS PHP API to send SMS via PHP API code\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/\",\"name\":\"msgclub.net\",\"description\":\"One Stop Bulk Communication Services \",\"publisher\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#organization\",\"name\":\"MSGCLUB\",\"url\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/05\\\/msglogo-1.png\",\"contentUrl\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/05\\\/msglogo-1.png\",\"width\":200,\"height\":90,\"caption\":\"MSGCLUB\"},\"image\":{\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/msgclubdotnet\\\/\",\"https:\\\/\\\/x.com\\\/MSGCLUB\",\"https:\\\/\\\/in.linkedin.com\\\/company\\\/msgclub-net---india\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/#\\\/schema\\\/person\\\/bf3b82b3f61b1dc1487a1206b8ad8775\",\"name\":\"MSGCLUB Team\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g\",\"caption\":\"MSGCLUB Team\"},\"url\":\"https:\\\/\\\/www.msgclub.net\\\/blog\\\/author\\\/msgclub_1212\\\/\"}]}<\/script>\r\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Bulk SMS PHP API to send SMS via PHP API code - MSGCLUB Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/","og_locale":"en_US","og_type":"article","og_title":"Bulk SMS PHP API to send SMS via PHP API code","og_description":"Along with developer and technocrats, you can also do&nbsp;API Integration&nbsp;into your software easily. With the help of ready to use&nbsp;Bulk SMS PHP API&nbsp;&nbsp;and source code, you can send information in few Minutes. We have ready PHP code for all kind of customer&#8217;s requirement like &#8211; 1.&nbsp;Send SMS HTTP PHP source code or API&nbsp;&#8211;&nbsp;Send single number ... Read more","og_url":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/","og_site_name":"MSGCLUB Blog","article_publisher":"https:\/\/www.facebook.com\/msgclubdotnet\/","article_published_time":"2016-12-05T08:29:00+00:00","article_modified_time":"2023-05-16T10:53:29+00:00","author":"MSGCLUB Team","twitter_card":"summary_large_image","twitter_creator":"@MSGCLUB","twitter_site":"@MSGCLUB","twitter_misc":{"Written by":"MSGCLUB Team","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/#article","isPartOf":{"@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/"},"author":{"name":"MSGCLUB Team","@id":"https:\/\/www.msgclub.net\/blog\/#\/schema\/person\/bf3b82b3f61b1dc1487a1206b8ad8775"},"headline":"Bulk SMS PHP API to send SMS via PHP API code","datePublished":"2016-12-05T08:29:00+00:00","dateModified":"2023-05-16T10:53:29+00:00","mainEntityOfPage":{"@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/"},"wordCount":1330,"commentCount":0,"publisher":{"@id":"https:\/\/www.msgclub.net\/blog\/#organization"},"keywords":["API Integration","Bulk SMS","Bulk SMS API","PHP API","PHP HTTP Send SMS API","PHP JSON BUlk SMS API","PHP sample API code In HTTP","PHP sample API CODE in JSON","PHP source code","Send SMS","Send SMS API","Send SMS PHP API"],"articleSection":["Developer API","PHP"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/","url":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/","name":"Bulk SMS PHP API to send SMS via PHP API code - MSGCLUB Blog","isPartOf":{"@id":"https:\/\/www.msgclub.net\/blog\/#website"},"datePublished":"2016-12-05T08:29:00+00:00","dateModified":"2023-05-16T10:53:29+00:00","breadcrumb":{"@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.msgclub.net\/blog\/send-sms-using-php-api-code\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.msgclub.net\/blog\/"},{"@type":"ListItem","position":2,"name":"Bulk SMS PHP API to send SMS via PHP API code"}]},{"@type":"WebSite","@id":"https:\/\/www.msgclub.net\/blog\/#website","url":"https:\/\/www.msgclub.net\/blog\/","name":"msgclub.net","description":"One Stop Bulk Communication Services ","publisher":{"@id":"https:\/\/www.msgclub.net\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.msgclub.net\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.msgclub.net\/blog\/#organization","name":"MSGCLUB","url":"https:\/\/www.msgclub.net\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.msgclub.net\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.msgclub.net\/blog\/wp-content\/uploads\/2024\/05\/msglogo-1.png","contentUrl":"https:\/\/www.msgclub.net\/blog\/wp-content\/uploads\/2024\/05\/msglogo-1.png","width":200,"height":90,"caption":"MSGCLUB"},"image":{"@id":"https:\/\/www.msgclub.net\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/msgclubdotnet\/","https:\/\/x.com\/MSGCLUB","https:\/\/in.linkedin.com\/company\/msgclub-net---india"]},{"@type":"Person","@id":"https:\/\/www.msgclub.net\/blog\/#\/schema\/person\/bf3b82b3f61b1dc1487a1206b8ad8775","name":"MSGCLUB Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5d3ac483ecbecca27535a356900972d69a406a4a41baf31466c3be212608a6f7?s=96&d=mm&r=g","caption":"MSGCLUB Team"},"url":"https:\/\/www.msgclub.net\/blog\/author\/msgclub_1212\/"}]}},"_links":{"self":[{"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/posts\/356","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/comments?post=356"}],"version-history":[{"count":7,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/posts\/356\/revisions"}],"predecessor-version":[{"id":1241,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/posts\/356\/revisions\/1241"}],"wp:attachment":[{"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/media?parent=356"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/categories?post=356"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.msgclub.net\/blog\/wp-json\/wp\/v2\/tags?post=356"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}