Skip to content

mattriley/node-kris-kringle

Repository files navigation

Kris Kringle

161 sloc 18 files 4 deps 9 dev deps

Christmas gift-giving made easy by randomising a draw and notifying players of their KK by SMS text message.


Table of Contents

Install

npm install kris-kringle

SMS notifications are sent using AWS SNS and requires an AWS profile to be configured.

Usage

kk <configJsonFile>

configJsonFile defaults to config.json.

Example

{
    "dryRun": true,
    "template": "Hey {name}! Your KK is {kk}. The spend is ${spend}. Merry Christmas! 🎅🏻🎄",
    "spend": 100,
    "players": [
        {
            "name": "foo",
            "number": "+6111111111"
        },
        {
            "name": "bar",
            "number": "+6122222222"
        },
        {
            "name": "baz",
            "number": "+6133333333"
        }
    ]
}

Text messages:

  • Hey foo! Your KK is baz. The spend is $100. Merry Christmas! 🎅🏻🎄
  • Hey bar! Your KK is foo. The spend is $100. Merry Christmas! 🎅🏻🎄
  • Hey baz! Your KK is bar. The spend is $100. Merry Christmas! 🎅🏻🎄

See src/default-config.json for other config options.

Architecture

Can't see the diagram? View it on GitHub

graph TD;
    effects-->io;
    commands-->effects;
    commands-->lib;

This diagram was generated with Module Composer


About

Christmas gift-giving made easy by randomising a draw and notifying players of their KK by SMS text message.

Topics

Resources

Stars

Watchers

Forks