openwhisk-cli icon indicating copy to clipboard operation
openwhisk-cli copied to clipboard

API URL with templated parameters in query parameters parsed incorrectly.

Open jthomas opened this issue 6 years ago • 1 comments

User has reported an issue creating an API when including template parameters in both path and query URL parameters, e.g.

wsk api create -n "PersonalDetailsAPI" /getDetails /name/{myname}/age/{myage}?id={id} get getNameAction --response-type http -i

I don't think templates identifers in the query parameters are supported. However, the CLI fails to handle this edge case and parse the second path parameter incorrectly.

The path parameters in the swagger is created as follows...

{ "name": "myage}?id={id" }

Looks like the regex is failing to handle this example. Assume the second path parameter should be extracted correctly and anything after ? ignored?

jthomas avatar May 24 '18 09:05 jthomas

@mdeuser, FYI.

dubee avatar May 24 '18 13:05 dubee