Code Monkey home page Code Monkey logo

smsgw.js's Introduction

This project is not in development and considered to be unstable for production.

smsgw.js is an SMS gateway which allows applications to send and receive SMS messages with a set of HTTP API. The project is only tested with Huawei E3372s but generally should work with modems that support GSM AT commands with serial interface.

Known issues

  • The serial port locks up after a period of usage.

API

Send messages

Send a GET request to / with queries listed below.

Example: /?action=send&device=E3372_1&to=85261234567&message=test

Name Value
action send
device Name of the GSM modem in config.js.
to Recipient's phone number.
message Content of the SMS message.

Retrieve status of modems

Send a GET request to / with queries listed below.

Example: /?action=status&device=E3372_1

Name Value
action status
device Name of the GSM modem in config.js. (optional)

Reset a modem

Send a GET request to / with queries listed below.

Example: /?action=reset&device=E3372_1

Name Value
action reset
device Name of the GSM modem in config.js.

Send USSD codes

Send a GET request to / with queries listed below.

Example: /?action=ussd&device=E3372_1&command=*#1234#

Name Value
action ussd
device Name of the GSM modem in config.js.
command The USSD code you could like to send.

Get unread messages

Send a GET request to / with queries listed below.

Example: /?action=readall&device=E3372_1

Name Value
action readall
device Name of the GSM modem in config.js.

Callback for incoming messages

Set the callback URL in config.js.

It should expect a POST request with the following form data.

Name Value
device Modem that received this message.
iccid ICCID of the SIM card inside this modem.
sender Sender of this message.
message Content of the SMS message.

smsgw.js's People

Contributors

slyh2 avatar slyh avatar

Stargazers

Alexander Waller avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.