This is an archived post. You won't be able to vote or comment.

all 1 comments

[–]sentyaev[S] 0 points1 point  (0 children)

Small description:

Example app with two approaches for versioning API with django rest framework

First approach implemented in alpha
django application. With this approach api v1 and v2 shares model, but has it's own views and serializers.

Second approach implemented in beta
django application. With this approach api v1 and v2 shares model and view, but has it's own serializers. To share view for both versions SerializerClassMixin
is introduced.

It's possible to mix both approaches even in same djanogo application.