400 The plain HTTP request was sent to HTTPS port

Hi, I'm using python client only (have not installed Elasticsearch on my machine) and I'm trying to query kibana and I get following error message:
Elasticsearch.exceptions.RequestError: RequestError(400, '\r\n400 The plain HTTP request was sent to HTTPS port
I don't have Elasticsearch conf file to update the ssl option to solve the issue.
any idea how I can resolve it?

Hi and welcome to our community

Could you elaborate what are you trying to query? Kibana REST interface? I guess it's more likely you're querying Elasticsearch? is there no way to configure the python client to use http?

Best,
Matthias

Thanks Matthias;
@matw
I'm trying to query Kibana to pull all the data in the specific index. I'm using Elasticsearch library to query Kibana.
I didn't find any settings in the python client to configure http. When I use postman, I can ignore https and query is successful but when I try to do the same thing using Elasticsearch, I get this error
just to emphasize that I did not install Elasticsearch and I'm just using python client
Thanks

I guess I found the answer: need to add these two flags when instantiating the Elasticsearch:
verify_certs=False, ssl_show_warn=False

1 Like

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