# Character "= " into a query parameter. How to escape it?

**URL:** <https://community.traefik.io/t/character-into-a-query-parameter-how-to-escape-it/15878>\
**Category:** Traefik v2\
**Tags:** docker\
**Created:** [September 23, 2022, 12:20pm UTC](https://community.traefik.io/t/character-into-a-query-parameter-how-to-escape-it/15878 "2022-09-23T12:20:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![r0m1CH](https://avatars.discourse-cdn.com/v4/letter/r/9de0a6/32.png) [@r0m1CH](https://community.traefik.io/u/r0m1CH)\
**Post date:** [September 23, 2022, 12:20pm UTC](https://community.traefik.io/t/character-into-a-query-parameter-how-to-escape-it/15878/1 "2022-09-23T12:20:51Z")

</div>

Hello,

I'm currently trying to route differently the web requests when an APIKey is given into the url with the parameter apikey. The api key ends with an = which is my problem.

Here what I use:

"traefik.http.routers.tools-api-rtr.rule=Host(`tools.$DOMAINNAME`) && PathPrefix(`/api`) && Query(`apikey`, `$tools_API_KEY`)"

But I end up with this error: "mux: number of parameters must be multiple of 2"

This is working well if I test with an api key which does not contain =

Unfortunately, I cannot find a way to escape this "special" character to make my route works and I cannot change the API as it's given by a tool and will always ends with =.

Anyone knows how to deal with this case ?

Thanks

---

<div class="post-metadata">

**Author:** ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)\
**Post date:** [September 23, 2022, 1:03pm UTC](https://community.traefik.io/t/character-into-a-query-parameter-how-to-escape-it/15878/2 "2022-09-23T13:03:07Z")

</div>

Hello,

the right syntax for the query parameter is `Query(`api=aaa`)`

> **[Traefik Routers Documentation - Traefik](https://doc.traefik.io/traefik/routing/routers/#rule)**
>
> In Traefik Proxy, a router is in charge of connecting incoming requests to the Services that can handle them. Read the technical documentation.

But there is a bug if you try to do `Query(`api=aa=a`)`, I fixed the bug in [fix: query parameter matching with equal by ldez · Pull Request #9369 · traefik/traefik · GitHub](https://github.com/traefik/traefik/pull/9369)

It will be a part of v2.8.6.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/containo/original/2X/b/bd81ebdb578656e76e56ff3cc3eed021d3ba132d.png) [@system](https://community.traefik.io/u/system)\
**Post date:** [September 26, 2022, 1:03pm UTC](https://community.traefik.io/t/character-into-a-query-parameter-how-to-escape-it/15878/3 "2022-09-26T13:03:30Z")

</div>

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.
