Jump to content

Recommended Posts

Posted

As you can already tell, I like anything sms. Well here's another script. its a simple sms api udf. Hope you like it.

#include <HTTP.au3>
#include <IE.au3>
;CODE SAMPLES:              https://www.vazu.com/api/codesamples.php
;GET YOUR OWN KEY FOR FREE: https://www.vazu.com/api/autopartner.php
$key = ""
$to = "321-555-1212"
$from = "312-555-1212"
$msg = "Hey there you sexy scripter"

$return = sms( $key, $to, $msg, $from )

ConsoleWrite( $return )
;Return of 1 is a successfully sent message

Func sms($key, $to, $msg, $from="")
$msg = _HTTPEncodeString($msg)
$ie = _IECreate("www.vazu.com/api/http/InstantSendMessage?licensekey="&$key&"&dest-number="&$to&"&from-number="&$from&"&message="&$msg, 0, 0)
$response = _IEBodyReadText( $ie )
_IEQuit( $ie )
$response = StringSplit( $response, " " )
If IsArray($response) Then
    $result = StringSplit( $response[1], "=" )
    If IsArray($result) Then
        Return $result[2]
    Else
        Return 0
    EndIf
Else
    Return 0
EndIf
EndFunc
Check out ConsultingJoe.com
  • 1 month later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...