Skip to content

πŸ”’πŸŒ 'Authorization Alif' - A Django-based app for secure user auth, email confirmation, and news management using Django & REST framework. Empowering seamless user experiences and efficient news handling.

License

EMMMABK/alif

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

39 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Alif Project πŸ’»πŸš€

News

Table of Contents

  1. Overview
  2. Project Setup
  3. API Endpoints
  4. Models and Serializers
  5. Views
  6. Routes
  7. Documentation

1. Overview ℹ️

The "Authorization Alif" project is a Django application designed for user authentication, user management, email confirmation, password management, and news management using Django and Django REST framework.

2. Project Setup πŸ› οΈ

Requirements ℹ️

Before you begin, ensure you have the following installed on your system:

  • Python
  • Django
  • Python packages listed in requirements.txt

Installation βš™οΈ

  1. Clone this repository to your local machine:
    git clone https://github.com/EMMMABK/authorization-alif.git
  2. Navigation 🚢
    cd authorization-alif
  3. Install the required packages πŸ“¦
    pip install -r requirements.txt

3. Database Setup πŸ—ƒοΈ

By default, this project uses SQLite as the database. You can change the database settings in settings.py.

  • Apply database migrations:
python manage.py migrate
  • Create a superuser for admin access:
python manage.py createsuperuser
  • Start the development server:
python manage.py runserver

4. API Endpoints 🌐

The project provides the following API endpoints:

  • User Authentication and Management
    • POST /api/login/: User login.
    • POST /api/register/: User registration.
    • POST /api/email-confirmation/: Email confirmation.
    • POST /api/password-change/: Password change.
    • POST /api/password-reset/: Password reset.
    • PUT /api/user/update/int:pk/: Update user profile.
    • GET /api/users/: Get a list of users.
    • GET /api/user/int:pk/: Get user details.
  • News Management
    • GET /api/news/: Get a list of news.
    • POST /api/news/create/: Create news.
    • GET /api/news/int:pk/: Get news details.
    • PUT /api/news/int:pk/: Update news.
    • DELETE /api/news/int:pk/: Delete news.

5. Models and Serializers πŸ“‹

User Model πŸ‘€

  • The User model represents a user in the application.
  • Fields include: email, name, surname, phone_number, is_active, is_staff, password, and more.
  • Serializers: UserSerializer, UserRegistrationSerializer, EmailConfirmationSerializer, PasswordChangeSerializer, PasswordResetSerializer, UserUpdateSerializer, UserFilterSerializer.

News Model πŸ“°

  • The News model represents a news article.
  • Fields include: image, title, content, and created_at.
  • Serializers: NewsSerializer, NewsCreateSerializer.

6. Views πŸ‘€

Views in this project handle the logic for API endpoints. Important views include user authentication, registration, email confirmation, password management, and news management.

7. Routes πŸ›£οΈ

URL routes are defined in urls.py. They map views to specific endpoints and HTTP methods.

8. Documentation πŸ“„

For detailed API documentation, see the official Django REST framework documentation. You can also refer to the comments within the code for more information on each API endpoint's usage.

Please note: It's important to keep your SECRET_KEY and other sensitive information secure, especially in a production environment.

Feel free to customize this README.md to suit your project's specific requirements, and add any additional information or instructions as necessary.

Make sure to replace "https://github.com/EMMMABK/authorization-alif.git" with the actual URL of your project's repository if it's hosted on a platform like GitHub. Additionally, customize any other parts of the README to match your project's specific needs.

About

πŸ”’πŸŒ 'Authorization Alif' - A Django-based app for secure user auth, email confirmation, and news management using Django & REST framework. Empowering seamless user experiences and efficient news handling.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages