Send SMS API For Android

1,314 views
Skip to first unread message

Nikita

unread,
Mar 29, 2011, 9:50:44 AM3/29/11
to phonegap
Hello All,

I want to send SMS from the Phonegap API in Android. And i have
searched a lot for finding the API but i didn't find any such API From
Phonegap Framework. Is their any send SMS API available in Phonegap,

At last i found one Javascript API for send sms :

http://wiki.phonegap.com/w/page/16494803/JavaScript-API#sms

In that their is the reference of send sms class but i am not able to
find such class from their and not able to do any more for send sms.

Also their is the post in this group for "Phonegap javascript API
proposal" :
http://groups.google.com/group/phonegap/browse_thread/thread/9c3bbcda8e183b04/d3c5e222148a454c?lnk=gst&q=send+SMS+API+Android#d3c5e222148a454c

And i found the same over their that is the send sms class containing
following functions:

SMS Class
• Void startListener([successCallback], [errorCallback])
• Void stopListener([successCallback], [errorCallback])
• Void onReceive(successCallback(sendersNumber, smsContent),
[errorCallback] )
• Void send(number, message, [successCallback], [errorCallback])

But from where i will get these class and how i implement it in my
phonegap android application.

Simon MacDonald

unread,
Mar 29, 2011, 11:38:35 AM3/29/11
to phon...@googlegroups.com
Use the sms:// protocol to send an SMS. 

<a href="sms:5551212" class="btn large">Send SMS</a>


When 0.9.5 comes out it will support the adding a SMS body.

<a href="sms:5551212?body=This is a bodyclass="btn large">Send SMS</a>


http://groups.google.com/group/phonegap/browse_thread/thread/5285e27eead57eac/f45f64f00842edcb?lnk=gst&q=Android+|+Set+SMS+Body#f45f64f00842edcb

--
You received this message because you are subscribed to the Google
Groups "phonegap" group.
To post to this group, send email to phon...@googlegroups.com
To unsubscribe from this group, send email to
phonegap+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/phonegap?hl=en?hl=en

For more info on PhoneGap or to download the code go to www.phonegap.com

Message has been deleted

Nikita

unread,
Mar 30, 2011, 3:51:02 AM3/30/11
to phonegap
Hi Mac,

Thanks for the help....

I have used this sms protocol and it works very well.But as i don't
know that how it works and the concept behind it, than its not the
fine with me for becoming Gud Programmer. So I want to know that how
this protocol work and how it does the process of message sending just
by writing a single line.... Any reference link is their from which i
can understand it...???

Yesterday, I have searched for the whole day but i didn't get any such
help for the send SMS API .
As i have told you that i found that their is the class of send sms
but i didn't get any such code of that class, what i get is just the
name of the class. I want to ask you that is their any such send sms
class is their? From where will i found such class.

Also i want to receive the sms from my application, so like sms
protocol is their any receive sms Protocol is their or any other
solution for receiving messages.

Thanks a Lot...
Bye....
Have a Nice Day... :-)

On Mar 29, 8:38 pm, Simon MacDonald <simon.macdon...@gmail.com> wrote:
> Use the sms:// protocol to send an SMS.
>
>    <a href="sms:5551212" class="btn large">Send SMS</a>
>
> When 0.9.5 comes out it will support the adding a SMS body.
>
> <a href="sms:5551212?body=This is a body" class="btn large">Send SMS</a>
>
> http://groups.google.com/group/phonegap/browse_thread/thread/5285e27e...+Set+SMS+Body#f45f64f00842edcb
>
> Simon Mac Donaldhttp://hi.im/simonmacdonald
>
> On Tue, Mar 29, 2011 at 9:50 AM, Nikita <nikita.saltri...@gmail.com> wrote:
> > Hello All,
>
> > I want to send SMS from the Phonegap API in Android. And i have
> > searched a lot for finding the API but i didn't find any such API From
> > Phonegap Framework. Is their any send SMS API available in Phonegap,
>
> > At last i found one Javascript API for send sms :
>
> >http://wiki.phonegap.com/w/page/16494803/JavaScript-API#sms
>
> > In that their is the reference of send sms class but i am not able to
> > find such class from their and not able to do any more for send sms.
>
> > Also their is the post in this group for "Phonegap javascript API
> > proposal" :
>
> >http://groups.google.com/group/phonegap/browse_thread/thread/9c3bbcda...

Nikita

unread,
Mar 30, 2011, 3:51:09 AM3/30/11
to phonegap
Hi Mac,

Thanks for the help....

I have used this sms protocol and it works very well.But as i don't
know that how it works and the concept behind it, than its not the
fine with me for becoming Gud Programmer. So I want to know that how
this protocol work and how it does the process of message sending just
by writing a single line.... Any reference link is their from which i
can understand it...???

