Can I send a custom MMS in response to an SMS?

Can I send a custom MMS in response to an SMS? SearchSearch
Author Message
Keith Ahern
Unregistered guest
Posted on Monday, January 17, 2005 - 11:24 am:   

I want to send a custom MMS with text and pictures from a database in response to a numeric code in an SMS. I've looked at the documentation for 2-way SMS and I'm not sure if it does everything I need. The bit I'm confused about is how I send back an MMS since it looks like I can only point it to a local command or HTTP server.

Less desirable but still acceptable is to prepolutate a directory with the MMS 'files' and return them e.g.

SMS 19023

return contents of

d:\mms\19023.mms

What format is 19023.mms? which of Now.SMSs products would I need to fulfil the above scenario?

Ideally my HTTP server would return a SMIL file with embedded content, or content linked via HTTP which non.sms would magically compile into a single MMS file which my gprs phone/modem would deliver.

Thanks in advance
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 3874
Registered: 10-2002
Posted on Monday, January 17, 2005 - 05:13 pm:   

Hi Keith,

It is possible, but a bit confusing.

Here is an old thread, however, that I think will help you out:

http://support.nowsms.com/discus/messages/1/507.html

A few additional notes ...

You wouldn't really want to define a separate 2-way command for each keyword request. It would be easier to maintain if you developed a script that redirected to different URLs based upon the keyword that was detected by the script.

An example showing a redirect from a PHP script is found in the following link (the example sends an SMS, but you would just modify the redirect link).

http://support.nowsms.com/discus/messages/1/4520.html
http://support.nowsms.com/discus/messages/1/3991.html

Also, note that you don't necessarily have to construct the pre-compiled MMS message file for sending if you don't want to. (We have a command line utility called MMSCOMP that is included with NowSMS that builds them.)

