Skip to content

Commit fbafa2f

Browse files
author
Luke Sneeringer
authored
docs: AIP–154 – Flesh out If-Match example. (#27)
Based on a comment from mkistler@ in #4.
1 parent 13f18d4 commit fbafa2f

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

aip/general/0154/aip.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,16 @@ guarantees it will change if the resource changes.
3535

3636
### Condition headers
3737

38+
Services that provide ETags **should** support the `If-Match` and
39+
`If-None-Match` headers on incoming requests:
40+
41+
```http
42+
GET /v1/publishers/{publisher}/books/{book} HTTP/2
43+
Host: library.googleapis.com
44+
Accept: application/json
45+
If-Match: "55cc0347-66fc-46c3-a26f-98a9a7d61d0e"
46+
```
47+
3848
If the service receives a request to modify a resource that includes an
3949
`If-Match` header, the service **must** validate that the value matches the
4050
current ETag. If the `If-Match` header value does not match the ETag, the

0 commit comments

Comments
 (0)