Giter Site home page Giter Site logo

thr0m3l / eventfly-microservices Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eventfly/microservices

0.0 0.0 0.0 3.53 MB

Forked from our CSE 408 software project.

Shell 0.38% JavaScript 44.88% Python 3.10% TypeScript 47.09% CSS 3.75% HTML 0.36% Dockerfile 0.24% SCSS 0.20%

eventfly-microservices's Introduction

Microservices Monorepo

Installation

  1. Download and install Docker/Docket Desktop
  2. Clone the repo git clone github.com/eventfly/Microservices.git
  3. Run cd Microservices
  4. Run docker compose build
  5. After build, run docker compose up

Docker PORT Mapping

3000 - Auth Service
3001 - Org Service
3002 - Events Service
3003 - Newsfeed Service
3004 - Participant Service
3005 - Payment Service

API Endpoints

AUTH Service

/api/auth/
         /users/currentuser    GET
         /users/signin         POST
         /org/signin           POST
         /org/currentuser      GET

Event Service

/api/event/
          /:id                  GET
          /:id                  PUT
          /:id/role             POST
          /:id/role             DELETE
          /:id/assign-staff     PUT
          /:id/remove-staff     POST
          /staff/:eventId       GET
          /all                  GET
          /:id/feedbacks        GET
          

ORG Service

/api/org/
        /:staffId             GET
        /:id/profile          GET

PARTICIPANT Service

/api/participant/:userId/tickets        GET
/api/participant/order                  POST
/api/participant                        POST
/api/participant/:id/tickets            GET
/api/participant/checkin                PUT
/api/participant/:id/events             GET
/api/participant/:id/edit               PUT
/api/participant/:id/profile            GET
/api/participant/search?query=          GET
/api/participant/event/:id              GET (Get event profile)
/api/participant/:id/orders             GET (Get all orders under a participant)
/api/participant/order/:id              GET (Get order info by order_id)
/api/participant/feedback               POST
/api/participant/event/:id/feedbacks    GET
/api/participant/event/:id/statistics   GET (Get statistics of an event)
/api/participant                        DELETE
/api/participant/:id/feedbacks          GET (Get all feedbacks of a participant)
/api/participant/event/:id/status       GET (Get a boolean indicating whether the user is registered)

NEWSFEED Service

/api/newsfeed/:eventId/post             POST (Add Post)
/api/newsfeed/post/:postId/comment      POST (Add Comment)
/api/newsfeed/:eventId/post             GET  (Get all posts under an event)
/api/newsfeed/post/:postId/comment      GET  (Get all comments under a post)
/api/newsfeed/feed?start=0&count=5      GET  (Get newsfeed)
/api/newsfeed/post/:postId              GET  (Get post data)
/api/newsfeed/:id/events                GET  (Get all events of an user)
/api/newsfeed/edit-like                 PUT  (Like/Unlike a post)
/api/newsfeed/post/:id/answer           PUT  (Answer a quiz/ Vote on a poll)
/api/newsfeed/post/:id                  DELETE (Delete a post)
/api/newsfeed/post/:id/activity         GET (Get a activity by post_id)
/api/newsfeed/post/:id/activity/all     GET (Get all activities under a post sorted by quiz_score)

PAYMENT Service

/api/payment/participant                POST
/api/payment/org                        POST

ANALYTICS Service (port 3006. Run it separately.)

Recommendation with location

/api/analytics/events                   POST
request payload:
{
    "participantId": "630a3262044e45a64cb73e17",
    "participantLng": 90.4331, #participantLng means participant's location's lng
    "participantLat": 23.7619  #participantLat means participant's location's lat
},

response:{
    "events": [
        "6308f258b31c4f5574fd7c75",
        "63078e4c93391fe597df659e",
        "6307909693391fe597df65ad",
    ]
}

Recommendation without location

/api/analytics/events/no-loc            POST
request payload:
{
    "participantId": "630a3262044e45a64cb73e17"
},

response:{
    "events": [
        "6308f258b31c4f5574fd7c75",
        "63078e4c93391fe597df659e",
        "6307909693391fe597df65ad",
    ]
}

Search by Location

/api/analytics/search/location              POST

request payload:
{
    "participantId": "630a3262044e45a64cb73e17",
    "participantLng": 90.4331, #participantLng means participant provided lng (not participant's location's lng) 
    "participantLat": 23.7619  #participantLat means participant provided lat (not participant's location's lat)
},

response:{
    "events": [
        "6308f258b31c4f5574fd7c75",
        "63078e4c93391fe597df659e"
    ]
}

Search by Query

/api/analytics/search/query                 POST

request payload:
{
    "query": "contest concert"
},

response:{
    "events": [
        "6308f258b31c4f5574fd7c75",
        "63078e4c93391fe597df659e"
    ]
}

eventfly-microservices's People

Contributors

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