Django REST framework vs Tastypie

Need advice about which tool to choose?Ask the StackShare community!

Django REST framework

1.5K
1.5K
+ 1
300
Tastypie

37
46
+ 1
4
Add tool

Django REST framework vs Tastypie: What are the differences?

Django REST framework: Web APIs for Django. Django REST framework is a powerful and flexible toolkit that makes it easy to build Web APIs; Tastypie: Creating delicious APIs for Django apps since 2010. Tastypie is a webservice API framework for Django. It provides a convenient, yet powerful and highly customizable abstraction for creating REST-style interfaces.

Django REST framework and Tastypie can be primarily classified as "Microframeworks (Backend)" tools.

Some of the features offered by Django REST framework are:

  • The Web browsable API is a huge usability win for your developers.
  • Authentication policies including OAuth1a and OAuth2 out of the box.
  • Serialization that supports both ORM and non-ORM data sources.

On the other hand, Tastypie provides the following key features:

  • Full GET/POST/PUT/DELETE/PATCH support
  • Reasonable defaults
  • Designed to be extended at every turn

Django REST framework and Tastypie are both open source tools. Django REST framework with 14.5K GitHub stars and 4.29K forks on GitHub appears to be more popular than Tastypie with 3.53K GitHub stars and 1.12K GitHub forks.

Advice on Django REST framework and Tastypie
Needs advice
on
Flask
and
Django REST framework

Hey! So I am planning to make an e-commerce website with React Native as my frontend technology stack and MongoDB as my database. I was wondering what will be the best REST framework to use for my backend that will simply serve the frontend. Is Django rest framework a good option or should I go with Flask? I am currently leaning towards flask as the development team is well versed in it. Please help!

See more
Replies (2)
Preeti Yuankrathok
Software Consultant at CODIUM · | 2 upvotes · 7.2K views

If the application is simple such as less endpoint or simple logic, I'd suggest Flask. But what you're building is quite a large system that contains many logics and a lot of models. So I'd suggest you with Django and Django REST framework. Django ORM is also one of the best ORM in the world as well.

See more
Mayur Borse
Software Engineer at hyphenOs · | 2 upvotes · 11.5K views
Recommends
fastapi
FastAPI

FastAPI is modern microframework. If you haven't used any of them, I'd suggest FastAPI. Django REST is also good if you have previous experience with it.

See more
haydenlingle

I'm going to do an independent study with React for school, and I'm looking to build a full-stack application. I have lots of experience with react, but everything else I'd need is somewhat foreign to me. What I'm looking for is to provide a back-end for a React application.

I'm trying to find a back-end framework that can provide and integrate with almost everything I need (database, API, authentication). I will also need to be able to host everything eventually online rather than just locally on my computer. I don't want to use something that is just click-and-go: I want to learn a lot but find something that has much built in functionality, so I don't have to completely re-invent the wheel.

Does anyone else have experience with a stack you'd recommend that is a happy medium of helpful features while still requiring you to understand and implement the functionality yourself? Something well documented (e.g., it's easy to find documentation regarding putting all the pieces together) would be great.

Thanks in advance!

See more
Replies (6)
Marcelo Escobar
Recommends
Rails

Greate documentation, lot's of info on StackOverflow and it's easy to learn, a lot of things it's already implemented on the stack. It's based on Ruby which is stable and constantly evolving.

Ruby/Rails have a lot of gems(libraries) that will allow you to connect to many DB systems, implement JWT or use a library for authentication.

I have a lot of API's created in Rails that respond to website and mobile apps, and you can create your first one without a lot of stress, responding with JSON easily.

You can use VSCode has good support for ruby and you will have all syntax help etc, I use Atom but I don't have the syntax support, didn't found a good package for that.

See more
Recommends
Node.js

The most popular stack that comes to mind for your case if MERN ( Mongo, Express, React and Node) I would use Nodejs + Express for backend. Easy to build dynamic and powerful REST APIs. For DB, it would be Mongo DB and front end can be React + Redux (for global state management). Plus NPM has a ton of packages for most cases. PS : Webstorm (free for students) or VS Code ( free for all) for IDE

See more
Alberto Mazaira
Recommends
Rails
Node.js

I would take either Rails or Node for your problem.

Rails is a great framework: super complete in regards of testing frameworks, authentication libraries, great community support.... but I would say that the latest versions are a bit of a mess for newcomers, because of the way they manage assets: if the assets are served by the framework(Assets Pipeline) vs using Webpack .

If you are already familiar with React, Node is another great framework that will require a bit more effort on selecting the dependencies but for your use case seems a great candidate.

In regards of what you are commenting about learning during the process, both can be Dockerized pretty easy and you can spend some time digging on the lifecycle of putting it into production. Rails has a ridiculous easy way of deploying with Heroku avoiding any kind of work, but if you want to get your hands dirty you can deploy either of the frameworks on a Dockerized environment to any cloud provider you like. That part is really interesting too, and if you are interested on the Devops side, I would say that Node is a bit easier and more convenient(smaller image sizes and times to build) than Rails. All in all:

Rails pros: stable framework, great community support, great testing utilities. Rails cons: How they manage the assets lately(Assets Pipeline vs Webpack), dockerize the app.

Node pros: You are already familiar with Js, simple, easy to put in prod allowing to spend time in the Devops side. Node cons: Dependency management in Js environments is a pain in the ass

See more
Julien DeFrance
Principal Software Engineer at Tophatter · | 4 upvotes · 2.8K views
Recommends
Rails

