Settings

Theme

What python framework can be used to build a REST api?

3 points by udswagz 11 years ago · 9 comments · 1 min read


I know of Flask, Django and Pyramid. I don't want anything that has those in it, i all i want is a pure Rest Framework (not Web framework with REST extensions). Something that is used for just RESTful ApI. Just Models and Controllers no views. Thanks in advance.

smt88 11 years ago

Just because a framework offers views doesn't mean that it's too heavy for you. If no views are being processed, they're adding a negligible amount of overhead just from loading the code.

You don't necessarily even need a framework. You could use some libraries. You only need: routing, HTTP request processing, and HTTP response preparation.

  • udswagzOP 11 years ago

    links please ?

    • smt88 11 years ago

      I've actually only used Django, Flask, and CherryPy for Python projects, so I haven't researched that stuff.

      In general, I strongly support the idea of tying together tiny libraries, rather than using a framework. It takes months to learn every line of code in an end-to-end framework, but if you're pulling in just the 2-3 libraries you need, you can understand every line of your code. That's really important for efficiency/bugfixing/maintenance.

      You might want to check out Bobo: http://bobo.digicool.com/en/latest/index.html

    • graphene 11 years ago

      You could check out werkzeug: http://werkzeug.pocoo.org/

      Note: Flask is basically just a combination of werkzeug and jinja for templating.

fclaerho 11 years ago

If you're still looking for something, I've hacked a wrapper over Bottle to ease the implementation of a REST service, it's small (2 python files including Bottle) and might fit your needs: https://github.com/fclaerho/rest

iurisilvio 11 years ago

Werkzeug is the Flask HTTP handler. It can be useful for you. I know restpy [0], based on werkzeug.

[0] https://restpy.readthedocs.org/en/latest/

chudi 11 years ago

you said that you don't want any flask, but have you looked at Flask-Restless ?

Flask just gives you the routing part maybe you can even strip flask out of it and just use wsgi.

You can try http://python-eve.org/ too

avinassh 11 years ago

have you looked into Tornado?

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection