github.com/googleapis/api-linter@v1.65.2/docs/rules/0235/http-body.md (about)

     1  ---
     2  rule:
     3    aip: 235
     4    name: [core, '0235', http-body]
     5    summary: Batch Delete methods should use `*` as the HTTP body.
     6  permalink: /235/http-body
     7  redirect_from:
     8    - /0235/http-body
     9  ---
    10  
    11  # Batch Delete methods: HTTP body
    12  
    13  This rule enforces that all `BatchDelete` RPCs use `*` as the HTTP `body`, as
    14  mandated in [AIP-235][].
    15  
    16  ## Details
    17  
    18  This rule looks at any RPC methods beginning with `BatchDelete`, and
    19  complains if the HTTP `body` field is anything other than `*`.
    20  
    21  ## Examples
    22  
    23  **Incorrect** code for this rule:
    24  
    25  ```proto
    26  // Incorrect.
    27  rpc BatchDeleteBooks(BatchDeleteBooksRequest) returns (google.protobuf.Empty) {
    28    option (google.api.http) = {
    29      post: "/v1/{parent=publishers/*}/books:batchDelete"
    30      body: ""  // The http body should be "*".
    31    };
    32  }
    33  ```
    34  
    35  **Correct** code for this rule:
    36  
    37  ```proto
    38  // Correct.
    39  rpc BatchDeleteBooks(BatchDeleteBooksRequest) returns (google.protobuf.Empty) {
    40    option (google.api.http) = {
    41      post: "/v1/{parent=publishers/*}/books:batchDelete"
    42      body: "*"
    43    };
    44  }
    45  ```
    46  
    47  ## Disabling
    48  
    49  If you need to violate this rule, use a leading comment above the method.
    50  Remember to also include an [aip.dev/not-precedent][] comment explaining why.
    51  
    52  ```proto
    53  // (-- api-linter: core::0235::http-body=disabled
    54  //     aip.dev/not-precedent: We need to do this because reasons. --)
    55  rpc BatchDeleteBooks(BatchDeleteBooksRequest) returns (google.protobuf.Empty) {
    56    option (google.api.http) = {
    57      post: "/v1/{parent=publishers/*}/books:batchDelete"
    58    };
    59  }
    60  ```
    61  
    62  If you need to violate this rule for an entire file, place the comment at the
    63  top of the file.
    64  
    65  [aip-235]: https://aip.dev/235
    66  [aip.dev/not-precedent]: https://aip.dev/not-precedent