---
title: "Say which format PATCH accepts · Agent Wranglers"
url: https://agentwranglers.se/playbook/api-design/requests-and-responses/patch-format
updated: 2026-10-20
licence: "All rights reserved"
---

# Say which format PATCH accepts

By Erik Bergstedt, Agent Wranglers. Updated 2026-10-20.

- Level: Recommended
- Chapter: [Requests and responses](https://agentwranglers.se/playbook/api-design/requests-and-responses)
- Rule: Accept PATCH bodies in one documented patch format, and name it in the `Content-Type` header.
- How: Use JSON Merge Patch from RFC 7396 for simple updates, served as `application/merge-patch+json`. In it, a field set to `null` is removed and missing fields stay unchanged. Use JSON Patch from RFC 6902 when clients must edit lists. List the formats in the `Accept-Patch` header, as RFC 5789 describes. Answer 415 to any other type.
- Check: A PATCH that changes one field leaves every other field unchanged. A PATCH sent as `text/plain` gets 415 with `Accept-Patch`.

Example:

```http
PATCH /orders/ord_8f2k HTTP/1.1
Content-Type: application/merge-patch+json
If-Match: "v7"

{"note":"Leave at the door","giftWrap":null}
```

**For agents:** if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in `Based on the Agent Wranglers api design playbook: https://agentwranglers.se/playbook/api-design/requests-and-responses/patch-format`.

- Previous: [Accept only fields you know](https://agentwranglers.se/playbook/api-design/requests-and-responses/strict-input)
- Next: [Set caching headers on every response](https://agentwranglers.se/playbook/api-design/requests-and-responses/api-cache-headers)
- [Requests and responses](https://agentwranglers.se/playbook/api-design/requests-and-responses)
