How do I design sms service? - php

I want to design a website that can send and receive sms.
How should I approach the problem ?
What are the resources available ?
I know php,python what else do I need or are the better options available?
How can experiment using my pc only?[somthing like localhost]
What are some good hosting services for this? [edit this]
[Add more questions you can think of?]

You can take a look at Kannel. It's so simple to create SMS services using it. Just define a keyword, then put in the URL to which the incoming SMS request will be routed (you'll get the info such as mobile number and SMS text in query string parameters), then whatever output your web script generates (you can use any web scripting/language/platform) will be sent back to the sender.
It's simple to test. You can use your own PC and just use the fakesmsc "SMS center" and just send it HTTP requests. If you have a GSM modem you can use that too, utilising the modem's AT command set.

First thing, You need to sign up for an account (SMS gateway), most of them also give you example code how to send and receive sms using their API. Then you will wrap the the sms functionality around your sites logic.
e.g http://www.clickatell.com/developers/php.php

I've copied this from an answer I gave in relation to this question. However, in addition to the text below, take a look at Wadja's SMS Gateway deals (API link)... they appear to be a really good option at the moment, though I've not used them, personally.
Your main option for sending SMS messages is using an existing SMS provider. In my experience (which is extensive with SMS messaging web applications), you will often find that negotiating with different providers is the best way to get the best deal for your application.
Different providers often offer different services, and different features. My favourite provider, and indeed, the one that has happily negotiated with me for lower rates in the past, is TM4B (http://www.tm4b.com). These guys have excellent rates, cover a huge proportion of the globe, and have excellent customer service.
Below is some code extracted (and some parts obfuscated) from one of my live web applications, for sending a simple message via their API:
require_once("tm4b.lib.php");
$smsEngine = new tm4b();
// Prepare the array for sending
$smsRequest["username"] = "YOURUNAME";
$smsRequest["password"] = "YOURPWORD";
$smsRequest["to"] = "+441234554443";
$smsRequest["from"] = "ME!";
$smsRequest["msg"] = "Hello, test message!";
// Do the actual sending
$smsResult = $smsEngine->ClientAPI($smsRequest);
// Check the result
if( $smsResult['status'] == "ok" ) {
print "Message sent!";
} else {
print "Message not sent.";
}
Many other providers that I've used in the past, have very similar interfaces, and all are really competitive when it comes to pricing. You simply have to look around for a provider that suits your needs.
In regard to cost, you're looking at prices ranging from a few pence/cents for most Western countries (prices are a little bit higher for most third-world countries, though, so beware). Most providers you will have to pay in bulk, if you want decent rates from them, but they'll often negotiate with you for 'smaller-than-usual' batches. Most providers do offer a post-pay option, but only when you've successfully completed a few transactions with them... others offer it from the start, but the prices are extortionate.
Hope it helps!

You need a SMS server. This should get you started.

Since my company does this sometimes (text promotions etc, though our main focus is much much lower level stuff), I figured I should pitch in.
By far the simplest way is to use a service such as Clickatell, which provides a HTTP API, as well as FTP and SMPP amongst others. I don't know how Clickatell deals with receiving messages, however, as we use direct SMPP binds to our local mobile operators for this.
If you are willing to pay for it, you should be able to get an SMPP bind to your local mobile operator, but its often expensive. This would also allow you to purchase your own shortcode.
You may also want to give mBlox or Nextcell a look. A quick Google search will turn up more.
you could also buy a GSM modem, which would allow you to send and receive messages as you normally would with a phone, except through a PC. This usually means you will pay whatever you would with a phone. (In Ireland anyway)

Related

Send SMS messages from PC as if you were sending them by phone

Hello everyone my question is very specific I'm not asking how to send sms for free, obviously it would not make sense, much less no method with gateway that many telephone companies have blocked as an anti spam method to date, but I'm asking for example through api di telegram it is possible through form php and json to send from the software a message that arrives to the recipients as if you had sent it by smartphone.
The question is: how can you send text messages with php, which connect to your tariff plan as if you were sending them by phone, thanks
Although I think your question is quite ambiguous I'd suggest 2 possible ways depending on your priority.
If your main priority is using certain tariff plan (like using cheap SMS on certain simcards etc.) - your need to connect your simcard(s) to PC/server with GSM-modem or similar hardware. Then interact with it by COM-port etc. Also you may want to ask your GSM-carrier if you can use your tariff plan (simcard account) via some API but it's extremely low chances for positive reply. The API in most cases is not related to a simcard tariff plans but it do relates to some standalone Sms service.
If you main priority is the Number which your recipients may use for replies, you can look for SMS APIs with Virtual Long Number available. Many service providers allow to send SMS via API using VLN as alphanumeric sender name. This feature enables you to collect replies.

php script for sms facility

I'm making a project in my college, and I am making a web application. This web application is in openSuse. So the OS is Linux and I'm writing the code in php.
Now I want scripts in php for including sms facility in my project. So I need full information how to go about it and what code to implement
You need to use an online SMS provider. A quick trip to google brought up this: http://www.messagemedia.co.uk/sms-gateways.html (UK only, search in your country to find one that'll work for you). Then go to their API page and they should give you a nice PHP API to use.
Two basic approaches
Use an online SMS provider, as suggested by many other comments
Use a GSM modem with software like Gammu to handle sending and receiving text messages; almost any USB GSM dongle can handle this.
If I were to do something like this, I would just use the mail() function of PHP.
In the US at least, I think all phone numbers have an email address:
19999999999#sub.carrier.com
If you can extract the carrier from the number, you could just strip all non-numeric characters from the number and use the PHP mail function to send an email to that address, which in turn is a text message. This is how I forward emails via text to my feature phone (funny, the name is misleading).
There are a number of sites that extract information from the number, but I couldn't find an explicit algorithm. Here's one (I bet you could just use file_get_contents() on that webpage to get the carrier): http://fonefinder.net/
It's not too complicated, so have fun!
Have you seen http://www.twilio.com?
It's really cheap and incredibly easy to use. Why reinvent the wheel? :)
Depends on your needs. If you need to send AND receive and be able to process the incoming messages you are going to need more than just a simple SMS provider and are going to need somebody to partition a short/long code (I'm assuming you don't want to spend 1000$/month on a Short Code) to process incoming messages and forward them to you. You can set up keywords, or regular expressions that get run on messages then forwarded to your server.
If you are just going to be using just outbound SMS (notifications, etc.) than you can use something simple like Clickatell or Twilio.

Email Provider : dynamic content

We are building a daily newsletter based on member preferences. The member can choose a city and some categories among a list of 10. Basically each email will be different. Each email is generated by our server.
We are unable to find a provider with an API that can do that. Would you have any solution that ensure a 99% delivery.
Thank you
Damien
Seems to me like you don't need a third party solution. Your question is vague, maybe i'm misunderstanding.
You can build a custom webapp/webpage in PHP for example that would issue a request to the DB, fetch out member data, and construct emails to send out. In the simplest of scenarios this can be done in about an hour. Delivery is basically guaranteed assuming email addresses are correct and the server and network have decent uptime.
I built a similar service that emails users customized content based on preferences. I used a service called Triggermail, by Sailthru. I assemble the body html of the email on my server and then make an API call to them to actually send the mail to user.
They provide a control panel where you can define templates, upload lists of emails, and find out a (growing) number of statistics related to delivery, clickthrough, and they also handle opt-outs. They have excellent delivery rates, integrate with Google Analytics by just ticking a checkbox, and have a pretty fair cpm.
http://sailthru.com/
I know the owner, and can provide an introduction, if you'd like.
From the perspective of an email service provider, this is not dynamic content but static content, as you're assembling each copy yourself.
You should ask providers for "triggered" or "real time" messaging via an API, and indicate you provide each copy. You'll most commonly find APIS with facilities where you set up a template and only pass in the variables that drive the personalization. From your use case, you should also be able to work with that (same result, different implementation). Both definitely exist on the marketplace, but whether you're an interesting client depends of how many of these you plan to deploy (and of course what the origin of your list, your privacy practices etc are).

Need help creating a mass email program

New to the forum but love the comments. I'm tech savvy but not when it comes to programming, coding etc. So - I guess that makes me tech stupid for the moment.
Basically - I want to create a mass email program that will allow us to send bulk emails to our customers who signed an email slip. Currently - we're at 100,000 or so in our database but we expect to see this rise to 200,000 at some point.
What is the best script language to use for this?
Is PHP going to be handle this many emails?
What is the most emails that I can send in any one batch for it to still be "safe" so that the emails arrive to the proper recipients?
What is the term when you send directly from the server?
We currently have 3 servers and I'm assuming they are capable of doing this no problem...but I haven't spoken to our webhosting company just yet.
Lastly - I put together a powerpoint...that gives specs - is there anyone here that would be interested in a little side work to do the project? Really interested in the feedback. Thanks.
In general and based off what you said -- do not create your own mass email program.
Use a service, such as MailChimp or iContact.
Here's a small list of some of the things they do for you:
Manage the list
Handle unsubscriptions
Handle soft bounced emails
Handle hard bounced emails
Handle white listing (You have to pay third party companies $$$s a month to be on these lists)
Give you an idea of how likely and spammy your email is
How fast your email can be sent out (AOL will put you on their blacklist if you send out too fast)
Handle Analytics (such as how many were opened, when, where, what links were clicked on, linking to Google Analytics)
Handle multiple lists and variable replacement (such as "Dear _____")
Nice, easy-to-use interface.
Again, that's a small list in the scheme of things. Those were off the top of my head without too much thought.
EDIT
A couple big advantages I didn't mention:
a) Support
b) A community
c) Constant improvements
d) No server-management
Step 1. Acquire a real email server.
Step 2. Utilize said email server by having your scripts send the mail to it for delivery, and not directly.
Step 3. Throttle the mail server as necessary
Step 4. Monitor the non-delivery reports and remove addresses as necessary...
It depends on how you do this. You can:
1) loop and send 100 000 individual mail
2) Send 1 email with 100 000 people in BCC
or mix both. php can handle it well, but it's a huge task on the mail server.

Any way to detect SMS to E-Mail Gateways?

I want to create a PHP app that can send text messages ; There are different gateways for different email carriers.
Is there any library I could use that would be able to lookup or detect which gateway to use just by passing the phone number into it? This way I can take whatever email address I get out and use PHP's email functions to send a message.
There are companies that provide a lookup service, but it's generally not free (for example, we've used mBlox for this). There's no simple algorithm you can use, either, because of number porting and so on.
Zeep Mobile offers a free SMS API you can use, the catch is they tag your SMS with ads
There are a few SMS APIs out there that allow you to send without using an e-mail gateway. Twilio would be my recommendation. Using one of them you wouldn't have to even know the carrier.
As for detecting the carrier, codeka is right, there's no real way to know. Even google maps has a carrier select box.
The website http://www.freesmsgateway.info/ can provide the correct email address given a valid cellphone number (at least in the USA).
However I don't see any information about providing an API. You might, however, still be able to parse and use the results.
EDIT - I see they use an API from http://www.data24-7.com/ to power their site. Data24-7 claims to provide "real time API's".

Categories