// docs/reindex.asciidoc:373

[source, php]
----
$params = [
    'body' => [
        'source' => [
            'index' => 'source',
            'query' => [
                'match' => [
                    'company' => 'cat',
                ],
            ],
        ],
        'dest' => [
            'index' => 'dest',
            'routing' => '=cat',
        ],
    ],
];
$response = $client->reindex($params);
----
