From 9fd6bcae65c003ecf4ca9639798a49e511d0738b Mon Sep 17 00:00:00 2001 From: Beliam21 Date: Fri, 21 Jun 2024 13:45:53 +0300 Subject: [PATCH] Updated endpoints Updated endpoints --- README.md | 28 ++++++++++++++++------------ src/MobiWeb/Rest/Client.php | 4 ++-- tests/asynch_get_balance.php | 6 +++--- tests/asynch_get_pricing.php | 6 +++--- tests/asynch_send_full_example.php | 6 +++--- tests/asynch_send_single_message.php | 6 +++--- 6 files changed, 30 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index ce7aaad..87282a4 100644 --- a/README.md +++ b/README.md @@ -465,9 +465,10 @@ $username = ""; $password = ""; //Endpoint Options: -// Client::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// Client::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = MobiWeb\Rest\Client::SMPP_API_OTP_ENDPOINT; +// APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = MobiWeb\Rest\Client::SMPP_API_1_ENDPOINT; $client = new MobiWeb\Rest\Client($username, $password, $endpoint); @@ -497,9 +498,10 @@ $username = ""; $password = ""; //Endpoint Options: -// Client::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// Client::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = MobiWeb\Rest\Client::SMPP_API_OTP_ENDPOINT; +// APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = MobiWeb\Rest\Client::SMPP_API_1_ENDPOINT; $client = new MobiWeb\Rest\Client($username, $password, $endpoint); @@ -534,9 +536,10 @@ $username = ""; $password = ""; //Endpoint Options: -// Client::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// Client::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = MobiWeb\Rest\Client::SMPP_API_OTP_ENDPOINT; +// APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = MobiWeb\Rest\Client::SMPP_API_1_ENDPOINT; $client = new MobiWeb\Rest\Client($username, $password, $endpoint); @@ -573,9 +576,10 @@ $username = ""; $password = ""; //Endpoint Options: -// Client::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// Client::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = MobiWeb\Rest\Client::SMPP_API_OTP_ENDPOINT; +// APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = MobiWeb\Rest\Client::SMPP_API_1_ENDPOINT; $client = new MobiWeb\Rest\Client($username, $password, $endpoint); diff --git a/src/MobiWeb/Rest/Client.php b/src/MobiWeb/Rest/Client.php index c79bb43..106efbd 100644 --- a/src/MobiWeb/Rest/Client.php +++ b/src/MobiWeb/Rest/Client.php @@ -13,8 +13,8 @@ class Client { protected $auth; protected $endpoint; const API_ENDPOINT = "https://sms.solutions4mobiles.com/apis"; - const SMPP_API_OTP_ENDPOINT = "https://apix.solutions4mobiles.com/apis"; - const SMPP_API_MRK_ENDPOINT = "https://apix2.solutions4mobiles.com/apis"; + const SMPP_API_1_ENDPOINT = "https://apix.solutions4mobiles.com/apis"; + const SMPP_API_2_ENDPOINT = "https://apix2.solutions4mobiles.com/apis"; const HLR = "hlr"; const SMS = "sms"; const OTP = "otp"; diff --git a/tests/asynch_get_balance.php b/tests/asynch_get_balance.php index 8b575d0..7dc2374 100644 --- a/tests/asynch_get_balance.php +++ b/tests/asynch_get_balance.php @@ -10,9 +10,9 @@ //Endpoint Options: // APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default -// APIClient::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// APIClient::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = APIClient::SMPP_API_OTP_ENDPOINT; +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = APIClient::SMPP_API_1_ENDPOINT; $client = new APIClient($username, $password, $endpoint); diff --git a/tests/asynch_get_pricing.php b/tests/asynch_get_pricing.php index 6d50f61..4904a8b 100644 --- a/tests/asynch_get_pricing.php +++ b/tests/asynch_get_pricing.php @@ -10,9 +10,9 @@ //Endpoint Options: // APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default -// APIClient::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// APIClient::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = APIClient::SMPP_API_OTP_ENDPOINT; +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = APIClient::SMPP_API_1_ENDPOINT; $client = new APIClient($username, $password, $endpoint); diff --git a/tests/asynch_send_full_example.php b/tests/asynch_send_full_example.php index 9525c74..564fd35 100644 --- a/tests/asynch_send_full_example.php +++ b/tests/asynch_send_full_example.php @@ -10,9 +10,9 @@ //Endpoint Options: // APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default -// APIClient::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// APIClient::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = APIClient::SMPP_API_OTP_ENDPOINT; +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = APIClient::SMPP_API_1_ENDPOINT; $client = new APIClient($username, $password, $endpoint); diff --git a/tests/asynch_send_single_message.php b/tests/asynch_send_single_message.php index f018e23..7d6f3ee 100644 --- a/tests/asynch_send_single_message.php +++ b/tests/asynch_send_single_message.php @@ -11,9 +11,9 @@ //Endpoint Options: // APIClient::API_ENDPOINT - REST API (SMS, OTP, HLR) - Default -// APIClient::SMPP_API_OTP_ENDPOINT - Asynchronous SMS API (SMS) - For (one-time pins) OTP & Notification messages -// APIClient::SMPP_API_MRK_ENDPOINT - Asynchronous SMS API (SMS) - For marketing messages -$endpoint = APIClient::SMPP_API_OTP_ENDPOINT; +// APIClient::SMPP_API_1_ENDPOINT - Asynchronous SMS API (SMS) +// APIClient::SMPP_API_2_ENDPOINT - Asynchronous SMS API (SMS) - Alternative +$endpoint = APIClient::SMPP_API_1_ENDPOINT; $client = new APIClient($username, $password, $endpoint);