官术网_书友最值得收藏!

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.

主站蜘蛛池模板: 浑源县| 遂平县| 安福县| 中牟县| 通山县| 漳州市| 通辽市| 镇宁| 屏东市| 英山县| 龙泉市| 新宾| 西平县| 长阳| 胶南市| 扶余县| 惠水县| 乌拉特中旗| 鹤壁市| 门头沟区| 邓州市| 彭州市| 柳河县| 保靖县| 贵南县| 仙游县| 乌拉特中旗| 崇州市| 花莲县| 仲巴县| 时尚| 蒙城县| 崇明县| 进贤县| 桐乡市| 长汀县| 绥化市| 林口县| 平定县| 祥云县| 防城港市|