Coder Social home page Coder Social logo

open-template-hub / sms-server-template Goto Github PK

View Code? Open in Web Editor NEW
9.0 2.0 1.0 95 KB

SMS Server Template is a generic open-source sms server that has a simple yet powerful design to connect your business with third-party sms service providers (like Twilio, Amazon SNS).

Home Page: https://opentemplatehub.com/en-US/product/server/sms-server-template

License: MIT License

TypeScript 96.49% Shell 3.51%
sms sms-api sms-gateway sms-client sms-messages sms-notifications sms-sdk

sms-server-template's Introduction

Logo

Open Template Hub - SMS Server Template v5

License Issues PRCLosed LastCommit Release SonarCloud

SMS Server Template is a generic open-source sms server that has a simple yet powerful design to connect your business with third-party sms service providers (like Twilio, Amazon SNS).

Ways to Begin

1. Express Deploy

Deploy this template to Heroku

Deploy

2. Start with Server Generator

Create your server with Server Generator Package

NPM

3. GitHub Template

Use this repository as a Template

GitHubTemplate

Installations

Install nodejs and npm via nodejs.org.

Check installed versions of nodejs and npm via running following commands:

node -v
npm -v

Check project's current nodejs and npm version from package.json.

Environment Variables

If you don't give RESPONSE_ENCRYPTION_SECRET, response encryption mechanism will be disabled automatically.

PORT=4007

PROJECT=OTH
MODULE=SmsServer
ENVIRONMENT=Local

MONGODB_URI={Database Connection Url}
MONGODB_CONNECTION_LIMIT={MongoDB Connection Limit}
        
CLOUDAMQP_APIKEY={MQ Api Key}
CLOUDAMQP_URL={MQ Connection Url}

SMS_SERVER_QUEUE_CHANNEL=oth_sms_queue
ORCHESTRATION_SERVER_QUEUE_CHANNEL=oth_orchestration_queue

REDISCLOUD_URL={Redis Connection Url}
REDIS_CONNECTION_LIMIT={Redis Connection Limit}

ACCESS_TOKEN_SECRET={Access Token Secret}
RESPONSE_ENCRYPTION_SECRET={Response Encryption Secret}

DEFAULT_LANGUAGE={Language Code}

Example Preconfigured Message:

{
   "key": "2FACodeSend", 
   "messages": [
   {
      "language": "en", 
      "message": "Hello ${username}, here is your 2FA code ${twoFactorCode}"
   }
   ],
   "payload": {
      "twilio": {
         "from": "{Your Twillio Phone Number}"
         }
      }
   }

Service Provider Configurations

1. Twillio

   {
      "key": "TWILIO",
      "description": "Twilio SMS Provider",
      "payload": {
         "accountId": "{Your Twillio Account Id}",
         "authToken": "{Your Twillio Account Token}",
         "serviceId": "{Your Twillio Service Id}",
         "from": "{Your Twillio Phone Number}"
      }
   }

Http Requests

You can find list of available http request in the requests directory. You can run http requests directly via WebStorm, for more information check out: jetbrains.com/help/idea/http-client-in-product-code-editor.html

Contributors


Furkan Yavuz

πŸ’¬ πŸ“– πŸ‘€

Fatih Turker

πŸ’¬ πŸ“– πŸ‘€

Mert Sarac

πŸ’¬ πŸ“– πŸ‘€

Contributing

Refer to CONTRIBUTING.md to see how to contribute to Open Template Hub.


Code of Conduct

Refer to CODE_OF_CONDUCT.md to see contributor covenant code of conduct.


LICENSE

The source code for this project is released under the MIT License.

sms-server-template's People

Contributors

fatihturker avatar furknyavuz avatar mertlsarac avatar oth-service-user avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

smshardy

sms-server-template's Issues

2022 Week 1

Logo

Open Template Hub - Feature Request

Description

Code Cleanup and fix TODOs.

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

2022 Week 5

Logo

Open Template Hub - Feature Request

Description

sms server update readme with configs

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

Week 1

Logo

Open Template Hub - Feature Request

Description

Code Cleanup and fix TODOs.

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

2022 Week 4

Logo

Open Template Hub - Feature Request

Description

  1. return 500 if β€œfrom” is not set
  2. update readme files
  3. set language code from env or default "en"

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

2022 Week 3

Logo

Open Template Hub - Feature Request

Description

use product table payload logic for preconfigured sms
payload: {
"twilio": {
"from": "1132123123123"
}
}
use _ for table naming

sms server preconfigured language code, message
messages: [
{
language: "en",
message: "Hi ${username}...."
},
{
language:"fr",
message....
}
]

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

Week 52

Logo

Open Template Hub - Feature Request

Description

Investigate SMS Service field missing

preconfigured messages & from

key="2FACodeSend"
languageCode=en
message="Hello {{username}}, here your 2FA code {{twoFactorCode}}"
from="+1141412412"
providerKey="Twilio"

key="HappyBirthdayMessage"
languageCode=en
message="Hello {{username}}, happy birthday. We enjoyed with you from {{years}}"
from="+1341412412"
providerKey="Twilio"

{
key="2FACodeSend",
languageCode=en,
to=""
payload = {
username:fatih
twoFactorCode:4225225
}
}

Supplementary Info

Links, images, screenshots etc.

othOpen Template Hub Β© 2021

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.