-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
When marked as optional:
(def compiled
(contextual.http/compile-request '{:query-params {:timestamp ^:optional timestamp}, :method "get"}
{'timestamp (contextual.core/path :ts)}
{}
{:serialize-query-params true}))
(contextual.core/invoke compiled {:ts "2021-05-28 16:22:55.000+00 00"})
=> {:method "get", :url "?timestamp=2021-05-28 16:22:55.000+00 00"}
When not marked as optional:
(def compiled
(contextual.http/compile-request '{:query-params {:timestamp timestamp}, :method "get"}
{'timestamp (contextual.core/path :ts)}
{}
{:serialize-query-params true}))
(contextual.core/invoke compiled {:ts "2021-05-28 16:22:55.000+00 00"})
=> {:method "get", :url "?timestamp=2021-05-28%2016%3A22%3A55.000%2B00%20%20%2000"}
Metadata
Metadata
Assignees
Labels
No labels