Hey, I have a compojure-api app that has a lot of endpoints. Recently I have moved my token from the "Authorization" header to a "token" parameter on all request for unrelated reasons. However, now compojure-api is throwing Request validation failed exceptions on all my routes because token is a disallowed-key. The token parameter is handled by authentication middleware on ring and not by compojure-api. Is there a way to allow a parameter on all endpoints without writing it on all endpoints?
url? you can add the parameter definition into a context too, and it gets accumulated into leafs. Something like:
(api (context "/api/:token"  :path-parameter [token :- s/Int] (GET "/"  (ok token)) (POST "/"  (ok token))))
Oh whoops, I meant query parameter but I can modify this. Thanks for the help!