You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Operation ID must start with the verb “list” and should be followed by a noun or compound noun.
84
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form, where the last noun is in plural form.
85
-
86
-
##### Implementation details
87
-
Rule checks for the following conditions:
88
-
- Applies only to GET methods on resource collection paths
89
-
- Ignores singleton resources
90
-
- Generates the expected OperationId given the resource identifier
91
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
Copy file name to clipboardExpand all lines: tools/spectral/ipa/rulesets/IPA-109.yaml
-19Lines changed: 0 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -57,22 +57,3 @@ rules:
57
57
given: '$.paths[*]'
58
58
then:
59
59
function: 'IPA109CustomMethodIdentifierFormat'
60
-
xgen-IPA-109-valid-operation-id:
61
-
description: |
62
-
The Operation ID must start with the custom method verb (the custom method path section delimited by the colon (:) character) and should be followed by a noun or compound noun.
63
-
If the custom Operation ID has a verb + noun, the Operation ID should end with the noun.
64
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier.
65
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form, where the last noun:
66
-
- Is in plural form if the method applies to a collection of resources
67
-
- Is in singular form if the method applies to a single resource
68
-
69
-
##### Implementation details
70
-
Rule checks for the following conditions:
71
-
- Applies only to paths containing custom method identifiers (with colon format)
72
-
- Generates the expected OperationId given the resource identifier and the method name portion following the colon
73
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
Copy file name to clipboardExpand all lines: tools/spectral/ipa/rulesets/README.md
-79Lines changed: 0 additions & 79 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -139,19 +139,6 @@ Rule checks for the following conditions:
139
139
- Applies only to GET methods on single resources or singleton resources
140
140
- Verifies that the operation object does not contain a requestBody property
141
141
142
-
#### xgen-IPA-104-valid-operation-id
143
-
144
-
`off`
145
-
The Operation ID must start with the verb “get” and should be followed by a noun or compound noun.
146
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form.
147
-
If the resource is a singleton resource, the last noun may be the plural form of the collection identifier.
148
-
149
-
##### Implementation details
150
-
Rule checks for the following conditions:
151
-
- Applies only to GET methods on single resources or singleton resources
152
-
- Generates the expected OperationId given the resource identifier
153
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
154
-
155
142
156
143
157
144
### IPA-105
@@ -206,19 +193,6 @@ The response body of the List method should consist of the same resource object
206
193
- Fails if the Get method doesn't have a schema reference or if the schemas don't match
207
194
- Validation ignores resources without a Get method
208
195
- Paths with `x-xgen-IPA-exception` for this rule are excluded from validation
209
-
#### xgen-IPA-105-valid-operation-id
210
-
211
-
`off`
212
-
The Operation ID must start with the verb “list” and should be followed by a noun or compound noun.
213
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form, where the last noun is in plural form.
214
-
215
-
##### Implementation details
216
-
Rule checks for the following conditions:
217
-
- Applies only to GET methods on resource collection paths
218
-
- Ignores singleton resources
219
-
- Generates the expected OperationId given the resource identifier
220
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
221
-
222
196
223
197
224
198
### IPA-106
@@ -299,18 +273,6 @@ Rule checks for the following conditions:
299
273
- Ignores resources without a Get method
300
274
- Paths with `x-xgen-IPA-exception` for this rule are excluded from validation
301
275
302
-
#### xgen-IPA-106-valid-operation-id
303
-
304
-
`off`
305
-
The Operation ID must start with the verb “create” and should be followed by a noun or compound noun.
306
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form.
307
-
308
-
##### Implementation details
309
-
Rule checks for the following conditions:
310
-
- Applies only to POST methods on resource collection paths
311
-
- Generates the expected OperationId given the resource identifier
312
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
313
-
314
276
315
277
316
278
### IPA-107
@@ -382,19 +344,6 @@ Rule checks for the following conditions:
382
344
- Validation only applies to schema references to a predefined schema (not inline)
383
345
- Confirms the referenced schema name ends with "Request" suffix
384
346
385
-
#### xgen-IPA-107-valid-operation-id
386
-
387
-
`off`
388
-
The Operation ID must start with the verb “update” and should be followed by a noun or compound noun.
389
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form.
390
-
If the resource is a singleton resource, the last noun may be the plural form of the collection identifier.
391
-
392
-
##### Implementation details
393
-
Rule checks for the following conditions:
394
-
- Validation checks the PATCH/PUT methods for single resource paths and [singleton resources](https://go/ipa/113).
395
-
- Generates the expected OperationId given the resource identifier
396
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
397
-
398
347
399
348
400
349
### IPA-108
@@ -439,18 +388,6 @@ Rule checks for the following conditions:
439
388
- Fails if any requestBody is defined for the DELETE method
440
389
- Skips validation for collection endpoints (without path parameters)
441
390
442
-
#### xgen-IPA-108-valid-operation-id
443
-
444
-
`off`
445
-
The Operation ID must start with the verb “delete” and should be followed by a noun or compound noun.
446
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form.
447
-
448
-
##### Implementation details
449
-
Rule checks for the following conditions:
450
-
- Applies to all DELETE methods for single resource endpoints (with path parameters)
451
-
- Generates the expected OperationId given the resource identifier
452
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
453
-
454
391
455
392
456
393
### IPA-109
@@ -496,22 +433,6 @@ Rule checks for the following conditions:
496
433
- Fails if multiple colons appear in the path
497
434
- Fails if other than an alphabetical character or a closing curly brace appears before a colon
498
435
499
-
#### xgen-IPA-109-valid-operation-id
500
-
501
-
`off`
502
-
The Operation ID must start with the custom method verb (the custom method path section delimited by the colon (:) character) and should be followed by a noun or compound noun.
503
-
If the custom Operation ID has a verb + noun, the Operation ID should end with the noun.
504
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier.
505
-
The noun(s) in the Operation ID should be the collection identifiers from the resource identifier in singular form, where the last noun:
506
-
- Is in plural form if the method applies to a collection of resources
507
-
- Is in singular form if the method applies to a single resource
508
-
509
-
##### Implementation details
510
-
Rule checks for the following conditions:
511
-
- Applies only to paths containing custom method identifiers (with colon format)
512
-
- Generates the expected OperationId given the resource identifier and the method name portion following the colon
513
-
- Confirms that the existing operationId is compliant with generated IPA Compliant OperationId
0 commit comments