Is an entity body allowed for an HTTP DELETE request?

后端 未结 15 1583
长发绾君心
长发绾君心 2020-11-21 13:32

When issuing an HTTP DELETE request, the request URI should completely identify the resource to delete. However, is it allowable to add extra meta-data as part of the entity

15条回答
  •  -上瘾入骨i
    2020-11-21 13:48

    The latest update to the HTTP 1.1 specification (RFC 7231) explicitly permits an entity body in a DELETE request:

    A payload within a DELETE request message has no defined semantics; sending a payload body on a DELETE request might cause some existing implementations to reject the request.

提交回复
热议问题