apache / apache/openwhisk-apigateway
Api v2 management allows swagger config to have basepath and path both set to /
- Dominant language
- Lua
- Stars
- 65
- Forks
- 43
- PR merge metrics
- No merged PRs in 30d
Description
When creating a new api, a swagger is sent to api management with both base path and operation path set to `/` the API doesn't error out.
To reproduce you should could use the WSK CLI
```
wsk api create / / get myaction
```
```
wsk api list -f
Action: /guest/myaction
API Name: /
Base path: /
Path: /
Verb: get
URL: https://service.eu.apiconnect.ibmcloud.com/gws/apigateway/api/123/
```
api management doesn't return error to know that there is an invalid combination to have both base path and operation path set to `/`
Contributor guide
Research direction
Reproduce the issue with the WSK CLI command `wsk api create / / get myaction`, then inspect the API v2 management path that handles the generated Swagger configuration. Confirm the behavior with `wsk api list -f`; done means the invalid combination of base path `/` and operation path `/` is rejected with an error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100