The example that we give for sending an MMS message by referencing the objects from a URL only shows including a single non-text object. (I'm referring to the URL example at the bottom of the following page: http://www.nowsms.com/documentation/ProductDocumentation/mms_notifications_and_c ontent/Submitting_MMS_Messages_URL.htm)

However, it is possible to repeat the MMSFILE reference to reference multiple objects ... and one of those objects can be your SMIL file so that you do not have to compiled the objects into a ".mms" file first.

-bn
Keith Ahern
Unregistered guest
Posted on Friday, February 25, 2005 - 04:51 am:   

Hi Bryce,

I've followed instructions above and I've successfully have 2 way sms working. However I can not get sms->return MMS to fully work. My phone gets the SMS notification of an MMS but never downloads it, i assume because its trying to get the mms file from my test machine which is behind a firewall and obviously out of vodafones walled garden. To clarify I'm using a HTTP GET with multiple MMSFILE parameters and Phone number etc. an mms file gets created by now.sms.

I am *NOT* using now.sms as an MMSC, I'm trying to use the default MMSC via the attached Sony Ericsson T610. i.e. I want to send this MMS via vodafones MMSC . The phone can send MMSes from its MMS composer.

How do I tell now.sms to connect to vodafones MMSC via the phone?

thanks in advance

Keith
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 4105
Registered: 10-2002
Posted on Monday, February 28, 2005 - 07:25 pm:   

Hi Keith,

You need to configure an "MMSC Routing" definition that tells NowSMS how to send MMS messages via the operator MMSC.

See:

http://www.nowsms.com/documentation/ProductDocumentation/mms_notifications_and_c ontent/Connecting_to_operator_MMSC.htm

And for Vodafone specific settings, see:

http://support.nowsms.com/discus/messages/485/491.html
Keith Ahern
Unregistered guest
Posted on Wednesday, March 02, 2005 - 06:23 am:   

Thanks Bryce,

I'm very, very close. However I still do not receive MMSes.
I added the MMSC routing and as my logs show I'm connecting to vodafones MMSC. The 'Test Connection' on the MMSC Routing tab works. As I stated before I'm confused as to whether I need to run the now.sms MMSC or not. If I do NOT RUN the now.sms mmsc I can't post MMS messages:


Trying 192.168.1.103...
Connected to 192.168.1.103.
Escape character is '^]'.
GET /?PhoneNumber=+61415NNNNNN&MMSTEXT=Beach&MMSFILE=http://192.168.1.100/realportal/edsilk/data/images/7/pic_view_01-mms.jpg HTTP/1.0

HTTP/1.0 500 Internal Error
Content-type: text/html
Expires: Tue, 01 Jan 1980 1:00:00 GMT
Cache-Control: no-cache

<HTML><HEAD><TITLE>
Internal Error</TITLE></HEAD>
<BODY><H1>Error: MMSC Service Not Active</H1></BODY></HTML>
Connection closed by foreign host.

When I turn on the now.sms MMSC I get a successful submission and the logs look good.

Trying 192.168.1.103...
Connected to 192.168.1.103.
Escape character is '^]'.
GET /?PhoneNumber=+61NNNNNNN&MMSTEXT=Beach&MMSFILE=http://192.168.1.100/realportal/edsilk/data/images/7/pic_view_01-mms.jpg HTTP/1.0

HTTP/1.0 200 OK
Content-type: text/html
Expires: Tue, 01 Jan 1980 1:00:00 GMT
Cache-Control: no-cache

<HTML>
<HEAD><TITLE>Message Submitted</TITLE></HEAD>
<BODY>
<p>
Message Submitted
<p>
<a href="javascript:history.back()">Continue</a>
<p>
</BODY>
</HTML>

However you will see a packet in my logs that looks like the vodafone MMSC tried to connect back to my server, which is unaccessible behind a firewall and has a NAT'ed IP address. Heres the packet:

15:37:04:456 [468] Debug: Before sendto
15:37:04:456 [468] Debug: After sendto
15:37:04:456 [468] WSPRequest: Debug: 10.202.2.60: requestOffset = 12600, requestLength = 13713
15:37:06:309 [468] WSPRequest: Packet Length is 85 bytes
15:37:06:309 [468] WSPRequest: 12 80 04 04 20 05 94 88 80 8D CA 01 04 6A 00 7F j
15:37:06:309 [468] WSPRequest: 7B E8 37 03 62 61 63 6B 00 18 03 42 61 63 6B 00 { 7 back Back
15:37:06:309 [468] WSPRequest: 01 32 01 01 67 60 03 20 43 6F 75 6C 64 6E 27 74 2 g` Couldn't
15:37:06:309 [468] WSPRequest: 20 72 65 61 63 68 20 74 68 65 20 69 6E 64 69 63 reach the indic
15:37:06:309 [468] WSPRequest: 61 74 65 64 20 77 65 62 20 73 65 72 76 65 72 2E ated web server.
15:37:06:309 [468] WSPRequest: 20 00 01 01 01
15:37:06:309 [468] WSPRestoreRoute: Modem: Unknown Modem
15:37:06:309 [468] WSPRequest: Sending 3 byte packet to 10.202.2.60
15:37:06:309 [468] WSPRequest: Packet Length is 3 bytes
15:37:06:309 [468] WSPRequest: 18 00 04

What webserver is it trying to reach?

I have also included a snapshot of my mmsc setting.

thanks again for helping me get this far.

Keith

BTW 'Unknown Modem' is the name of the modem I'm using, it works.

application/zipLogs and snapshots
NowSMSLog.zip (81.4 k)
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 4136
Registered: 10-2002
Posted on Wednesday, March 02, 2005 - 10:29 pm:   

Hi Keith,

You do need to have the MMSC running. It performs all outbound MMS routing.

On to your logs ... we are trying to post to http://pxt.vodafone.net/pxtsend, which I assume is what you have configured as the MMS Server URL.

Based upon a quick web search, I think the correct URL for Vodafone Australia is:

http://pxt.vodafone.net.au/pxtsend

Give that a try, and just to recap, I believe these are the settings for Vodafone Australia:

APN: live.vodafone.com
User ID & Password: not required
WAP Gateway IP: 10.202.2.60
MMS Server URL: http://pxt.vodafone.net.au/pxtsend


And "Unknown Modem" is fine. We don't use any advanced features of any modem drivers, which is why I often tell people that the "Standard Modem" drivers are fine.

-bn
denis
New member
Username: Denis690

Post Number: 1
Registered: 06-2005
Posted on Thursday, June 23, 2005 - 01:15 pm:   

I sent MMS from NowSMS to Vodafone, but I can't download it and it has been rejected with an "HTTP/1.0 500 Internal Error". I think it is because of the "content-type: text/plain" to be added into the GET requiest by Vodafone. Can I configure NowSMS to ignore that field? Please advice! Thank You!

Here the log from NowSMS:

12:25:49:348 [7] ThreadProcessConnection: Processing connection from 212.183.136.195...
12:25:49:348 [7] ThreadProcessConnection: Packet Length is 1037 bytes
12:25:49:348 [7] ThreadProcessConnection: 47 45 54 20 2F 32 30 30 35 30 36 32 33 2F 31 32 GET /20050623/12
12:25:49:348 [7] ThreadProcessConnection: 2F 42 34 43 34 35 45 30 39 2E 4D 4D 53 3F 69 64 /B4C45E09.MMS?id
12:25:49:348 [7] ThreadProcessConnection: 3D 25 32 62 34 34 37 37 37 34 31 31 34 36 32 38 =%2b447774114628
12:25:49:348 [7] ThreadProcessConnection: 20 48 54 54 50 2F 31 2E 31 0D 0A 78 2D 77 61 70 HTTP/1.1 x-wap
12:25:49:348 [7] ThreadProcessConnection: 2D 70 72 6F 66 69 6C 65 3A 20 68 74 74 70 3A 2F -profile: http:/
12:25:49:348 [7] ThreadProcessConnection: 2F 77 61 70 2E 73 6F 6E 79 65 72 69 63 73 73 6F /wap.sonyericsso
12:25:49:348 [7] ThreadProcessConnection: 6E 2E 63 6F 6D 2F 55 41 70 72 6F 66 2F 50 38 30 n.com/UAprof/P80
12:25:49:348 [7] ThreadProcessConnection: 30 52 31 30 31 2E 78 6D 6C 0D 0A 61 63 63 65 70 0R101.xml accep
12:25:49:348 [7] ThreadProcessConnection: 74 3A 20 74 65 78 74 2F 68 74 6D 6C 2C 20 61 70 t: text/html, ap
12:25:49:348 [7] ThreadProcessConnection: 70 6C 69 63 61 74 69 6F 6E 2F 78 68 74 6D 6C 2B plication/xhtml+
12:25:49:348 [7] ThreadProcessConnection: 78 6D 6C 2C 20 61 70 70 6C 69 63 61 74 69 6F 6E xml, application
12:25:49:348 [7] ThreadProcessConnection: 2F 76 6E 64 2E 77 61 70 2E 78 68 74 6D 6C 2B 78 /vnd.wap.xhtml+x
12:25:49:348 [7] ThreadProcessConnection: 6D 6C 2C 20 74 65 78 74 2F 63 73 73 2C 20 74 65 ml, text/css, te
12:25:49:348 [7] ThreadProcessConnection: 78 74 2F 76 6E 64 2E 77 61 70 2E 77 6D 6C 2C 20 xt/vnd.wap.wml,
12:25:49:348 [7] ThreadProcessConnection: 61 70 70 6C 69 63 61 74 69 6F 6E 2F 76 6E 64 2E application/vnd.
12:25:49:348 [7] ThreadProcessConnection: 77 61 70 2E 77 6D 6C 63 2C 20 61 70 70 6C 69 63 wap.wmlc, applic
12:25:49:348 [7] ThreadProcessConnection: 61 74 69 6F 6E 2F 76 6E 64 2E 77 61 70 2E 77 62 ation/vnd.wap.wb
12:25:49:348 [7] ThreadProcessConnection: 78 6D 6C 2C 20 61 70 70 6C 69 63 61 74 69 6F 6E xml, application
12:25:49:348 [7] ThreadProcessConnection: 2F 76 6E 64 2E 77 61 70 2E 77 6D 6C 73 63 72 69 /vnd.wap.wmlscri
12:25:49:348 [7] ThreadProcessConnection: 70 74 63 2C 20 74 65 78 74 2F 78 2D 76 43 61 72 ptc, text/x-vCar
12:25:49:348 [7] ThreadProcessConnection: 64 2C 20 74 65 78 74 2F 78 2D 76 43 61 6C 65 6E d, text/x-vCalen
12:25:49:348 [7] ThreadProcessConnection: 64 61 72 2C 20 69 6D 61 67 65 2F 2A 2C 20 61 70 dar, image/*, ap
12:25:49:348 [7] ThreadProcessConnection: 70 6C 69 63 61 74 69 6F 6E 2F 76 6E 64 2E 77 61 plication/vnd.wa
12:25:49:348 [7] ThreadProcessConnection: 70 2E 6D 6D 73 2D 6D 65 73 73 61 67 65 2C 20 61 p.mms-message, a
12:25:49:348 [7] ThreadProcessConnection: 70 70 6C 69 63 61 74 69 6F 6E 2F 76 6E 64 2E 77 pplication/vnd.w
12:25:49:348 [7] ThreadProcessConnection: 61 70 2E 73 69 63 2C 20 61 70 70 6C 69 63 61 74 ap.sic, applicat
12:25:49:348 [7] ThreadProcessConnection: 69 6F 6E 2F 76 6E 64 2E 77 61 70 2E 73 6C 63 2C ion/vnd.wap.slc,
12:25:49:348 [7] ThreadProcessConnection: 20 61 70 70 6C 69 63 61 74 69 6F 6E 2F 76 6E 64 application/vnd
12:25:49:348 [7] ThreadProcessConnection: 2E 77 61 70 2E 63 6F 63 2C 20 2A 2F 2A 2C 61 70 .wap.coc, */*,ap
12:25:49:348 [7] ThreadProcessConnection: 70 6C 69 63 61 74 69 6F 6E 2F 78 6D 6C 3B 71 3D plication/xml;q=
12:25:49:348 [7] ThreadProcessConnection: 30 2E 31 32 35 2C 74 65 78 74 2F 76 6E 64 2E 77 0.125,text/vnd.w
12:25:49:348 [7] ThreadProcessConnection: 61 70 2E 77 6D 6C 73 63 72 69 70 74 3B 71 3D 30 ap.wmlscript;q=0
12:25:49:348 [7] ThreadProcessConnection: 2E 31 32 35 2C 74 65 78 74 2F 76 6E 64 2E 77 61 .125,text/vnd.wa
12:25:49:348 [7] ThreadProcessConnection: 70 2E 73 69 3B 71 3D 30 2E 31 32 35 2C 74 65 78 p.si;q=0.125,tex
12:25:49:348 [7] ThreadProcessConnection: 74 2F 76 6E 64 2E 77 61 70 2E 73 6C 3B 71 3D 30 t/vnd.wap.sl;q=0
12:25:49:348 [7] ThreadProcessConnection: 2E 31 32 35 2C 74 65 78 74 2F 76 6E 64 2E 77 61 .125,text/vnd.wa
12:25:49:348 [7] ThreadProcessConnection: 70 2E 63 6F 3B 71 3D 30 2E 31 32 35 0D 0A 61 63 p.co;q=0.125 ac
12:25:49:348 [7] ThreadProcessConnection: 63 65 70 74 2D 63 68 61 72 73 65 74 3A 20 75 74 cept-charset: ut
12:25:49:348 [7] ThreadProcessConnection: 66 2D 38 2C 20 75 74 66 2D 31 36 3B 20 71 3D 30 f-8, utf-16; q=0
12:25:49:348 [7] ThreadProcessConnection: 2E 36 2C 20 69 73 6F 2D 38 38 35 39 2D 31 2C 20 .6, iso-8859-1,
12:25:49:348 [7] ThreadProcessConnection: 2A 0D 0A 61 63 63 65 70 74 2D 6C 61 6E 67 75 61 * accept-langua
12:25:49:348 [7] ThreadProcessConnection: 67 65 3A 20 65 6E 0D 0A 63 61 63 68 65 2D 63 6F ge: en cache-co
12:25:49:348 [7] ThreadProcessConnection: 6E 74 72 6F 6C 3A 20 4E 6F 2D 63 61 63 68 65 0D ntrol: No-cache
12:25:49:348 [7] ThreadProcessConnection: 0A 68 6F 73 74 3A 20 31 39 34 2E 31 32 39 2E 32 host: 194.129.2
12:25:49:348 [7] ThreadProcessConnection: 34 38 2E 33 3A 38 30 39 30 0D 0A 75 73 65 72 2D 48.3:8090 user-
12:25:49:348 [7] ThreadProcessConnection: 61 67 65 6E 74 3A 20 53 6F 6E 79 45 72 69 63 73 agent: SonyErics
12:25:49:364 [7] ThreadProcessConnection: 73 6F 6E 50 38 30 30 2F 52 31 30 31 20 50 72 6F sonP800/R101 Pro
12:25:49:364 [7] ThreadProcessConnection: 66 69 6C 65 2F 4D 49 44 50 2D 31 2E 30 20 43 6F file/MIDP-1.0 Co
12:25:49:364 [7] ThreadProcessConnection: 6E 66 69 67 75 72 61 74 69 6F 6E 2F 43 4C 44 43 nfiguration/CLDC
12:25:49:364 [7] ThreadProcessConnection: 2D 31 2E 30 0D 0A 62 65 61 72 65 72 2D 69 6E 64 -1.0 bearer-ind
12:25:49:364 [7] ThreadProcessConnection: 69 63 61 74 69 6F 6E 3A 20 30 0D 0A 78 2D 77 73 ication: 0 x-ws
12:25:49:364 [7] ThreadProcessConnection: 62 2D 6D 73 69 73 64 6E 2D 63 6F 6E 74 65 6E 74 b-msisdn-content
12:25:49:364 [7] ThreadProcessConnection: 2D 66 69 6C 74 65 72 3A 20 34 34 37 37 37 34 31 -filter: 4477741
12:25:49:364 [7] ThreadProcessConnection: 31 34 36 32 38 0D 0A 61 63 63 65 70 74 2D 65 6E 14628 accept-en
12:25:49:364 [7] ThreadProcessConnection: 63 6F 64 69 6E 67 3A 20 64 65 66 6C 61 74 65 2C coding: deflate,
12:25:49:364 [7] ThreadProcessConnection: 20 67 7A 69 70 2C 20 63 6F 6D 70 72 65 73 73 3B gzip, compress;
12:25:49:364 [7] ThreadProcessConnection: 71 3D 30 2E 31 2C 20 69 64 65 6E 74 69 74 79 0D q=0.1, identity
12:25:49:364 [7] ThreadProcessConnection: 0A 56 69 61 3A 20 57 53 50 2F 31 2E 30 20 6D 73 Via: WSP/1.0 ms
12:25:49:364 [7] ThreadProcessConnection: 67 77 73 6C 31 33 20 28 58 4D 47 20 37 32 34 53 gwsl13 (XMG 724S
12:25:49:364 [7] ThreadProcessConnection: 6F 6C 75 74 69 6F 6E 73 20 48 54 47 20 42 43 5F olutions HTG BC_
12:25:49:364 [7] ThreadProcessConnection: 50 43 36 5F 4D 30 5F 42 30 35 37 20 32 30 30 35 PC6_M0_B057 2005
12:25:49:364 [7] ThreadProcessConnection: 30 35 31 38 2E 31 32 35 35 35 39 29 0D 0A 63 6F 0518.125559) co
12:25:49:364 [7] ThreadProcessConnection: 6E 74 65 6E 74 2D 74 79 70 65 3A 20 74 65 78 74 ntent-type: text
12:25:49:364 [7] ThreadProcessConnection: 2F 70 6C 61 69 6E 0D 0A 43 6F 6E 6E 65 63 74 69 /plain Connecti
12:25:49:364 [7] ThreadProcessConnection: 6F 6E 3A 20 63 6C 6F 73 65 0D 0A 0D 0A on: close
12:25:49:364 [7] SendCommand: HTTP/1.0 500 Internal Error
12:25:49:364 [7] SendCommand: Content-Type: text/html
12:25:49:364 [7] SendCommand: Date: Thu, 23 Jun 2005 11:25:49 GMT
12:25:49:364 [7] SendCommand: Expires: Thu, 23 Jun 2005 11:25:49 GMT
12:25:49:364 [7] SendCommand:
12:25:49:364 [7] SendCommand: <HTML><HEAD><TITLE>
12:25:49:364 [7] SendCommand: Unknown Request
12:25:49:364 [7] SendCommand: </TITLE></HEAD><BODY><H1>
12:25:49:364 [7] SendCommand: Unknown request: content type is unknown
12:25:49:364 [7] SendCommand: </H1></BODY></HTML>


Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 4677
Registered: 10-2002
Posted on Wednesday, July 27, 2005 - 09:48 pm:   

Hi Denis,

I apologise that because of work overload on our end, we have not been able to respond to you in a timely manner.

Hopefully you were one of the people who sent a direct e-mail to us regarding this issue, as I gather that Vodafone must have "upgraded" their gateway last month.

You are correct that the Vodafone UK gateway should not be including this particular header on a "GET" request.

But, we should also just ignore it.

There is an update for NowSMS at the following URL:

http://www.nowsms.com/download/latestpatch.zip

... and that update does include a fix for that issue.

-bn
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 4678
Registered: 10-2002
Posted on Wednesday, July 27, 2005 - 09:52 pm:   

Hi Denis,

I apologise that because of work overload on our end, we have not been able to respond to you in a timely manner.

Hopefully you were one of the people who sent a direct e-mail to us regarding this issue, as I gather that Vodafone must have "upgraded" their gateway last month.

You are correct that the Vodafone UK gateway should not be including this particular header on a "GET" request.

But, we should also just ignore it.

There is an update for NowSMS at the following URL:

http://www.nowsms.com/download/latestpatch.zip

... and that update does include a fix for that issue.

-bn