Giter Club home page Giter Club logo

technote-nodejs-and-pusherjs's Introduction

Technote demonstrating a Pusher.JS-based app that subscribes to remote events, such as events generated from another Pusher-based app

This technote is intended for developers interested in learning more about the Pusher's API. This is not a complete tutorial. Instead, you will be guided straightforwardly to a simple application with two NodeJS-based scripts: One for authentication purposes and other for the subscription function.

Get your app credentials (from https://dashboard.pusher.com)

You will need to visit Pusher.com web service to get your app credentials. Once you get the data, make sure you edit the config-sample.json and rename it to config.json:

{
  "APP_ID"       : "REPLACE_APP_ID",
  "APP_KEY"      : "REPLACE_APP_KEY",
  "SECRET"       : "REPLACE_APP_SECRET",
  "authEndpoint" : "REPLACE_YOUR_URL:5000/pusher/auth",
  "cluster"      : "REPLACE_CLUSTER_NAME"
}

Architecture requirements and initial installation

  • "test_auth.js" β€”Β is the authentication system. This JavaScript application will be called from Pusher.com service. This application uses an NPM package named "Pusher" and it exposes the "/pusher/auth" end-point.

  • Sample "test.js" will use the NPM package named "Pusher-JS" and will mainly attempt to subscribe to a private channel named "private-channel".

technote-nodejs-and-pusherjs's People

Contributors

meuusuario avatar taboca avatar

Stargazers

 avatar

Watchers

 avatar  avatar  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.