Can I send an Anonymous SMS with Android? - android

I would like to send SMS (with Android) with an anonymous sender number or a different phone number from the actual sender phone number. (e.g. sender phone number 123, received SMS will show 456)
Is that applicable ? Please attach a small sample code.

You can't do it using the android API itself. You can however use some online SMS sending service.

Related

Google cloud messaging: 100 multiple senders limitation

My android application needs to enable GCM push notifications from multiple senders. I've read that it is possible here: Receiving messages from multi-senders. However, it is mentioned that there is a limit of 100 multiple senders. In my use-case I might have more than 100 senders (servers with different sender ids and api keys), but each application installed on a device will register to a small number of senders (less than 100).
This is how I need it to work:
1. When the user logs in, the client app will send a rest directly to the app server to get the sender ids which are relevant to that user. The number of possible sender ids is larger than 100, but for a specific user the subset of sender ids which are relevant to that user is probably 1.
2. The client app would execute the following code for each senderId in the set of returned sender ids:
String token = instanceID.getToken(senderId),
GoogleCloudMessaging.INSTANCE_ID_SCOPE, null);
I want to make sure that the limit of 100 multiple senders doesn't apply to my use-case. I tried searching more about the limitation, but came up empty.
Thanks in advance!
The limit of 100 multiple senders mentioned in [0] refers to senders used by a single instance of your app. Thus your specific use case is supported.
[0] https://developers.google.com/cloud-messaging/concept-options#receiving-messages-from-multi-senders

how to send different push notifications from python server to multiple android devices?

We have a python script which do specific job and we want when it see the trigger occurred , it sends a push notification to android devices
but we don't want to send a default message to all of our users.
we want to send customize message based on the trigger to our users
for example :
"user1" the "trigger" hits.
"user2" the "trigger" hits.
.
.
can you help me how to send different messages to different unique android IDs?
I suggest that you're familiar with GCM (official documentation for start you could find here Set up a GCM Client App on Android
Now regarding your question:
you have to have storage on your server where you save registration id, device token + any info which will help you to differ one user/device from another. For example, I did same thing for different apps and stored package_name in addition.
To send custom message you'll need:
1) choose to which devices/users you'll send a message (on exit you'll have a list of device tokens)
2) get list of registration ids from device tokens (on exit list of registration ids)
I separated 1 and 2 for simplicity.
3) I suggest that you know that GCM supports for up to 1,000 recipients for a single message. So you should form here a string of registration ids separated by comma. If you need to send message to 2500 devices, you need to do 3 requests.
4) send request to GCM server and see custom message on specific devices.
Regards.

Get all sms/mms sent to one specific phone number in Android

I am trying to get the list of all the sms/mms sent to one particular phone number. I have been able to do this by getting at least one sms/mms from that number and then based on the thread_id, I get the sent sms/mms to that phone number. However, I have not been able to filter Sent SMS/MMS based on the destination number given I am the sender. Any ideas ? I know that Android doesn't support interaction with SMS/MMS officially, at least, not up to API level 18.
You are right, although android doesn't support sms and mms interaction you can query the content provider responsible for the handling of sms and mms data.
Since you can query the content provider related to sms and mms data you can know the sent sms and mms and the destination of that sms and mms message.
I didn't flaged this answer as duplicate because the idea behind it is slightly different from the following link:
You can use this answer to build what you want to achieve:
How to Read MMS Data in Android?
The only difference is that you dont want to query the content provider for unread messages like i did but for sent messages and include the destination number

SMS from Android phone with different callback contact name

I have developed an android application which now I want to extend so as it can send text messages.
Most probably I will be able to find documentation on how to send a text message, but what I am looking for is something I don't know how to do a research on it.
There are two types of text messages you can receive.
One type is from a contact you already know, hence you will see the contact name.
Second type is from a contact you don't know. And, depending on the contact, you will either see a mobile number or a name (eg Google).
My goal is to extend my android application to send a text message in a way that the recipient will see a name as sender (eg Google) and not a mobile number.
I cannot extend my application to use 3G to communicate with a server and send the sms through the server nor I can use an online service which is going to send the sms.
I have to either send the text message from the android application directly or send an sms to an sms service to forward the text message to the recipient.
Is this possible to do?

Can I send a push notification to a phone which I only have its number?

Basically I'm asking about the Client Id - How do I contact someone without having them contact me first?
I believe your requirement implies sending an SMS or MMS. I can't think of any other protocol or standard that uses phone number as destination for the data.

Categories

Resources