Sending sms and receiving delivery report in J2me - java-me

I am developing a project where I need to send an sms to the contact and if the contact doesn't receives the sms I have to send him another or choose another contact. So, for notifying my midlet of successful sms delivery i'll need to receive and read the sms delivery report.
How to read delivery report using j2me? Or Is there any other way to achieve this?

If you put your application on the Nokia store it will be automatically signed by Nokia to the 3rd party trusted domain, so the prompts will be less. Also i think if you implement SATSA JSR http://en.wikipedia.org/wiki/Security_and_Trust_Services_API_for_J2ME you can talk to the Sim card and get relevant information maybe on delivery of SMS also, but you need the app to be signed to the operator domain for permission. On the other hand, if you have an SMPP connection to a server you can send SMS to users with a port number and also view the message status there.

Related

Twillio Error 30004 "Message Delivery - Message blocked"

I integrated twillio for signup user in my application. From my application twillio SMS send to User for One Time Password(OTP). If user can verify OTP then and then he can register in my App.
But Sometime Twillio give error code 30004. But I want to send SMS forcefully to user without any restriction. Is there any way to fulfill my requirement.
I also read this page of twillio for my error https://support.twilio.com/hc/en-us/articles/223134167-Limitations-sending-SMS-messages-to-Indian-mobile-devices
But I want to send SMS to user any how.
Twilio developer evangelist here.
I am guessing, since you mention the article on limitations of sending SMS to India that you are trying to send to an Indian device.
As you have read, there are a number of issues with sending to India that all follow from India's classification of services like Twilio as marketing. For this reason, you are unable to send messages outside of the hours of 9am - 9pm and if a number is on the Do Not Call registry your message will never be delivered.
If you are trying to implement two factor authentication for India then I recommend you do so using an authenticator application. You can do this using Twilio's Authy API or by generating a secret and sharing it to applications like Authy or Google Authenticator.
This is more secure than 2FA over SMS and means you do not need to send SMS and rely on delivery in India. Instead the authentication can happen between the server and the device. This is what GitHub did for their 2FA and you can read why about that here.
Let me know if that helps at all.
Error 30004 "Message Delivery - Message blocked" when Sending SMS
If a message you sent is not delivered to the end device and returns a 30004 error code, this means that delivery of your message failed because the destination is blocked from receiving this message

How can you send SMS for an existing phone number without Twilio?

I want to make a service for existing business so if they receive a message it automatically gets parsed by my bot and if necessary bot responds to it from the same number.
With Twilio, you need to move your number over to them, which is very inconvenient for businesses who often have land phone lines.
Twilio developer evangelist here.
You need to move numbers to Twilio in order to use the Twilio service because that is the only way that Twilio can receive calls and SMS messages from the phone network for that number.
If you are working on behalf of a business that has a landline, then why not purchase a Twilio mobile number for them that can be used for the chat bot? That way they keep their existing number for calls, but customers can interact with them in a new way via the mobile number and your chat bot.

Track sms conversation with twilio and there is multiple conversation between two numbers

I am building customer service application and I have integrated Twilio for all SMS operations.
Now when customer request for the service system will generate one ticket and details will be messaged on customer's number.
and then the customer can message to my Twilio number which is service center specific(I mean each service center has been assigned one Twilio number) and service center executive can reply him back so I want to make this SMS conversation.
I can use cookies twilio SMS conversations but it won't work in the case when my application will first message as I can only set cookie when my server is actually acting as a server which will be only in receiving SMS
which is narrated in Application Initiated Conversations section in above article.
and another problem is there can be multiple tickets for single user with particular service center so how to manage it.
Any help is appreciated.
Twilio developer evangelist here.
SMS is a simple protocol that has no idea of different conversations, simply a chronologically ordered set of messages. There are two ways to get around this.
You can either insist that your user include an ID for the ticket they are referring to so that you can parse it out of the message and associate it to the right conversation.
Alternatively, you can add more than one number per service centre that can be used for different conversations.
Let me know if that helps at all.

How to retrieve a phone number for a gprs request in a j2me application?

I am creating an j2me application in which for activation user sends a GPRS request request. Can we get the user phone number with his GPRS request?
I don't think it's possible, I mean up to MIDP2, I don't know about MIDP3 yet.
You must think of different mechanism to get the phone number, for instance is sending SMS via the application to Server SMS Gateway,
The mechanism goes like this :
- Your application send SMS to Server SMS gateway
- Server generate some random number and then save this random number to phone number match in database.
- And then SMS Gateway send SMS reply which contain the random number to the application.
- Your application retrieve the content of the SMS (which is the server generated random number) and save it to local DB.
- After this everytime you send any request (HTTP request) you send also the random number you have saved.
Therefore in the server you can find out which phone send the request.

sending sms in j2me

i wrote a sending sms program through wireless messaging in j2me..but whenever i am sending message they are asking permission for sending mssg.
You need to sign your midlet otherwise you will get these security prompts whenever you use an API such as network connection or SMS.
even if you sign your midlet with a 3rd party certificate from Verisign/Thawte you will end up with prompts, the only other suggestion is to use an sms aggregator such as a clickatell to proxy the sms for you
The confirmation is there by design, and from the user's point of view he/she do not want applications to be able to send sms messages without his/her knowledge because they cost money. Your question is in some way like "how can I connect to my neighbour's wifi access point without supplying the required password".

Resources