How to get all datas from postman API to elastic search using PHP

I got the json values in elasticsearch by using the below code:
use Elasticsearch\ClientBuilder;
require 'vendor/autoload.php';
$client = ClientBuilder::create()->build();

$params = [
'index' => 'my_index',
'id'    => 'my_id',
'body'  => [
'testField' => 'abc'


$response = $client->index($params);

I tried to get all the json values from postman api to elasticsearch using PHP, can you all please guide me to achieve the same.

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