# Kibana route proxy

**URL:** <https://discuss.elastic.co/t/kibana-route-proxy/242582>\
**Category:** Kibana\
**Created:** [July 25, 2020, 1:02am UTC](https://discuss.elastic.co/t/kibana-route-proxy/242582 "2020-07-25T01:02:50Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tipham](https://avatars.discourse-cdn.com/v4/letter/t/e47774/32.png) [@tipham](https://discuss.elastic.co/u/tipham)\
**Post date:** [July 25, 2020, 1:02am UTC](https://discuss.elastic.co/t/kibana-route-proxy/242582/1 "2020-07-25T01:02:50Z")

</div>

I used to have this code to specify proxy for request handler in the legacy Kibana plugin.

```auto
    server.route({
        path: '/api/myplugin/{path*}',
        method: ['GET', 'POST', 'DELETE'],
        handler: {
          proxy: {
            mapUri: request => {
              return { uri: `${baseUri}/${request.params.path || ''}` };
            }
          }
        }
      });

```

How can I do this with new Kibana router?

---

<div class="post-metadata">

**Author:** ![tsullivan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsullivan/32/31077_2.png) [@tsullivan](https://discuss.elastic.co/u/tsullivan)\
**Post date:** [August 6, 2020, 7:02pm UTC](https://discuss.elastic.co/t/kibana-route-proxy/242582/2 "2020-08-06T19:02:12Z")

</div>

I think that was a feature of the Hapijs module, which developers no longer have direct access to:

> <https://github.com/hapijs/h2o2/blob/8f61fec26e7b3b4911c05c5e261bd06ff4ab00fd/API.md#hproxyoptions>

I don't think it's likely that support will be added for this in core Kibana since there are better tools for proxying web requests out there. But you might want to add an enhancement request over at: [https://github.com/elastic/kibana/issues/new](https://github.com/elastic/kibana/issues/new)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 3, 2020, 7:02pm UTC](https://discuss.elastic.co/t/kibana-route-proxy/242582/3 "2020-09-03T19:02:22Z")

</div>

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