Skip to main content

DRF_commands is a Django package that helps you to create django rest framework endpoints faster using manage.py.

You can visit Django rest framework website for more information about generic views:https://www.django-rest-framework.org/

Quick start

  1. Run pip install DRF_commands

  2. Add Both “rest_framework” and “DRF_commands” to your INSTALLED_APPS of your settings.py like this:

    INSTALLED_APPS = [
        ...
        'rest_framework',
        'DRF_commands',
    ]
  3. Create a Django application using DRF_commands:

python manage.py createApp [yourAppName]

  1. Run python manage.py using custom commands of DRF_commands to create generic views.

Available commands:

  • createApp [yourAppName]

  • createSerializer [appName][serializerName]

  • APIView [appName][viewName]

  • CreateAPIView [appName][viewName]

  • DestroyAPIView [appName][viewName]

  • ListAPIView [appName][viewName]

  • ListCreateAPIView [appName][viewName]

  • RetrieveAPIView [appName][viewName]

  • RetrieveDestroyAPIView [appName][viewName]

  • RetrieveUpdateAPIView [appName][viewName]

  • RetrieveUpdateDestroyAPIView [appName][viewName]

  • UpdateAPIView [appName][viewName]

Generated application working tree:

├── admin.py
├── apps.py
├── __init__.py
├── migrations
│   └── __init__.py
├── models
│   └── __init__.py
├── serializers
│   └── __init__.py
├── static
│   └── myapp
├── templates
│   └── myapp
├── tests.py
├── urls.py
└── views
    └── __init__.py

Metadata

Release files for DRF-commands 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for DRF-commands 0.1.1
File Size Uploaded
DRF_commands-0.1.1.tar.gz 7.2 kB Details

Release files / DRF_commands-0.1.1.tar.gz

Download URL DRF_commands-0.1.1.tar.gz
Size 7.2 kB
Tags Source
SHA-256 checksum
How to use checksums
dee159107a37db5ee1380338890e095a5ec983c2736b544d584394b5309baccd
BLAKE2b-256 checksum
How to use checksums
38fb5d5c2d13853748dc0987ac969273e07ceb43dc3fb9a90c1de3d6cbde5d5c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.5.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.5

Release history Release notifications | RSS feed

This release

0.1.1 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page