Code Monkey home page Code Monkey logo

invitation_manager's Introduction

Project Setup

Please read all the instructions carefully and follow step by step.

Prerequisites:

You will need the following programs properly installed on your system.

Installation and Running :

git clone https://github.com/ongraphpythondev/invitation_manager.git

cd invitation_manager

Note:-

Open settings.py in the project directory and update database settings and email settings.

EMAIL_HOST_USER = "your_email"

EMAIL_HOST_PASSWORD = "your_password"

# Install required packages for the project to run
pip install -r requirements.txt

python manage.py migrate

python manage.py runserver

# Run Celery worker to work in the background
celery -A invitation_manager worker -l info

API Endpoints:-

  1. URL: http://127.0.0.1:8000/api/invitations/

    METHOD: GET
    HEADER: Authorization Token <token>
    Response:
    data:[
      {
           'id': <str>, 
           'createdTime': <str iso 8601 format>,
           'seconds': <int> The time since the invitation has been created in seconds
           'email': <str>,
           'used': <bool>
           'creatorEmail': <str>, 
           'creatorFullname': <str> Example: John Oliver,
       },
           ...
      ]
    
    
    METHOD: POST
    HEADER: Authorization Token <token>
     Body:
           {
             "email": "[email protected]"
            }
    Response:
          {
           'id': <str>, 
           'createdTime': <str iso 8601 format>,
           'seconds': <int> The time since the invitation has been created in seconds
           'email': <str>,
           'used': <bool>
           'creatorEmail': <str>, 
           'creatorFullname': <str> Example: John Oliver,
       }
    
  2. URL: http://127.0.0.1:8000/api/invitations/{id}

     METHOD: PATCH
     HEADER: Authorization Token <token>
     Request Body:
       {
         "email": "[email protected]",
         "used": true/false
        }
     
     Response:
     <id>
     
    
     METHOD: DELETE
     HEADER: Authorization Token <token>
     Response:
     <id>
    

invitation_manager's People

Contributors

ongraphpythondev avatar

Watchers

 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.