# Plugin com mapa de rota curinga universal

**URL:** <https://meta.discourse.org/t/plugin-with-catch-all-wildcard-route-map/100348>\
**Category:** Development\
**Created:** [24 Outubro , 2018 12:12 UTC](https://meta.discourse.org/t/plugin-with-catch-all-wildcard-route-map/100348 "2018-10-24T12:12:09Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![kleinfreund](https://avatars.discourse-cdn.com/v4/letter/k/a6a055/32.png) [@kleinfreund](https://meta.discourse.org/u/kleinfreund)\
**Post date:** [30 Outubro , 2018 16:47 UTC](https://meta.discourse.org/t/plugin-with-catch-all-wildcard-route-map/100348/7 "2018-10-30T16:47:44Z")

</div>

I’m working on a plugin which works as a kind of reverse proxy. It allows users to specify routes which upon requesting are forwarded to another URL. The goal is to allow arbitrary web applications to be served within a Discourse instance.

For this, I essentially need to handle all routes that were defined by the plugin users. Therefor, I thought, it’s necessary to catch all requests that aren’t handled by Discourse. In a nutshell, I have unknown paths (they might have multiple segments, query parameters, etc.) that I all want to use the same route for. The route then makes an AJAX call in order to forward the request and retrieve the web application’s content.

I do realize that this is a complex plugin and use case.

* * *

So far, I wasn’t able to make this work with any combination of dynamic path segments and wildcard path segments I tried.

---

_[View the full topic](https://meta.discourse.org/t/plugin-with-catch-all-wildcard-route-map/100348)._
