# Http-pooler issue . Cannot send API call

**URL:** https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096
**Category:** Logstash
**Tags:** elastic-stack-security, docker
**Created:** [October 10, 2019, 6:33pm UTC](https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096 "2019-10-10T18:33:33Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Xor44](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/xor44/32/55721_2.png) [@Xor44](https://discuss.elastic.co/u/Xor44)
#### Post date: [October 10, 2019, 6:33pm UTC](https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096/1 "2019-10-10T18:33:33Z")

</div>

Hi Folks ,  
I have some issue with my configuration . I'm not able to get data in my elastic cluster . I'm using the configuration below  
input {  
http\_poller {  
urls =\> {  
method =\> get  
headers =\> { X-xxx-APIToken =\> "apitoken" }  
url =\> "[https://xxxx.ne.xxx.com/api/xxx/v2/xxx-groups/?ssl=22](https://xxxx.ne.xxx.com/api/xxx/v2/xxx-groups/?ssl=22)"  
}  
truststore =\> "/usr/share/logstash/certs/logstash/arbor-lab.jks"  
truststore\_password =\> "${JKS\_TRUSTSTORE\_PASSWORD}"  
tags =\> ["xxx-api"]  
schedule =\> { cron =\> "\* \* \* \* \* UTC" }  
keepalive =\> false  
codec =\> "json"  
}  
}  
output {  
elasticsearch {  
hosts =\> ["[https://es01:9200](https://es01:9200)"]  
index =\> "arbor-metric-%{+YYYY.MM.dd}"  
ssl =\> true  
ssl\_certificate\_verification =\> true  
cacert =\> "/usr/share/logstash/certs/ca/ca.crt"  
index =\> "arbor-metric-%{+YYYY.MM.dd}"  
user =\> "elastic"  
password =\> "${ELASTIC\_PASSWORD}"  
ilm\_policy =\> "delete-after-120days"  
}  
}

Error that I get

> [2019-10-10T18:24:06,318][ERROR][logstash.agent] Failed to execute action {:action=\>LogStash::PipelineAction::Create/pipeline\_id:main, :exception=\>"LogStash::ConfigurationError", :message=\>"Exp  
> ected one of #, -, ", ', } at line 7, column 73 (byte 137) after input {\n http\_poller {\n\n urls =\> {\n\n\t\t\t\t\t\t\t method =\> get\n he  
> aders =\> { ", :backtrace=\>["/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:41:in `compile_imperative'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:49:in `compile\_graph'", "/us  
> r/share/logstash/logstash-core/lib/logstash/compiler.rb:11:in `block in compile_sources'", "org/jruby/RubyArray.java:2577:in `map'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:10:in `comp ile_sources'", "org/logstash/execution/AbstractPipelineExt.java:151:in `initialize'", "org/logstash/execution/JavaBasePipelineExt.java:47:in `initialize'", "/usr/share/logstash/logstash-core/lib/logstash/ java_pipeline.rb:24:in `initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline\_action/create.rb:36:in `execute'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:325:in `block in  
> converge\_state'"]}  
> [2019-10-10T18:24:09,356][ERROR][logstash.agent] Failed to execute action {:action=\>LogStash::PipelineAction::Create/pipeline\_id:main, :exception=\>"LogStash::ConfigurationError", :message=\>"Exp  
> ected one of #, -, ", ', } at line 7, column 73 (byte 137) after input {\n http\_poller {\n\n urls =\> {\n\n\t\t\t\t\t\t\t method =\> get\n

> logstash | [2019-10-10T18:31:52,870][ERROR][logstash.agent] Failed to execute action {:action=\>LogStash::PipelineAction::Create/pipeline\_id:main, :exception=\>"LogStash::ConfigurationError", :message=\>"Expected one of #, -, ", ', } at line 7, column 73 (byte 137) after input {\n http\_poller {\n\n urls =\> {\n\n\t\t\t\t\t\t\t method =\> get\n headers =\> { ", :backtrace=\>["/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:41:in `compile_imperative'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:49:in `compile\_graph'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:11:in `block in compile_sources'", "org/jruby/RubyArray.java:2577:in `map'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:10:in `compile_sources'", "org/logstash/execution/AbstractPipelineExt.java:151:in `initialize'", "org/logstash/execution/JavaBasePipelineExt.java:47:in `initialize'", "/usr/share/logstash/logstash-core/lib/logstash/java_pipeline.rb:24:in `initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline\_action/create.rb:36:in `execute'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:325:in `block in converge\_state'"]}

---

<div class="post-metadata">

### Author: ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)
#### Post date: [October 10, 2019, 7:03pm UTC](https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096/2 "2019-10-10T19:03:37Z")

</div>

> [@Xor44](#):
>
> http\_poller {  
> urls =\> {  
> method =\> get  
> headers =\> { X-xxx-APIToken =\> "apitoken" }  
> url =\> "[https://xxxx.ne.xxx.com/api/xxx/v2/xxx-groups/?ssl=22](https://xxxx.ne.xxx.com/api/xxx/v2/xxx-groups/?ssl=22)"  
> }

That should be

```
http_poller {
    urls => {
        randomname => {
            method => get
            headers => { X-xxx-APIToken => "apitoken" }
            url => "https://xxxx.ne.xxx.com/api/xxx/v2/xxx-groups/?ssl=22"
        }
    }

```

---

<div class="post-metadata">

### Author: ![Xor44](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/xor44/32/55721_2.png) [@Xor44](https://discuss.elastic.co/u/Xor44)
#### Post date: [October 10, 2019, 8:26pm UTC](https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096/3 "2019-10-10T20:26:27Z")

</div>

Thanks Badger , It's seem to be fixed

---

<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: [November 7, 2019, 8:26pm UTC](https://discuss.elastic.co/t/http-pooler-issue-cannot-send-api-call/203096/4 "2019-11-07T20:26:28Z")

</div>

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