- Building Microservices with Go
- Nic Jackson
- 79字
- 2021-07-15 17:28:08
CRUD function names
When designing great REST URIs we never use a CRUD function name as part of the URI, instead we use a HTTP verb. For example:
DELETE /cats/1234
We do not include the verb in the name of the method as this is specified by the HTTP verb, the following URIs would be considered an anti-pattern:
GET /deleteCat/1234
DELETE /deleteCat/1234
POST /cats/1234/delete
When we look at HTTP verbs in the next section this will make more sense.
推薦閱讀
- Cocos2d Cross-Platform Game Development Cookbook(Second Edition)
- Flask Web全棧開發實戰
- Boost.Asio C++ Network Programming(Second Edition)
- Python數據可視化:基于Bokeh的可視化繪圖
- Mastering Objectoriented Python
- Elastic Stack應用寶典
- Full-Stack Vue.js 2 and Laravel 5
- 深度學習:算法入門與Keras編程實踐
- QTP自動化測試進階
- HTML5+CSS3 Web前端開發技術(第2版)
- CoffeeScript Application Development Cookbook
- Python 3 數據分析與機器學習實戰
- Redmine Cookbook
- Solr權威指南(下卷)
- Python數據預處理技術與實踐