Giter Site home page Giter Site logo

john677 / node-http-post-listener Goto Github PK

View Code? Open in Web Editor NEW

This project forked from deardooley/node-http-post-listener

0.0 2.0 0.0 140 KB

A simple http server that listens for POST events on port 9000 and prints the contents to the console. Don't use this in production. It is not production grade or useful for anything except easily inspecting web hooks.

License: GNU General Public License v2.0

JavaScript 100.00%

node-http-post-listener's Introduction

Node.js HTTP Listener

A simple http server that listens for POST events on port 9000 and prints the contents to the console. Don't use this in production. It is not production grade or useful for anything except easily inspecting web hooks.

This was largely derived from a gist by Kyle Tolle.

Installation

You can run this about anywhere you have node installed and a publicly accessible IP address. If you use the default port, your machine will need to make that port available through its firewall.

Requirements

The only requirement to run this server is node.js and npm. Install node.js and npm via whatever install process is available.

http://nodejs.org/download/

Project setup

Check out the project and cd into the project directory. Run the server directly using the node command.

git clone https://bitbucket.org/taccaci/node-http-post-listener.git
cd node-http-post-listener

Usage

Running the server

To start a node server on localhost:9000, run the following command from within the project directory.

node node-http-post-listener.js

You can test that the server is receiving requests by running the following curl statement in another tab.

curl -XPOST -d "foo=bar" http://localhost:9000/listener?alpha=beta

Stopping the server

To stop the server, type CTRL+C in the windows you started the server

node-http-post-listener's People

Contributors

deardooley avatar

Watchers

 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.