multiValueQueryStringParameters typing #3640
Unanswered
gregggilbert-ivadolabs
asked this question in
Q&A
Replies: 1 comment 1 reply
-
Hey @gregggilbert-ivadolabs! We don't support this right now, but we have an issue opened to implement it: #3622 We hope to implement it in future releases. Thanks |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The current way to type query parameters is by using the
Annotated[str, Query()]
types, but what happens when we needmultiValueQueryStringParameters
such as a list of strings?By using
param_1: Annotated[list[str], Query]
, Swagger UI will reflect it correctly, but when you "Try It Out", the resulting query would be decoupled in the URL (e.g.,http://abc?param_1=value_1¶m_1=value_2
. This will raise an error because only one of theparam_1
values will be retained by PowerTools'Query()
, and an error will be raised saying thatparam_1
must be a list.Any idea how
multiValueQueryStringParameters
can be handled and typed?Beta Was this translation helpful? Give feedback.
All reactions