Skip to main content

Versioning tools for use with Django Rest Framework

Project description

Django REST Framework Versioning

This project aims to make it easy to support many different API versions in a Django REST Framework (DRF) project.

DRF supports several versioning schemes but (perhaps wisely) sidesteps the issue of how to actually deal with the different versions in your code. To quote the docs: "How you vary the API behavior is up to you".

This project provides some out-of-the box tools to handle versioning in views and serializers. The aim is to abstract away any versioning logic into a sort of "versioning layer" and allow the bulk of the code (and its developers) to focus on the latest behaviour.

Documentation

Please see the full documentation here.

Acknowledgements

The approach taken in this project was inspired by Stripe's API version "compatibility layer", as described in blog posts by Brandur Leach and Amber Feng. I used Ryan Kaneshiro's excellent Django sketch as a starting point.

I also want to thank my colleagues at Tranzer for encouraging me to work on this, and for being my guinea pigs / code duckies ❤️

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

djangorestframework_versioning-2.1.0.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file djangorestframework_versioning-2.1.0.tar.gz.

File metadata

File hashes

Hashes for djangorestframework_versioning-2.1.0.tar.gz
Algorithm Hash digest
SHA256 82079a2461f53bebcd0e7f10e9888a7e0ed5ad2c089dba32810b22257f3d2bee
MD5 7aaf3d033594439279b7ec450255fad8
BLAKE2b-256 85d7fdc646ba1c38353486e504bd39545ddb84aab5c7ca4c568e2bfb148a9993

See more details on using hashes here.

File details

Details for the file djangorestframework_versioning-2.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for djangorestframework_versioning-2.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 656671e5dda2ef322988e9e748597295650414f55a9befb57a96d6ee5a5ccc91
MD5 028be28c6fbbb1edd087d7ce5053a6cb
BLAKE2b-256 09f9bbd02bf2ebd1dcc1c1a3fe5c41f12383910e018a406ccb4c53f83d3f3ee0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page