Rails is an easy framework to pick up, and you'll get to love all of the magic it does for you. Some of that can be a little confusing at first but once you've got acquainted, this is part of the productivity Rails offers as opposed to other languages or frameworks that sometimes tend to require developers to waste a ton of valuable time setting up their own boilerplate when starting to work on a new project. More pragmatically, Rails is still extremely popular at both startups and at large companies, you can use it to power web applications, or backend APIs, and this will be extremely valuable on your resume. There also is a very large/rich set of libraries (called gems) that will allow you to focus on your actual project/product, rather than rebuilding what already exists. I'd recommend you go with the latest versions of Ruby (3.0) and Rails (6.1.1) so you are from the get-go learning them in their most current form.

See more
Rogério R. Alcântara
Recommends

Although not entirely confident, as I've never used Django and I've not used ASP.NET since 2.0, but given your requirements, at first thought, I'd go with Rails.

Yet, may I ask if have you considered some BAAS such as Firebase, Hasura and the like? Although I've admittedly suffered a bit with Firebase - I'm not totally sure if I've used it correctly, tho. But I've heard really awesome things about Hasura. This slant compairson shows some Firebase's alternatives that I've never heard. In your position, I would have a look.

Cheers.

See more
View all (6)
kristan-dev
Senior Solutions Analyst · | 7 upvotes · 92.9K views

My journey to developing REST APIs started with Flask Restful, and I've found it to be enough for the needs of my project back then. Now that I've started investing more time on personal projects, I've yet to decide if I should move to use Django for writing REST APIs. I often see job posts looking for Python+Django developers, but it's usually for full-stack developers. I'm primarily interested in Data Engineering, so most of my web projects are back end.

Should I continue with what I know (Flask) or move on to Django?

See more
Replies (1)
Rafael Torres
Technical Lead at 4Agile · | 9 upvotes · 83.7K views

If you want to be a Web developer with knowledge in another frontend and NoSql technology, maybe continue with Flask. However, if you want to create very fast solutions to grow up with a new business and merge these with data analysis and other tools, Django is the answer. Basically read more about the service architecture where you feel more comfortable, Microservice or Monolithic, but please will not married with any because they solve issues to different contexts.

See more
Decisions about Django REST framework and Tastypie
Shiqi Lin
Software Developer at BigClarity · | 3 upvotes · 43.2K views

We will use Django to set up our backend and Django REST Framework (DRF) for our API creation. The easiness of performing development tasks (eg. user authentication, URL routing, and schema migration) attracts our attention. Also, Django with PostgreSQL provides many benefits: 1. Some data types in Django will only work with PostgreSQL; 2. Django offers django.contrib.postgres to operate on PostgreSQL; 3. Django supports many features of PostgreSQL. Moreover, Django is compatible with Redis.

See more
Get Advice from developers at your company using Private StackShare. Sign up for Private StackShare.
Learn More
Pros of Django REST framework
Pros of Tastypie
  • 64
    Browsable api
  • 63
    Easy to use
  • 53
    Great documentation
  • 49
    Customizable
  • 41
    Fast development
  • 9
    Easy to use, customizable, pluggable, serializer
  • 8
    Python
  • 5
    Django ORM
  • 4
    FastSerialize
  • 2
    Less code
  • 2
    Easy implementation
  • 0
    Dsasda
  • 2
    Good in Django
  • 1
    Fast development
  • 1
    Customizable

Sign up to add or upvote prosMake informed product decisions

Cons of Django REST framework
Cons of Tastypie
  • 2
    Bad documentation
  • 2
    Reimplements Django functionality
  • 1
    No support for URL Namespaces
  • 0
    Bad CSRF handling
    Be the first to leave a con

    Sign up to add or upvote consMake informed product decisions

    What is Django REST framework?

    It is a powerful and flexible toolkit that makes it easy to build Web APIs.

    What is Tastypie?

    Tastypie is a webservice API framework for Django. It provides a convenient, yet powerful and highly customizable abstraction for creating REST-style interfaces.

    Need advice about which tool to choose?Ask the StackShare community!

    Jobs that mention Django REST framework and Tastypie as a desired skillset
    What companies use Django REST framework?
    What companies use Tastypie?
    See which teams inside your own company are using Django REST framework or Tastypie.
    Sign up for Private StackShareLearn More

    Sign up to get full access to all the companiesMake informed product decisions

    What tools integrate with Django REST framework?
    What tools integrate with Tastypie?

    Sign up to get full access to all the tool integrationsMake informed product decisions

    Blog Posts

    +42
    46
    38833
    +47
    46
    68357
    +3
    6
    5237
    What are some alternatives to Django REST framework and Tastypie?
    Django
    Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
    Flask
    Flask is intended for getting started very quickly and was developed with best intentions in mind.
    Swagger UI
    Swagger UI is a dependency-free collection of HTML, Javascript, and CSS assets that dynamically generate beautiful documentation and sandbox from a Swagger-compliant API
    Graphene
    Graphene is a Python library for building GraphQL schemas/types fast and easily.
    Spring Boot
    Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.
    See all alternatives
    How developers use Django REST framework and Tastypie
    Yaakov Gesher uses
    Django REST framework

    Django REST delivered all the content to the BI, making calls to the Postgres DB, aggregating numeric data, and automatically associating data models at the time of row creation.

    Alec Cunningham uses
    Django REST framework

    Instead of using Django for both back and frontend, I use DRF to layout an API that ReactJs can pull data from. Easy to setup, well documented, and works seamlessly with React.

    Seungkwon Park uses
    Django REST framework

    django에서 api를 만드는데 최고의 framework라고 생각합니다. 아직은 tutorial 수준의 class base view, function base view 수준으로 사용합니다.

    하지만 현재 진행중인 프로젝트의 심화로 REST framework를 심도있게 다룰 예정입니다.

    Blair Gemmer uses
    Django REST framework

    Really great framework for building RESTful APIs. Lots of plugins for it!

    TOMIS uses
    Django REST framework

    For our backend REST API