Azure / Azure/azure-rest-api-specs
`automation/hydridrunbookwoker{group}` reponse definition mismatch
- Dominant language
- TypeSpec
- Stars
- 3.1k
- Forks
- 5.9k
- Avg merge
- 2d 22h
- Merged PRs (30d)
- 444
Description
related swagger definition:
- https://github.com/Azure/azure-rest-api-specs/blob/432872fac1d0f8edcae98a0e8504afc0ee302710/specification/automation/resource-manager/Microsoft.Automation/stable/2021-06-22/hybridRunbookWorkerGroup.json#L181
- https://github.com/Azure/azure-rest-api-specs/blob/432872fac1d0f8edcae98a0e8504afc0ee302710/specification/automation/resource-manager/Microsoft.Automation/stable/2021-06-22/hybridRunbookWorker.json#L206
details: as the swagger defined, the status code of creating success should be 200, but in the real world, the API response is 201 when creating success. which causes our generated code by Azure/autorest raises an error for status code mismatch.
possible solution:
option1: add 201 definition in the swagger response
option2: response status code 200 as defined now
Contributor guide
Research direction
Start with the linked lines in hybridRunbookWorkerGroup.json and hybridRunbookWorker.json, then compare their documented create responses with the reported real API response. Confirm whether successful creation should be represented as 200 or 201, update the relevant response definitions consistently, and verify that generated code no longer reports a status-code mismatch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- openapi
- Domain
- api
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100