Giter VIP home page Giter VIP logo

mobile-n10n's Introduction

mobile-n10n

mobile-n10n or "mobile-notification" is our next generation of push-notification services. This project will focus on connecting directly to cloud providers (Azure, GCM) and act as an interface to it.

Modules

  • registration: Handles the registration requests received from the device, and redirect them to the correct provider
  • notification: Handler notification messages and redirects them to correct provider
  • report: TODO
  • backup: TODO
  • common: The common stuff

Registration

The Play configuration file must contain:

gu.msnotifications.endpointUri=https://servicebus-ns.servicebus.windows.net
gu.msnotifications.hubname=nameOfNotficationHub
gu.msnotifications.sharedKeyName=nameOfSharedKey
gu.msnotifications.sharedKeyValue=sharedKeyActualValue

notifications.auditor.content-notifications=http://content-notification-auditor.elb.amazonaws.com
notifications.auditor.goal-alerts=http://goal-alert-auditor.elb.amazonaws.com

Device registration create or udpate

Requires a deviceId, used for updating topics or device ids.

Returns an updated or created registration. 'topics' array is validated against auditor agents ie. it may contain less elements than in original registration.

PUT /registrations/deviceId
Content-Type: application/json

{
  "deviceId": "wnsChannelIdOrProviderSpecificDeviceIdentifier",
  "platform": "windows-mobile",
  "userId": "abcd",
  "topics": [
    {"type": "stuff", "name": "stuff"},
    {"type": "other-stuff", "name": "stuff"}
  ]
}

returns

{
  "deviceId":"deviceAA",
  "platform":"windows-mobile",
  "userId":"idOfUser",
  "topics": [
      {"type":"football-match","name":"match-in-response"}
  ]
}

Or an error code if a failure with body string being the reason

Send push notifications

POST /push/?api-key=api-key
Content-type: application/json

{
    "wnsType": "wns/toast",
    "xml": "<xml...>",
    "topics": [
        {"type": "stuff", "name": "stuff"}
    ]
}

Returns no relevant content - could return an error code however.

The topics are matched with AND - this can be easily changed however. Or we could restrict it all to just one topic.

As this is an external API it does need hardening - ie input data needs to be validated.

mobile-n10n's People

Contributors

davidfurey avatar alexduf avatar agulowaty avatar nathanielbennett avatar scalawilliam avatar pvighi avatar kant avatar diegovazqueznanini avatar lmath avatar hoyla avatar

Watchers

James Cloos avatar Jon Tseng 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.