Parcourir la source

Update index.lua (#127)

mtghr il y a 6 ans
Parent
commit
5d905bacbc
1 fichiers modifiés avec 6 ajouts et 1 suppressions
  1. 6 1
      sms/resources/install/scripts/app/sms/index.lua

+ 6 - 1
sms/resources/install/scripts/app/sms/index.lua

@@ -324,7 +324,12 @@
 			-- No XML content, continue processing
 			-- No XML content, continue processing
 			if (carrier == "flowroute") then
 			if (carrier == "flowroute") then
 				cmd = "curl -u ".. access_key ..":" .. secret_key .. " -H \"Content-Type: application/json\" -X POST -d '{\"to\":\"" .. to .. "\",\"from\":\"" .. outbound_caller_id_number .."\",\"body\":\"" .. body .. "\"}' " .. api_url;
 				cmd = "curl -u ".. access_key ..":" .. secret_key .. " -H \"Content-Type: application/json\" -X POST -d '{\"to\":\"" .. to .. "\",\"from\":\"" .. outbound_caller_id_number .."\",\"body\":\"" .. body .. "\"}' " .. api_url;
-			elseif (carrier == "twilio") then
+			
+		elseif (carrier == "peerless") then	
+   	        cmd = "curl -u" .. access_key .. ":" .. secret_key .. " -ki  https://mms1.pnwireless.net:443/partners/messageReceiving/".. access_key .."/submitMessage -H \"Content-Type: application/json\" -X POST -d '{\"from\":\"" .. outbound_caller_id_number .."\",\"recipients\":[\"+".. to .."\"],\"text\":\"" .. body .. "\"}'";
+		
+		
+		elseif (carrier == "twilio") then
 				if to:len() < 11 then
 				if to:len() < 11 then
 					to = "1" .. to;
 					to = "1" .. to;
 				end
 				end