Yesterday, I have searched for the whole day but i didn't get any such
help for the send SMS API .
As i have told you that i found that their is the class of send sms
but i didn't get any such code of that class, what i get is just the
name of the class. I want to ask you that is their any such send sms
class is their? From where will i found such class.

Also i want to receive the sms from my application, so like sms
protocol is their any receive sms Protocol is their or any other
solution for receiving messages.

Thanks a Lot...
Bye....
Have a Nice Day... :-)

On Mar 29, 8:38 pm, Simon MacDonald <simon.macdon...@gmail.com> wrote:
> Use the sms:// protocol to send an SMS.
>
>    <a href="sms:5551212" class="btn large">Send SMS</a>
>
> When 0.9.5 comes out it will support the adding a SMS body.
>
> <a href="sms:5551212?body=This is a body" class="btn large">Send SMS</a>
>
> http://groups.google.com/group/phonegap/browse_thread/thread/5285e27e...+Set+SMS+Body#f45f64f00842edcb
>
> Simon Mac Donaldhttp://hi.im/simonmacdonald
>
> On Tue, Mar 29, 2011 at 9:50 AM, Nikita <nikita.saltri...@gmail.com> wrote:
> > Hello All,
>
> > I want to send SMS from the Phonegap API in Android. And i have
> > searched a lot for finding the API but i didn't find any such API From
> > Phonegap Framework. Is their any send SMS API available in Phonegap,
>
> > At last i found one Javascript API for send sms :
>
> >http://wiki.phonegap.com/w/page/16494803/JavaScript-API#sms
>
> > In that their is the reference of send sms class but i am not able to
> > find such class from their and not able to do any more for send sms.
>
> > Also their is the post in this group for "Phonegap javascript API
> > proposal" :
>
> >http://groups.google.com/group/phonegap/browse_thread/thread/9c3bbcda...

Simon MacDonald

unread,
Mar 30, 2011, 10:45:25 AM3/30/11
to phon...@googlegroups.com
Well the code to handle the SMS uri is baked right into the Android
web browser. If you want to understand how it works you can look at
the Android documentation for the android.telephony package.

http://developer.android.com/reference/android/telephony/package-summary.html

The info that you found on a SMS API is outdated and no longer supported.

On Wed, Mar 30, 2011 at 3:50 AM, Nikita <nikita.s...@gmail.com> wrote:
> Hi Mac,
>
> Thanks for the help....
>
> I have used this sms protocol and it works very well.But as i don't
> know that how it works and the concept behind it, than its not the
> fine with me for becoming Gud Programmer. So I want to know that how
> this protocol work and how it does the process of message sending just
> by writing a single line.... Any reference link is their from which i
> can understand it...???
>
> Yesterday, I have searched for the whole day but i didn't get any such
> help for the send SMS API .
> As i have told you that i found that their is  the class of send sms
> but i didn't get  any such code of that class, what i get is just the
> name of the class. I want to ask you that is their any such send sms
> class is their? From where will i found such class.
>
> Also i want to receive the sms from my application, so like sms
> protocol is their any receive sms Protocol is their or any other
> solution for receiving messages.
>
> Thanks a Lot...
> Bye....
> Have a Nice Day... :-)
>
> On Mar 29, 8:38 pm, Simon MacDonald <simon.macdon...@gmail.com> wrote:

>> Use the sms:// protocol to send an SMS.
>>
>>    <a href="sms:5551212" class="btn large">Send SMS</a>
>>
>> When 0.9.5 comes out it will support the adding a SMS body.
>>
>> <a href="sms:5551212?body=This is a body" class="btn large">Send SMS</a>
>>

>> http://groups.google.com/group/phonegap/browse_thread/thread/5285e27e...+Set+SMS+Body#f45f64f00842edcb
>>
>> Simon Mac Donaldhttp://hi.im/simonmacdonald


>>
>> On Tue, Mar 29, 2011 at 9:50 AM, Nikita <nikita.saltri...@gmail.com> wrote:
>> > Hello All,
>>
>> > I want to send SMS from the Phonegap API in Android. And i have
>> > searched a lot for finding the API but i didn't find any such API From
>> > Phonegap Framework. Is their any send SMS API available in Phonegap,
>>
>> > At last i found one Javascript API for send sms :
>>
>> >http://wiki.phonegap.com/w/page/16494803/JavaScript-API#sms
>>
>> > In that their is the reference of send sms class but i am not able to
>> > find such class from their and not able to do any more for send sms.
>>
>> > Also their is the post in this group for "Phonegap javascript API
>> > proposal" :
>>

>> >http://groups.google.com/group/phonegap/browse_thread/thread/9c3bbcda...

Reply all
Reply to author
Forward
0 new messages