# RestClient issue : Request denied by WatchGuard HTTP Proxy

**URL:** <https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383>\
**Category:** Elasticsearch\
**Created:** [May 29, 2017, 2:11am UTC](https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383 "2017-05-29T02:11:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jshraddha](https://avatars.discourse-cdn.com/v4/letter/j/e480ec/32.png) [@jshraddha](https://discuss.elastic.co/u/jshraddha)\
**Post date:** [May 29, 2017, 2:11am UTC](https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383/1 "2017-05-29T02:11:56Z")

</div>

Hi I am using elasticsearch rest client to push data to my amazon elasticsearch domain. It works perfect with host : localhost port: 9200

whereas when I change host to point my amazon elasticsearch endpoint with the port as "80" it gives me following error Request denied by WatchGuard HTTP Proxy

I am ingesting data through post request, same post requests works if I do that through postman but it does not work with elasticsearch RestClient java.

Following code snippet is used for the same :

HttpEntity entity = new NStringEntity(json,  
ContentType.APPLICATION\_JSON);  
restClient.performRequest("POST",  
url, Collections.\<String, String\> emptyMap(), entity);

---

<div class="post-metadata">

**Author:** ![thiago](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/thiago/32/32096_2.png) [@thiago](https://discuss.elastic.co/u/thiago)\
**Post date:** [May 29, 2017, 2:18am UTC](https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383/2 "2017-05-29T02:18:18Z")

</div>

This is an issue external to Elasticsearch. Moreover I would say you have a proxy in your network. You should be contacting your network administrator about this.

Cheers

---

<div class="post-metadata">

**Author:** ![jshraddha](https://avatars.discourse-cdn.com/v4/letter/j/e480ec/32.png) [@jshraddha](https://discuss.elastic.co/u/jshraddha)\
**Post date:** [May 29, 2017, 6:17am UTC](https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383/3 "2017-05-29T06:17:20Z")

</div>

Thanks thiago. Its the issue with proxy only.

---

<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:** [June 26, 2017, 6:17am UTC](https://discuss.elastic.co/t/restclient-issue-request-denied-by-watchguard-http-proxy/87383/4 "2017-06-26T06:17:56Z")

</div>

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