When try request do elastic using php client response it's returning always null, I've try using "search", "get" methodos and not working, when a try use postman request it's working, sample code below
Request Status Code: 200
Body: Null
$client = ClientBuilder::create()
->setBasicAuthentication(
config('elasticsearch.user'),
config('elasticsearch.password')
)
->setHosts($app['config']->get('elasticsearch.hosts'))
->setCABundle(config('elasticsearch.certificate'))
->build();
$client->get([
'index' => 'company',
'id' => '31244951000130'
])->getBody->getContents();