Djang Referral System

Overview
Djang Referral System

 

Djang Referral System

Github language Repository size

About   |   Features   |   Technologies   |   Requirements   |   Starting   |   License   |   Author


🎯 About

I created django referral system and I wanna show it for other people! If you wanna contrib you are welcome!

Features

✔️ New user can signUp only with referral code;
✔️ Each new user get 3 referral codes for friends;
✔️ Each new admin get 5 referral codes;

🚀 Technologies

The following tools were used in this project:

Requirements

Before starting 🏁 , you need to have Git and Python + Poetry installed. In the project I used postgresql, you need to start postgresql so you need Docker-compose.

🏁 Starting

# Clone this project
$ git clone https://github.com/mur4ik18/django-referral-system && cd django-referral-system

# Install dependencies
$ poetry install

# Run env
$ poetry shell

# Run postgresql (If you don't have)
$ docker-compose -f db.yml up --build -d

# Start project
$ python src/manage.py runserver

🏁 Works with api

Create account:

POST http://127.0.0.1:8000/auth/jwt/create/
body={
"username":"admin",
"password":"admin"
}

It return:

{
    "refresh": "refresh_token",
    "access": "access_token"
}

Get tokens list:

GET http://127.0.0.1:8000/api/v1/get_tokens/
Headers={
"Authorization":"JWT access_token",
}

It return:

[
    {
        "token": "w3iP8GJt1woqLRM6MNrNx88JxuI",
        "user": 1,
        "refer_relations": [
	   {
	    "employer": 1,
	    "employee": 10,
	    "refer_token": 1
            }
	]
    },
    {
        "token": "E6VQuA4qFucR028UW0XL6FAW8vw",
        "user": 1,
        "refer_relations": []
    },
    ...
]

Create new account:

POST http://127.0.0.1:8000/auth/users/
body={
"username":"user",
"password":"password1",
"email":"[email protected]",
"referral_token":"E6VQuA4qFucR028UW0XL6FAW8vw",
}

It return:

{
    "referral_token": "E6VQuA4qFucR028UW0XL6FAW8vw",
    "email": "t[email protected]",
    "username": "test1sdas",
    "id": 11
}

📝 License

Made with ❤️ by mur4ik18

 

Back to top

Owner
Alex Kotov
Python back-end developer
Alex Kotov
Website desenvolvido em Django para gerenciamento e upload de arquivos (.pdf).

Website para Gerenciamento de Arquivos Features Esta é uma aplicação full stack web construída para desenvolver habilidades com o framework Django. O

Alinne Grazielle 8 Sep 22, 2022
A simple plugin to attach a debugger in Django on runserver command.

django-debugger A simple plugin to attach a debugger in Django during runserver Installation pip install django-debugger Usage Prepend django_debugger

Sajal Shrestha 11 Nov 15, 2021
A simple demonstration of how a django-based website can be set up for local development with microk8s

Django with MicroK8s Start Building Your Project This project provides a Django web app running as a single node Kubernetes cluster in microk8s. It is

Noah Jacobson 19 Oct 22, 2022
A standalone package to scrape financial data from listed Vietnamese companies via Vietstock

Scrape Financial Data of Vietnamese Listed Companies - Version 2 A standalone package to scrape financial data from listed Vietnamese companies via Vi

Viet Anh (Vincent) Tran 45 Nov 16, 2022
Plug and play continuous integration with django and jenkins

django-jenkins Plug and play continuous integration with Django and Jenkins Installation From PyPI: $ pip install django-jenkins Or by downloading th

Mikhail Podgurskiy 941 Oct 22, 2022
PEP-484 stubs for Django

pep484 stubs for Django This package contains type stubs and a custom mypy plugin to provide more precise static types and type inference for Django f

TypedDjango 1.1k Dec 30, 2022
Example project demonstrating using Django’s test runner with Coverage.py

Example project demonstrating using Django’s test runner with Coverage.py Set up with: python -m venv --prompt . venv source venv/bin/activate python

Adam Johnson 5 Nov 29, 2021
Django CRUD REST API Generator

Django CRUD REST API Generator This is a simple tool that generates a Django REST API with the given models. Specs: Authentication, DRF generic views,

Mehmet Alp Sümer 57 Nov 24, 2022
A slick ORM cache with automatic granular event-driven invalidation.

Cacheops A slick app that supports automatic or manual queryset caching and automatic granular event-driven invalidation. It uses redis as backend for

Alexander Schepanovski 1.7k Jan 03, 2023
Full-text multi-table search application for Django. Easy to install and use, with good performance.

django-watson django-watson is a fast multi-model full-text search plugin for Django. It is easy to install and use, and provides high quality search

Dave Hall 1.1k Dec 22, 2022
Fully reponsive Chat Application built with django, javascript, materialUi, bootstrap4, html and css.

Chat app (Full Stack Frameworks with Django Project) Fully reponsive Chat Application built with django, javascript, materialUi, bootstrap4, html and

1 Jan 19, 2022
Highlight the keywords of a page if a visitor is coming from a search engine.

Django-SEKH Django Search Engine Keywords Highlighter, is a middleware for Django providing the capacities to highlight the user's search keywords if

Julien Fache 24 Oct 08, 2021
Template de desarrollo Django

Template de desarrollo Django Python Django Docker Postgres Nginx CI/CD Descripción del proyecto : Proyecto template de directrices para la estandariz

Diego Esteban 1 Feb 25, 2022
Django API that scrapes and provides the last news of the city of Carlos Casares by semantic way (RDF format).

"Casares News" API Api that scrapes and provides the last news of the city of Carlos Casares by semantic way (RDF format). Usage Consume the articles

Andrés Milla 6 May 12, 2022
A small and lightweight imageboard written with Django

Yuu A small and lightweight imageboard written with Django. What are the requirements? Python 3.7.x PostgreSQL 14.x Redis 5.x FFmpeg 4.x Why? I don't

mint.lgbt 1 Oct 30, 2021
A Django app that allows visitors to interact with your site as a guest user without requiring registration.

django-guest-user A Django app that allows visitors to interact with your site as a guest user without requiring registration. Largely inspired by dja

Julian Wachholz 21 Dec 17, 2022
PostgreSQL with Docker + Portainer + pgAdmin + Django local

django-postgresql-docker Running PostgreSQL with Docker + Portainer + pgAdmin + Django local for development. This project was done with: Python 3.9.8

Regis Santos 4 Jun 12, 2022
Atualizando o projeto APIs REST Django REST 2.0

APIs REST Django REST 3.0-KevinSoffa Atualização do projeto APIs REST Django REST 2.0-Kevin Soffa Melhorando e adicionando funcionalidades O que já fo

Kevin Soffa 2 Dec 13, 2022
A feature flipper for Django

README Django Waffle is (yet another) feature flipper for Django. You can define the conditions for which a flag should be active, and use it in a num

950 Dec 26, 2022
Backend with Django .

BackendCode - Cookies Documentation: https://docs.djangoproject.com/fr/3.2/intro/ By @tcotidiane33 & @yaya Models Premium class Pack(models.Model): n

just to do it 1 Jan 28, 2022