On Sun, Mar 13, 2011 at 10:33 PM, ZHUO Qiang <zhuo.qi...@gmail.com> wrote: > Hi All, > > I'm right now developing a new RESTful web service project using Pyramid. > The problem is that there seems little info about how to do RESTful route in > Pyramid (on the contrary there is pretty good support about how to build > RESTful style web in both framework and document In Pylons). > > Actaully it's not hard to figure out how to do it the Pyramid way after some > study. And I have summarized my solution here: > http://zhuoqiang.me/a/restful-pyramid > > I see others are looking for the solution as well (see > https://groups.google.com/d/msg/pylons-devel/0Qypgj7Lk1M/CaNwkqaC38UJ) I > hope it will be a help to all. > > Any feedbacks, correctings, suggestions are welcome. I'm not sure if the > solution has any potential side effects. > > It's better that some build-in support for RESTful be added into Pyramid, at > least there should be some *offical* docuement for how to do it.
There was going to be a pyramid_routehelper package with an equivalent to Routes map.resource() but it's not written yet. So for now you have to do REST on your own. Yes, there needs to be an official way to do it. You can also use the request_param route predicate to check the _method param directly. -- Mike Orr <sluggos...@gmail.com> -- You received this message because you are subscribed to the Google Groups "pylons-devel" group. To post to this group, send email to pylons-devel@googlegroups.com. To unsubscribe from this group, send email to pylons-devel+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/pylons-devel?hl=en.