Skip to content
/ chirpy Public

Web server that mimics a popular short-form-messaging platform backend with CRUD operations and security features

Notifications You must be signed in to change notification settings

CMaxK/chirpy

Repository files navigation

chirpy

Web server that mimics a popular short-form-messaging platform backend with:

  • CRUD operations for messages
  • User auth with JWT
  • Refresh tokens as extra security layer on top of of JWT
  • User login/logout and relevant access permissions
  • JSON object to mimic document store for messages and users

To run:

go build -o out && ./out

On re-run:

Either manually delete the previously created database.json file or run: go build -o out && ./out --debug

Testing Endpoints:

1. User creation, login, auth, chirp posting, get chirps:

Creation: image Login: image Post chirp using auth token: image image image Get Chrips: image

2. Chirps Delete:

image

4. Webhook for premium members:

Creation: image Upgrade using API Key: image image Premium feature (is_chirpy_red) activated: image

Further features such as:

  • not allowing duplicate user creation
  • Only user can delete their own tweets
  • Admin panel with auto-increment visitor count
  • Admin revocation of user access
  • API health-check endpoint
  • Reading chirps by chirp_id
  • If a user should not be allowed to perform a certain task...they won't be able to without correct auth tokens etc.

About

Web server that mimics a popular short-form-messaging platform backend with CRUD operations and security features

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published