123456789101112131415161718192021222324 |
- // indices/put-mapping.asciidoc:114
- [source, php]
- ----
- $params = [
- 'index' => 'twitter-1',
- ];
- $response = $client->indices()->create($params);
- $params = [
- 'index' => 'twitter-2',
- ];
- $response = $client->indices()->create($params);
- $params = [
- 'index' => 'twitter-1,twitter-2',
- 'body' => [
- 'properties' => [
- 'user_name' => [
- 'type' => 'text',
- ],
- ],
- ],
- ];
- $response = $client->indices()->putMapping($params);
- ----
|