Run a Composition

Runs a query on a single composition and returns matching results.

Usage

Required ACL: search
1
2
3
4
5
6
7
8
9
10
use Algolia\AlgoliaSearch\Api\CompositionClient;

$client = CompositionClient::create('ALGOLIA_APPLICATION_ID', 'ALGOLIA_API_KEY');

$response = $client->search(
    'foo',
    ['params' => ['query' => 'batman',
    ],
    ],
);
Did you find this page helpful?