amartya-dev / notes_app

A notes app created as a demo using DRF

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Description

The present application is a simple Django Rest Framework Backend for a notes application where there are the following functionalities.
To check the data stored in the database:
After you create the superuser and have run all migrations, you can check all the values stores by visiting http://localhost:8000/admin and logging in by the username and password given during superuser creation.

Functionalities

{
  "username": "string",
  "password": "string"
}

Response (on success):

{
  "status": "account created"
}

Response (on failure):

{
  "details": "<some error>"
}
{
  "note": "string",
  "user_id": int
}

Response (on success):

{
  "status": "success"
}

Response (on success):

[
    {
        "user": "<username>",
        "note": "<note>"
    },
    {
        "user": "<username>",
        "note": "<note>"
    }
]
{
  "username": "string",
  "password": "string"
}

Response (on success):

{
  "status": "success",
  "userId": int
}

Response (on failure):

{
  "status": "access denied"
}

Steps to run

  • Clone the repository
  • Make the MYSQL database according to details in the settings.py file under the following:
# Connect to the Mysql DB
DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'notes',
        'USER': 'notes_user',
        'PASSWORD': 'aahtheo@123',
        'HOST': 'localhost',
        'PORT': '3306',
    }
}
  • Run: pip install -r requirements.txt
  • Run: python manage.py migrate
  • Create super user: python manage.py createsuperuser

ToDo

  • Correct the documentation by customizing for each view

About

A notes app created as a demo using DRF


Languages

Language:Python 100.0%