Skip to content

Ducktatorrr/simple-webhook-listener

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Webhook Listener

As the repository title says, a simple webhook listener with Svelte app frontend to view the contents of the sent requests. Handy for debugging, previewing, or collecting data you're POSTing.

alt text

About

I created this project as an exercise to explore Svelte and for personal use to avoid relying on online services for inspecting POST request data. Contributions are always welcome!

Please note: the requests are stored in an array at the app level. If you refresh the page or restart the app the data will reset. Contemplating to move this over to the server side eventually but I don't really want this to be a permanent data store service.

Setup

Cloning & Installing

To set up this project, clone the repository and run the following commands:

git clone https://github.com/Ducktatorrr/simple-webhook-listener.git
cd simple-webhook-listener
npm install

Seting up environment variable

In /api and /app there are .env.example files. Make a copy of these files and rename them .env Here you will note where your API and Svelte App would be running. The default values in the example are already correctly set for you to run the start command for local usage.

Rock & Rolling (locally)

To then run the API + Svelte App locally run the follow command:

npm start

Both the API server and Svelte App should will start up.

Now open the Svelte App by visiting http://localhost:8080/ in your browser.

To make sure everything works make a test POST request to the API:

curl -X POST -H "Content-Type: application/json" -d '{"Ayo": "World"}' http://localhost:3000

License

This project is licensed under the MIT License - see the LICENSE file for details.

                       _        ______          _
     /\               | |      |  ____|        | |
    /  \   _ __  _ __ | | ___  | |__ _   _  ___| | _____ _ __ ___
   / /\ \ | '_ \| '_ \| |/ _ \ |  __| | | |/ __| |/ / _ \ '__/ __|
  / ____ \| |_) | |_) | |  __/ | |  | |_| | (__|   <  __/ |  \__ \
 /_/    \_\ .__/| .__/|_|\___| |_|   \__,_|\___|_|\_\___|_|  |___/
          | |   | |
          |_|   |_|

About

No description, website, or topics provided.

Resources

License

Stars

0 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors