Git Product home page Git Product logo

way2sms-api's Introduction

Way2SMS PHP API

Send SMS Via Way2SMS from PHP.

Tested Working with Way2SMS UI Version 4. Supports upto 140 Characters
Way2SMS has added a Captcha Verification. Will update when I can find a workaround
UPDATE: Fully functional again :)

How to Use

Simple Usage
<?php
    include('way2sms-api.php');
    sendWay2SMS ( '9000012345' , 'password' , '987654321' , 'Hello World');   
    sendWay2SMS ( '9000012345' , 'password' , '987654321,9876501234' , 'Hello World');   
?>
Multiple Messages with different content
<?php 
    include('way2sms-api.php');
    $client = new WAY2SMSClient();
    $client->login('username', 'password');
    $client->send('987654321', 'msg1');
    //Add sleep between requests to make this requests more human like! 
    //A blast of request's may mark the ip as spammer and blocking further requests.
    sleep(1);
    $client->send('987654321,9876501234', 'msg2');
    sleep(1);
    $client->logout();
?>

HTTP API

Send SMS just making GET or POST Requests.

Incase u want to use the service from your application then the parameters for ur application would be

http://www.yourdomain.com/sendsms.php?uid=LOGIN_ID&pwd=PASSWORD&phone=XXXXXXXXX,YYYYYYYYY&msg=Hello+World

Parameters
uid = LOGIN_ID ( Your Login ID [either nickname or 10 Digit mobile no] )
pwd = PASSWORD ( Your Login Password )
phone = 10 Digit Mobile number. Incase of multiple numbers then numbers separated by comma (,)
msg = Your Message.

Note

Please use this code on your own risk. The author is no way responsible for the outcome arising out of this.

way2sms-api's People

Contributors

kingster avatar suyashbansal avatar yashkumarverma avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

way2sms-api's Issues

Repeated Login and Logout

Say a user has to send messages with different content to different people. This can be done using loop, but the problem is that, whenever the function is called, it logs into the website, send the message and then logsout every time. This is acceptable for 2-3 messages but for say about 30 messages, it becomes a very extensive process.
Is there any way to skip the re-login and re-logout every-time ?

Cheers !

Error!

Getting the following below error
PHP Notice: Undefined property: WAY2SMSClient::$jstoken in /home/pi/Way2SMS-API/way2sms-api.php on line 108

Getting error of output started on this line

I am trying to send sms by using your code its working fine but when i try to send sms by your code and redirecting by header then a error is ooccured then output is started on n line.but i am not seeing any output befor header may be in your output is started some wherw plss help me to resolve issue

Not Working

I have tried But It is not working.
I am getting access error : Empty reply from server in response.
Is there any change made by way2sms ?

Its not working anymore

It stopped working again two weeks back. Could somebody troubleshoot and correct the code

Thanks

Message not getting delivered

This is not able to send any message even after some changes like,

  1. Adding +91 as a prefix in senders mobile number.
    Doing this it says true (Message delivered), but the message never delivered.

Invalid login

when running code with correct uid, pwd getting false every time. so I debug the code then got "invalid login" every time. with wrong and correct uid, pwd

invalid login
D:\wamp\www\Way2SMS-API-master\sendsms.php:72:
array (size=1)
0 =>
array (size=3)
'phone' => string '8829980508' (length=10)
'msg' => string 'YOUR MESSAGE ' (length=13)
'result' => boolean false

"invalid login" is getting every time from way2sms-api.php page. on these lines :
$pos = stripos(curl_getinfo($this->curl, CURLINFO_EFFECTIVE_URL), "ebrdg.action");
if ($pos === "FALSE" || $pos == 0 || $pos == ""){
echo "invalid login";die();
//return "invalid login";
}

URL Change

Hi

The SMS POST url seems like changed.

It is way2sms.com/jsp/stp2p.action

May be you should try updating the script with correct url

It stopped Working

The api seems to have stopped working since a week , I've been using it for the past months . Please resolve this and make this work again ! Thanks

Issue with Slim framework

Hello,
I am using your script to send sms, it is working very well with php without any framework, but when i try the same script with Slim framework it stop working.

Undefined property: WAY2SMSClient::$jstoken
this is the error i am receiving. Please help, i am a mobile app developer and do not have much experience in PHP or related frameworks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.