O'Reilly logo
  • Pawel Konieczny thinks this is interesting:

method support


Cover of Building Web Applications with Flask


How to test it with curl: curl -X GET http://localhost:5000/articles/ curl -X POST -d '{"title":"API title","content":"API"}' \ -H "Content-Type: application/json" http://localhost:5000/api/articles curl -X PUT -d '{"title":"new title","content":"new content"}' \ -H "Content-Type: application/json" http://localhost:5000/api/articles/1 curl -X DELETE http://localhost:5000/articles/2 curl -X GET http://localhost:5000/articles/ Note: disable csrf protection in ArticleForm for the above to work.