Azure / Azure/azure-rest-api-specs
[Authorization] Invalid swagger - duplicate API path
- Dominant language
- TypeSpec
- Stars
- 3.1k
- Forks
- 5.9k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 424
Description
Path "/{scope}/providers/Microsoft.Authorization/roleDefinitions/{roleDefinitionId}" GET looks to be duplicated:
- https://github.com/Azure/azure-rest-api-specs/blob/master/arm-authorization/2015-07-01/swagger/authorization.json#L653
- https://github.com/Azure/azure-rest-api-specs/blob/master/arm-authorization/2015-07-01/swagger/authorization.json#L769
[Error: The Swagger document(s) are invalid]
errors:
[ { code: 'DUPLICATE_API_PATH',
message: 'API path (or equivalent) already defined: /{roleDefinitionId}',
path: [ 'paths', '/{roleDefinitionId}' ] } ],
failedValidation: true
Contributor guide
Research direction
Open arm-authorization/2015-07-01/swagger/authorization.json and compare the GET definitions near lines 653 and 769 for the duplicated /{scope}/providers/Microsoft.Authorization/roleDefinitions/{roleDefinitionId} path. Determine the intended single definition, then run the Swagger validation that reported DUPLICATE_API_PATH; done means the document validates without that duplicate-path error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- openapi
- Domain
- api, authorization, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100