Vataxia

Open source social network built with Django and Django REST framework

  • 所有者: buckyroberts/Vataxia
  • 平台:
  • 许可证:
  • 分类:
  • 主题:
  • 喜欢:
    0
      比较:

Github星跟踪图

Overview

Vataxia is an open source social network built with Django and Django REST framework. This project is the backend REST
API only. The frontend is written in React and can be found here:

Vataxia Frontend

Project Setup

Install required packages:

pip3 install -r requirements/local.txt

Initialize database:

python3 manage.py makemigrations
python3 manage.py migrate

Fixtures

To load in sample data for all tables at once:

bash scripts/load_sample_data.sh

For Windows users:

python manage.py loaddata v1\accounts\fixtures\user.json

This will create an initial superuser account with the following credentials:

admin@email.com
pass1234

Authentication

To login, send a POST request to /login with the data:

  • email
  • password

On success, user information and API token will be returned:

{
  "id": 1,
  "email": "admin@email.com",
  "first_name": "Bucky",
  "last_name": "Roberts",
  "profile": {
    "id": 2,
    "image": "/media/bucky_256.png",
    "user": 1
  },
  "role": "administrator",
  "token": "cb810da7d03b85335ea18babf3536fbf2a31ccdf"
}

All subsequent API requests must include this token in the HTTP header for user identification.
Header key will be Authorization with value of 'Token' followed by a single space and then token string:

Authorization: Token 753da61b4c39bd195782710c82fe3c3b1e7f7428

API Documentation

To view API documentation, run development server and visit http://127.0.0.1:8000/docs/

主要指标

概览
名称与所有者buckyroberts/Vataxia
主编程语言Python
编程语言Python (语言数: 2)
平台
许可证
所有者活动
创建于2017-05-27 00:00:01
推送于2023-11-09 14:11:50
最后一次提交2017-07-03 04:06:43
发布数0
用户参与
星数448
关注者数47
派生数125
提交数122
已启用问题?
问题数18
打开的问题数7
拉请求数9
打开的拉请求数1
关闭的拉请求数0
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?