Visual RFC.
ALL RFCs / RFC 5789
Read the RFC ↗
RFC 5789 / MECHANISM GUIDE

Patch versus replacement

01

PATCH submits modification instructions rather than a complete replacement representation.

RFC 5789 · § 2EXAMPLE
3 / 3
03
Apply the specified change

Other values survive according to the patch format.

Patch versus replacementPATCH submits modification instructions rather than a complete replacement representation.Patch versus replacementname: Adacolor: bluePATCH: set color = greenname: Ada color: green

Key idea: The request media type identifies the patch-document format.

Terms

Look up a term in the glossary ↗

Rules & examples
  • The request media type identifies the patch-document format.
  • PATCH is neither safe nor inherently idempotent.
  • Creation of a missing target is possible only when the patch format and permissions allow it.

Examples are illustrative. Consult the linked RFC and its errata for implementation details.

Sources
Protocol participantThreat or exceptionProtocol controlSimplified drawings · precise section references
New to this? Start hereA quick picture + helpful background

A request starts a conversation.

A client asks for a resource. A server sends a response. The method, address, headers, and status explain what that conversation means.

Helpful first, if these ideas are unfamiliar

These pictures are analogies to help you learn. The linked RFC explains the actual rules.

Related RFCs and changes

“Updates” changes part of an earlier RFC. “Obsoletes” replaces it. This list shows selected related documents.

What changed
Complete replacement with PUTRFC 5789 §1

This document adds PATCH for partial modification because PUT replacement does not express a generic set of modification instructions. JSON Patch is specified separately.

Read the updated RFC section ↗

All chapters in RFC 5789

Drawing view

Scroll the drawing to see every part. Playback controls stay above it.

RFC 9700 / CHAPTERS

Chapters

For full details, tables, algorithms, and exceptions, read the original RFC.

RFC status and corrections ↗