Announcement

Collapse
No announcement yet.

SMS using SocketTools

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • SMS using SocketTools

    The CTextMessage class provides methods that can be used to determine the provider associated with a specific telephone number
    1. Is anyone successfully sending SMS to any SMS enabled phone without knowing the phone provider using PowerBASIC and SocketTools?
    2. Can it be done without paying Twillio or other third-party server provider?
    If so, is anything else needed like a security certificate on another machine if you want to send SMS messages from any machine?
    3. Is this a newer feature in SocketTools 10?

    TextMessage
    Demonstrates how to send a text message through a service provider SMTP gateway.

  • #2
    I’ve only used SocketTools to send my own phone a test text. So the service provider was known...

    Are you a DYIer? Adafruit FONA (https://www.adafruit.com/product/3147) provides a GSM modem link... I’m guessing someone/somewhere has a turnkey solution that will allow the same.

    Just fyi about something I worked on and was able to get working. This could be linked to PB via serial port. I’ve sent/received text but I didn’t ever test MMS. Obviously there will be the cost of the hardware as well as the cost of a monthly cell phone bill.

    Comment


    • #3
      Michael,
      Can you send to yourself or others using CTextMessage which is supposed to be able to look-up the provider?

      Comment


      • #4
        Hey Mike,

        I have SocketTools 9.3 and I don't see "CTextMessage" defined, so I'm assuming that is something newer than what I have. I think when I tested it I used "SmsSendMessage", but that was a year or two ago and I don't remember the details exactly. Sorry I'm not able to help you with "CTextMessage".

        Comment


        • #5
          Code:
           Thanks,  I have a much older version than that!
           Testing indentation and tags.  Either I changed something or tags are not working.
           My slPushDatabase / slPopDatabase demo got trashed.   The slcopydatabase function can be found in  src\sqlitening.bas.
           I will go back and try to fix the post.
           Sounds like it is time to repurchase SocketTools.
          This is bold and working.

          Off-topic: There appears to be an issue in the databases/database programming forum using code tags, etc.

          Comment


          • #6
            I've had some issues posting things here as well. I even verified that I was following the temporary guidelines and I still couldn't get it...finally I just gave up.

            I'd check with SocketTools dev to make sure the current version does what you want. SocketTools is a GREAT communications lib. But for SMS I'd verify with them that it was going to do what I wanted...

            Comment


            • #7
              Thanks!
              Does anyone using the current 10 series of SocketTools (with CTextMessage) have it working sending texts with the found provider?

              Comment


              • #8
                Mike,
                I'm not seeing that function listed in their online documentation.

                Click image for larger version

Name:	Doc.png
Views:	146
Size:	2.4 KB
ID:	797637

                Maybe download the free trial version and try it?

                Comment


                • #9
                  The actual HTML help file is a bit strange in its naming. The functions you listed above are listed as e.g. CTextMessage::GetFirstProvider even in the 7.2 version. It's basically right where you listed those:
                  Code:
                  - Text Messaging
                    - Functions
                      - CTextMessage::CTextMessage
                      - CTextMessage::GetFirstProvider etc.

                  Comment


                  • #10
                    CTextMessage is not something you'd be using in PowerBASIC. The APIs you'd use are the SmsInitialize, SmsSendMessage, etc. The class section of the technical reference is not going to be useful to you unless you're using Visual C++ (or another Windows C++ compiler).

                    By the way, if you look in the SocketTools Examples folder under your Documents, you'll find a PowerBASIC example called "TextMessage" which uses the API.
                    Mike Stefanik
                    sockettools.com

                    Comment


                    • #11
                      Mike,
                      Can an Sms provider be obtained using the functions available to PowerBASIC without having to pay some third-party provider to get the carrier of the phone?

                      Comment


                      • #12
                        One final thing, because this API uses an SMTP gateway to deliver text message, if you don't know the provider you can ask the API to "guess" based on the phone number. This can work, as long as the number has not been redirected to another provider (i.e.: number portability). If it has been, it's up to the original provider as to whether or not they will forward the message or not, and most will not. In that case, you'll either need to explicitly identify the current provider, or use a paid service like Twilio.
                        Mike Stefanik
                        sockettools.com

                        Comment


                        • #13
                          Thank you!

                          Comment


                          • #14
                            Originally posted by Mike Doty View Post
                            Mike,
                            Can an Sms provider be obtained using the functions available to PowerBASIC without having to pay some third-party provider to get the carrier of the phone?
                            We have our own internal API that maps a phone number to a service provider, and it's free for you to use (there's no additional charge) but that does not include portability number information. So if you have a phone number that was originally allocated by Verizon, and then that person moved over to AT&T and kept the same phone number, our API is going to think it's still a Verizon phone number and attempt to use their SMS gateway.
                            Mike Stefanik
                            sockettools.com

                            Comment


                            • #15
                              All morning I couldn’t remember why I hadn’t used SocketTools for my SMS needs. FINALLY I remembered...it was because I needed to also receive text messages. Basically send a text confirming an appointment and receive text back yes/no...

                              Twillio certainly has an extensive list of customer interaction products/tools. That’s the first I’d read up on them...very impressive. I didn’t do any digging to see pricing, but it sure looks like they can cater to about every type of electronic customer contact you would likely need.

                              Comment

                              Working...
                              X