fxa/packages/fxa-basket-proxy
Shane Tomlinson 23849da5d8 Release v1.134.0 2019-04-02 15:02:45 +01:00
..
.circleci feat(ci): update to circle 2 mozilla/fxa-basket-proxy#61); r=rfk 2018-07-24 03:05:26 -07:00
bin feat(fake-server): Have the fake server serve CORS requests, handle OAuth tokens. 2019-03-19 11:29:37 +00:00
config
grunttasks fix(deps): drop nodemon, update mozlog 2018-11-26 15:04:50 -05:00
lib feat(fake-server): Have the fake server serve CORS requests, handle OAuth tokens. 2019-03-19 11:29:37 +00:00
scripts
test chore(api): More tests and cleanups for basket API compatibility. mozilla/fxa-basket-proxy#57); r=stomlinson 2018-04-23 12:54:59 +10:00
.eslintrc
.gitignore
.nsprc fix(deps): add filtered npm audit 2018-10-22 17:25:29 -04:00
.travis.yml fix(deps): add filtered npm audit 2018-10-22 17:25:29 -04:00
AUTHORS
CHANGELOG.md Release v1.134.0 2019-04-02 15:02:45 +01:00
CONTRIBUTING.md
Dockerfile-build fix(docker): base image node:8-alpine and upgrade to npm6 mozilla/fxa-basket-proxy#59) r=@vladikoff 2018-06-13 17:49:19 -07:00
Dockerfile-test
Gruntfile.js
LICENSE
README.md
npm-shrinkwrap.json Release v1.134.0 2019-04-02 15:02:45 +01:00
package.json Release v1.134.0 2019-04-02 15:02:45 +01:00

README.md

Firefox Accounts Basket Proxy

Build Status: Travis

This server acts as an intermediary between Firefox Accounts and Basket, Mozilla's email newsletter subscription system. It allows FxA-OAuth-authenticated access to the Basket API and is responsible for some background data-syncing tasks.

Over time, we expect most of the functionality of this proxy to be absorbed into Basket itself; running it as a separate system in the meantime gives us the ability to iterate quickly and minimise coupling between the two systems.

To run the proxy:

node ./bin/basket-proxy-server.js

To process account-related events from SQS:

node ./bin/basket-event-handler.js

For testing and development purposes, there's a minimal 'fake' implementation of the Basket server API that stores its state in memory. Run it like so, and the proxy will use it unless configured with the URL of a live Basket server:

node ./bin/fake-basket-server.js

Prerequisites

  • node 6
  • npm
  • Grunt

Grunt is used to run common tasks to build, test, and run local servers.

TASK DESCRIPTION
grunt lint run ESLint and JSCS (code style checker) on the code.
grunt server run a local server running on port 1114.
grunt test run local tests.
grunt version stamp a new minor version. Updates the version number and creates a new CHANGELOG.md.
grunt version:patch stamp a new patch version. Updates the version number and creates a new CHANGELOG.md.

License

MPL 2.0