Using django-rest-interface

后端 未结 4 1119
轮回少年
轮回少年 2020-12-25 14:44

I have a django application that I\'d like to add some rest interfaces to. I\'ve seen http://code.google.com/p/django-rest-interface/ but it seems to be pretty simplistic.

4条回答
  •  旧时难觅i
    2020-12-25 15:32

    Well, from the look of things, there's an authentication parameter to Collection. (see this example: authentication.py)

    Second, (even if Django doesn't have it yet,) there should probably be a middleware that does CSRF/XSRF form checking. (Oh, there seems to be one.) You should also be able to use the login_required and permission_required decorators in the urls.py.

提交回复
热议问题