File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22id : 131
33state : approved
44created : 2019-01-22
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 10
@@ -36,7 +37,7 @@ rpc GetBook(GetBookRequest) returns (Book) {
3637
3738- The RPC's name ** must** begin with the word ` Get ` . The remainder of the RPC
3839 name ** should** be the singular form of the resource's message name.
39- - The request message ** must** match the RPC name, with a ` - Request` suffix.
40+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
4041- The response message ** must** be the resource itself. (There is no
4142 ` GetBookResponse ` .)
4243 - The response ** should** usually include the fully-populated resource unless
@@ -99,6 +100,7 @@ exist, the service **must** error with `NOT_FOUND` (HTTP 404).
99100
100101## Changelog
101102
103+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
102104- ** 2020-06-08** : Added guidance on returning the full resource.
103105- ** 2019-10-18** : Added guidance on annotations.
104106- ** 2019-08-12** : Added guidance for error cases.
Original file line number Diff line number Diff line change 22id : 132
33state : approved
44created : 2019-01-21
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 20
@@ -37,7 +38,7 @@ rpc ListBooks(ListBooksRequest) returns (ListBooksResponse) {
3738- The RPC's name ** must** begin with the word ` List ` . The remainder of the RPC
3839 name ** should** be the plural form of the resource being listed.
3940- The request and response messages ** must** match the RPC name, with
40- ` - Request` and ` - Response` suffixes.
41+ ` Request ` and ` Response ` suffixes.
4142- The HTTP verb ** must** be ` GET ` .
4243- The collection whose resources are being listed ** should** map to the URI
4344 path.
@@ -204,6 +205,7 @@ not exist, the service **must** error with `NOT_FOUND` (HTTP 404).
204205
205206## Changelog
206207
208+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
207209- ** 2020-09-02** : Add link to the filtering AIP.
208210- ** 2020-08-14** : Added error guidance for permission denied cases.
209211- ** 2020-06-08** : Added guidance on returning the full resource.
Original file line number Diff line number Diff line change 22id : 133
33state : approved
44created : 2019-01-23
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 30
@@ -37,7 +38,7 @@ rpc CreateBook(CreateBookRequest) returns (Book) {
3738
3839- The RPC's name ** must** begin with the word ` Create ` . The remainder of the
3940 RPC name ** should** be the singular form of the resource being created.
40- - The request message ** must** match the RPC name, with a ` - Request` suffix.
41+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
4142- The response message ** must** be the resource itself. There is no
4243 ` CreateBookResponse ` .
4344 - The response ** should** include the fully-populated resource, and ** must**
@@ -194,6 +195,7 @@ user-specified IDs.
194195
195196## Changelog
196197
198+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
197199- ** 2020-10-06** : Added declarative-friendly guidance.
198200- ** 2020-08-14** : Updated error guidance to use permission denied over
199201 forbidden.
Original file line number Diff line number Diff line change 22id : 134
33state : approved
44created : 2019-01-24
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 40
@@ -37,7 +38,7 @@ rpc UpdateBook(UpdateBookRequest) returns (Book) {
3738
3839- The RPC's name ** must** begin with the word ` Update ` . The remainder of the
3940 RPC name ** should** be the singular form of the resource's message name.
40- - The request message ** must** match the RPC name, with a ` - Request` suffix.
41+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
4142- The response message ** must** be the resource itself. (There is no
4243 ` UpdateBookResponse ` .)
4344 - The response ** should** include the fully-populated resource, and ** must**
@@ -283,6 +284,7 @@ exist, the service **must** error with `NOT_FOUND` (HTTP 404) unless
283284
284285## Changelog
285286
287+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
286288- ** 2021-11-04** : Changed the permission check if ` allow_missing ` is set.
287289- ** 2021-07-08** : Added error guidance for resource not found case.
288290- ** 2021-03-05** : Changed the etag error from ` FAILED_PRECONDITION ` (which
Original file line number Diff line number Diff line change 22id : 135
33state : approved
44created : 2019-01-24
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 50
@@ -35,7 +36,7 @@ rpc DeleteBook(DeleteBookRequest) returns (google.protobuf.Empty) {
3536
3637- The RPC's name ** must** begin with the word ` Delete ` . The remainder of the
3738 RPC name ** should** be the singular form of the resource's message name.
38- - The request message ** must** match the RPC name, with a ` - Request` suffix.
39+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
3940- The response message ** should** be ` google.protobuf.Empty ` .
4041 - If the resource is [ soft deleted] ( #soft-delete ) , the response message
4142 ** should** be the resource itself.
@@ -233,6 +234,7 @@ exist, the service **must** error with `NOT_FOUND` (HTTP 404) unless
233234
234235## Changelog
235236
237+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
236238- ** 2022-02-02** : Changed eTag error from ` FAILED_PRECONDITION ` to ` ABORTED ` making it consistent with change to [ AIP-154] [ ] & [ AIP-134] [ etag ] on 2021-03-05.
237239- ** 2020-10-06** : Added guidance for declarative-friendly resources.
238240- ** 2020-10-06** : Added guidance for allowing no-op delete for missing
Original file line number Diff line number Diff line change 22id : 136
33state : approved
44created : 2019-01-25
5+ updated : 2022-06-02
56placement :
67 category : operations
78 order : 100
@@ -54,9 +55,9 @@ services. The bullets below apply in all three cases.
5455- The ` body ` clause in the ` google.api.http ` annotation ** should** be ` "*" ` .
5556 - However, if using ` GET ` or ` DELETE ` , the ` body ` clause ** must** be absent.
5657- Custom methods ** should** usually take a request message matching the RPC
57- name, with a ` - Request` suffix.
58+ name, with a ` Request ` suffix.
5859- Custom methods ** should** usually return a response message matching the RPC
59- name, with a ` - Response` suffix.
60+ name, with a ` Response ` suffix.
6061 - When operating on a specific resource, a custom method ** may** return the
6162 resource itself.
6263
@@ -118,6 +119,7 @@ expectation of declarative support.
118119
119120## Changelog
120121
122+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
121123- ** 2020-10-06:** Added declarative-friendly guidance.
122124- ** 2019-08-01:** Changed the examples from "shelves" to "publishers", to
123125 present a better example of resource ownership.
Original file line number Diff line number Diff line change 22id : 144
33state : approved
44created : 2020-03-19
5+ updated : 2022-06-02
56placement :
67 category : fields
78 order : 50
@@ -95,10 +96,10 @@ rpc RemoveAuthor(RemoveAuthorRequest) returns (Book) {
9596 a map with the ` Update ` method instead.
9697- The RPC's name ** must** begin with the word ` Add ` or ` Remove ` . The remainder
9798 of the RPC name ** should** be the singular form of the field being added.
98- - The request message ** must** match the RPC name, with a ` - Request` suffix.
99+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
99100- The response message ** should** be the resource itself, unless there is useful
100101 context to provide in the response, in which case the response message must
101- match the RPC name, with a ` - Response` suffix.
102+ match the RPC name, with a ` Response ` suffix.
102103 - When the response is the resource itself, it ** should** include the
103104 fully-populated resource.
104105- The HTTP verb ** must** be ` POST ` , as is usual for [ custom methods] [ aip-136 ] .
@@ -153,6 +154,7 @@ message RemoveAuthorRequest {
153154
154155## Changelog
155156
157+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
156158- ** 2020-10-17** : Recommended returning the resource itself in Add and Remove
157159 RPCs over separate response types.
158160- ** 2020-10-17** : Added guidance for Add and Remove RPCs and requests.
Original file line number Diff line number Diff line change 22id : 152
33state : approved
44created : 2020-04-27
5+ updated : 2022-06-02
56placement :
67 category : design-patterns
78 order : 10
@@ -58,11 +59,11 @@ rpc RunWriteBookJob(RunWriteBookJobRequest)
5859
5960- The RPC's name ** must** begin with the word ` Run ` . The remainder of the
6061 RPC name ** should** be the singular form of the job resource being run.
61- - The request message ** must** match the RPC name, with a ` - Request` suffix.
62+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
6263- The method ** should** return a [ long-running operation] [ aip-151 ] , which
6364 ** must** resolve to a response message that includes the result of running
6465 the job.
65- - The response message name must match the RPC name, with a ` - Response`
66+ - The response message name must match the RPC name, with a ` Response `
6667 suffix.
6768 - The method ** may** use any metadata message it wishes.
6869- The HTTP verb ** must** be ` POST ` , as is usual for [ custom methods] [ aip-136 ] .
@@ -127,6 +128,7 @@ the child resource.
127128
128129## Changelog
129130
131+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
130132- ** 2020-11-02** : Expanded guidance on HTTP, field behavior, and resource
131133 reference annotations and request format.
132134
Original file line number Diff line number Diff line change 22id : 165
33state : approved
44created : 2019-12-18
5+ updated : 2022-06-02
56placement :
67 category : design-patterns
78 order : 100
@@ -45,10 +46,10 @@ rpc PurgeBooks(PurgeBooksRequest) returns (google.longrunning.Operation) {
4546
4647- The RPC's name ** must** begin with the word ` Purge ` . The remainder of the
4748 RPC name ** should** be the plural form of the resource being purged.
48- - The request message ** must** match the RPC name, with a ` - Request` suffix.
49+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
4950- The response type ** must** be a ` google.longrunning.Operation ` (see
5051 AIP-151) that resolves to a message whose name matches the RPC name, with
51- a ` - Response` suffix.
52+ a ` Response ` suffix.
5253- The HTTP verb ** must** be ` POST ` , and the ` body ` ** must** be ` "*" ` .
5354- The URI path ** should** represent the collection for the resource.
5455- The ` parent ` field ** should** be included in the URI. If the API wishes to
@@ -131,6 +132,7 @@ message PurgeBooksResponse {
131132
132133## Changelog
133134
135+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
134136- ** 2020-10-29** : Expanded guidance on HTTP, field behavior, and resource
135137 reference annotations.
136138
Original file line number Diff line number Diff line change 22id : 216
33state : approved
44created : 2018-10-01
5+ updated : 2022-06-02
56placement :
67 category : fields
78 order : 110
@@ -89,7 +90,7 @@ rpc PublishBook(PublishBookRequest) returns (Book) {
8990
9091- The name of the method ** should** be a verb followed by the singular form of
9192 the resource's message name.
92- - The request message ** must** match the RPC name, with a ` - Request` suffix.
93+ - The request message ** must** match the RPC name, with a ` Request ` suffix.
9394- The response message ** should** be the resource itself.
9495 - If the RPC is [ long-running] [ ] , the response message ** should** be a
9596 ` google.longrunning.Operation ` which resolves to the resource itself.
@@ -232,6 +233,7 @@ necessary.
232233
233234## Changelog
234235
236+ - ** 2022-06-02:** Changed suffix descriptions to eliminate superfluous "-".
235237- ** 2020-10-20** : Added guidance on prefixing enum values with enum name.
236238- ** 2020-09-02** : Clarified that states are not directly set on create either.
237239- ** 2019-12-05** : Changed guidance on state transition methods, downgrading
You can’t perform that action at this time.
0 commit comments