Json 补丁 - 它是否违反 REST 规则?

Json Patch - does it violate REST rules?

Json 补丁是否违反 REST 规则?我的API用了就不会是RESTful?或者,也许不是?

{ "op": "replace", "path": "/biscuits/0/name", "value": "Chocolate Digestive" }

Does Json Patch violate REST rules?

没有

JSON补丁是standardized media-type designed to act as a patch document (in the RFC 5789意义上的)。这是描述对 JSON 文档的编辑的一种完全正常的方式。

Every protocol, every media type definition, every URI scheme, and every link relationship type constitutes prior knowledge that the client must know (or learn) in order to make use of that knowledge. REST doesn’t eliminate the need for a clue. What REST does is concentrate that need for prior knowledge into readily standardizable forms. -- Fielding, 2008

这正是这里所做的。