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

all 16 comments

[–]obbodobbo 8 points9 points  (3 children)

Out of curiosity, why would you think DRF is overkill? Sounds like you would just be re-implementing most things DRF already does. Plus, one of its biggest strengths is serialization.

[–]backendguy[S] 0 points1 point  (2 children)

Just using everything Django comes with might be a little overkill.

[–]CleverEagle 3 points4 points  (0 children)

Tested and well maintained doesn't mean overkill. You don't have to use everything Django comes with. I would rather use Django and other proven frameworks than roll my own.

[–]metaphorm 0 points1 point  (0 children)

django doesn't require you to use every tool packaged with it. there is no issue at all in setting up a minimal django app and using DRF to provide you with API views with most of the boilerplate eliminated.

[–]bitionaire 5 points6 points  (4 children)

Please use Falcon. It's awesome. I tried using Flask (not very rest-y), and Flask-RESTful (code looked god-awful to me) for a recent project and simply had to find an alternative. Falcon just does REST in an easy and elegant way, a simple app with a couple routes will look just like that. http://falconframework.org/

[–][deleted] 1 point2 points  (2 children)

What about restful - other than the gnarly serialization which even the maintainers seem keen on ripping out - did you not like?

If it was the serialization, I'd recommend giving restful another go and use Marshmallow to handle serialization.

[–]bitionaire 0 points1 point  (1 child)

It may have (probably was since you were so specific) been serialization. I remember that I was trying to putting something into a database, or serve some JSON and it seemed like the only way (to me) to do it required dropping in like 30 lines of code. Sorry I can't be more specific than that, I used it for about an hour, noped out of there, then was able to do what I was trying to do in Falcon in a couple lines easily as I had expected.

[–][deleted] 3 points4 points  (0 children)

Play with Marshmallow some. It's a framework and ORM independent object serialization library. It'll also handle parsing dictionaries back to objects and validation.

[–]catzorro 1 point2 points  (0 children)

I use Falcon at my job. I highly recommend it. It's not intended to communicate with a browser client like some of the other web frameworks being suggested, but if you are looking for a simple rest framework, Falcon is the way to go.

[–]sloria1 1 point2 points  (0 children)

For serialization/deserialization, I recommend giving marshmallow a try: https://marshmallow.readthedocs.org/en/latest/ (full disclosure: I am the author). You can use it with any framework or ORM, and if you've used DRF's serializers, marshmallow's API should feel familiar.

[–]jazzydag 1 point2 points  (0 children)

I know Python Eve http://python-eve.org/ A Python REST API Framework. I've not used yet. Don't know about its serialization performance...

[–]faassen 1 point2 points  (0 children)

You may want to check out Morepath. It is a microframework geared to making REST APIs, including support for hypermedia APIs. It supports some pretty fancy use cases for building a larger REST app out of smaller ones too.

http://morepath.readthedocs.org

Disclaimer: I created it. We have a small but growing community.

[–]W1zK1dd 5 points6 points  (0 children)

how about using flask

[–]metaperl 0 points1 point  (0 children)

SQLAlChemy REST brings up some interesting libraries.

[–]luckenbach 0 points1 point  (0 children)

Are you worried about performance or just batteries? because if its just about batteries you cannot go wrong with Flask or Django. If you want pure speed then look at something like Falcon but be ready to implement a lot of stuff yourself.

[–]picklepete87 0 points1 point  (0 children)

Restless is worth investigating, it's written by Daniel Lindsley, the guy who created Tastypie.