Sample application for A2P3 ##Prerequsites
-
git
-
node 0.8.x or later
-
Facebook account
####Optional
- DotCloud account; or
- Windows Azure account
##Install and Setup
-
git clone git://github.com/dickhardt/sample-node-a2p3.git
-
cd sample-node-a2p3
-
npm install
-
npm run config
-
Register if need be at setup.a2p3.net and create a CLI Agent and save the device parameter
-
Edit config.json and insert the
device
parameter -
npm run register
to create the vault.json file (if you change the App ID, you need to rerun this command) -
npm start
will start the server locally
##DotCloud Deployment
-
Register at DotCloud for a free account and install the dotcloud CLI
-
dotcloud create sample
answer yes to link -
dotcloud push
will deploy to dotcloud and show you the URL it is running at
####config.json and vault.json See node-a2p3 for details
##Windows Azure Deployment
-
Register at Windows Azure and build and deploy a Node.js web site if you have not done it before.
-
Create a new website and set up deployment to use a local git repository. Remember your username, password and copy the resulting git repo that is hosted at Azure.
-
git remote add azure <git repo at azure>
will add a git remote to your local copy of the Sample App -
Add the generated vault.json and config.json files to the repo so that they will be deployed to Azure.
git add -f vault.json git add -f config.json
-
git commit -m "adding in vault.json and config.js"
to commit new files to local repo -
git push azure master
will push the code to Azure. You will need to enter your credentials you created in (2)
##How it Works
TBD
##Related
A2P3_specs Specifications and POC documentation
A2P3 POC Server implementation source (node.js)
A2P3_agent POC mobile agent (PhoneGap)
A2P3_bank POC mobile bank app (PhoneGap)
node-a2p3 node.js npm module for A2P3 applications
rs-sample-node-a2p3 sample A2P3 resource server using node-a2p3
MIT License
Copyright (c) 2013 Province of British Columbia
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.