| 1 | package Search::Elasticsearch::Client::5_0::Role::API; | ||
| 2 | $Search::Elasticsearch::Client::5_0::Role::API::VERSION = '6.81'; | ||
| 3 | use Moo::Role; | ||
| 4 | with 'Search::Elasticsearch::Role::API'; | ||
| 5 | |||
| 6 | use Search::Elasticsearch::Util qw(throw); | ||
| 7 | use namespace::clean; | ||
| 8 | |||
| 9 | has 'api_version' => ( is => 'ro', default => '5_0' ); | ||
| 10 | |||
| 11 | our %API; | ||
| 12 | |||
| 13 | #=================================== | ||
| 14 | sub api { | ||
| 15 | #=================================== | ||
| 16 | my $name = $_[1] || return \%API; | ||
| 17 | return $API{$name} | ||
| 18 | || throw( 'Internal', "Unknown api name ($name)" ); | ||
| 19 | } | ||
| 20 | |||
| 21 | #=================================== | ||
| 22 | %API = ( | ||
| 23 | #=================================== | ||
| 24 | |||
| 25 | 'bulk.metadata' => { | ||
| 26 | params => { | ||
| 27 | '_index' => '_index', | ||
| 28 | 'index' => '_index', | ||
| 29 | '_type' => '_type', | ||
| 30 | 'type' => '_type', | ||
| 31 | '_id' => '_id', | ||
| 32 | 'id' => '_id', | ||
| 33 | 'pipeline' => 'pipeline', | ||
| 34 | 'routing' => 'routing', | ||
| 35 | '_routing' => 'routing', | ||
| 36 | 'parent' => 'parent', | ||
| 37 | '_parent' => 'parent', | ||
| 38 | 'timestamp' => 'timestamp', | ||
| 39 | '_timestamp' => 'timestamp', | ||
| 40 | 'ttl' => 'ttl', | ||
| 41 | '_ttl' => 'ttl', | ||
| 42 | 'version' => 'version', | ||
| 43 | '_version' => 'version', | ||
| 44 | 'version_type' => 'version_type', | ||
| 45 | '_version_type' => 'version_type' | ||
| 46 | } | ||
| 47 | }, | ||
| 48 | 'bulk.update' => { | ||
| 49 | params => [ | ||
| 50 | '_retry_on_conflict', '_source', | ||
| 51 | '_source_include', '_source_exclude', | ||
| 52 | 'detect_noop', 'doc', | ||
| 53 | 'doc_as_upsert', 'fields', | ||
| 54 | 'scripted_upsert', 'script', | ||
| 55 | 'upsert', | ||
| 56 | ] | ||
| 57 | }, | ||
| 58 | 'bulk.required' => { params => [ 'index', 'type' ] }, | ||
| 59 | |||
| 60 | #=== AUTOGEN - START === | ||
| 61 | |||
| 62 | 'bulk' => { | ||
| 63 | body => { required => 1 }, | ||
| 64 | doc => "docs-bulk", | ||
| 65 | method => "POST", | ||
| 66 | parts => { index => {}, type => {} }, | ||
| 67 | paths => [ | ||
| 68 | [ { index => 0, type => 1 }, "{index}", "{type}", "_bulk" ], | ||
| 69 | [ { index => 0 }, "{index}", "_bulk" ], | ||
| 70 | [ {}, "_bulk" ], | ||
| 71 | ], | ||
| 72 | qs => { | ||
| 73 | _source => "list", | ||
| 74 | _source_exclude => "list", | ||
| 75 | _source_include => "list", | ||
| 76 | error_trace => "boolean", | ||
| 77 | fields => "list", | ||
| 78 | filter_path => "list", | ||
| 79 | human => "boolean", | ||
| 80 | pipeline => "string", | ||
| 81 | refresh => "enum", | ||
| 82 | routing => "string", | ||
| 83 | timeout => "time", | ||
| 84 | wait_for_active_shards => "string", | ||
| 85 | }, | ||
| 86 | serialize => "bulk", | ||
| 87 | }, | ||
| 88 | |||
| 89 | 'clear_scroll' => { | ||
| 90 | body => {}, | ||
| 91 | doc => "search-request-scroll", | ||
| 92 | method => "DELETE", | ||
| 93 | parts => { scroll_id => { multi => 1 } }, | ||
| 94 | paths => [ | ||
| 95 | [ { scroll_id => 2 }, "_search", "scroll", "{scroll_id}" ], | ||
| 96 | [ {}, "_search", "scroll" ], | ||
| 97 | ], | ||
| 98 | qs => { | ||
| 99 | error_trace => "boolean", | ||
| 100 | filter_path => "list", | ||
| 101 | human => "boolean" | ||
| 102 | }, | ||
| 103 | }, | ||
| 104 | |||
| 105 | 'count' => { | ||
| 106 | body => {}, | ||
| 107 | doc => "search-count", | ||
| 108 | method => "POST", | ||
| 109 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 110 | paths => [ | ||
| 111 | [ { index => 0, type => 1 }, "{index}", "{type}", "_count" ], | ||
| 112 | [ { index => 0 }, "{index}", "_count" ], | ||
| 113 | [ {}, "_count" ], | ||
| 114 | ], | ||
| 115 | qs => { | ||
| 116 | allow_no_indices => "boolean", | ||
| 117 | analyze_wildcard => "boolean", | ||
| 118 | analyzer => "string", | ||
| 119 | default_operator => "enum", | ||
| 120 | df => "string", | ||
| 121 | error_trace => "boolean", | ||
| 122 | expand_wildcards => "enum", | ||
| 123 | filter_path => "list", | ||
| 124 | human => "boolean", | ||
| 125 | ignore_unavailable => "boolean", | ||
| 126 | lenient => "boolean", | ||
| 127 | min_score => "number", | ||
| 128 | preference => "string", | ||
| 129 | q => "string", | ||
| 130 | routing => "list", | ||
| 131 | terminate_after => "number", | ||
| 132 | }, | ||
| 133 | }, | ||
| 134 | |||
| 135 | 'count_percolate' => { | ||
| 136 | body => {}, | ||
| 137 | doc => "search-percolate", | ||
| 138 | parts => { | ||
| 139 | id => {}, | ||
| 140 | index => { required => 1 }, | ||
| 141 | type => { required => 1 } | ||
| 142 | }, | ||
| 143 | paths => [ | ||
| 144 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 145 | "{type}", "{id}", | ||
| 146 | "_percolate", "count", | ||
| 147 | ], | ||
| 148 | [ { index => 0, type => 1 }, "{index}", | ||
| 149 | "{type}", "_percolate", | ||
| 150 | "count", | ||
| 151 | ], | ||
| 152 | ], | ||
| 153 | qs => { | ||
| 154 | allow_no_indices => "boolean", | ||
| 155 | error_trace => "boolean", | ||
| 156 | expand_wildcards => "enum", | ||
| 157 | filter_path => "list", | ||
| 158 | human => "boolean", | ||
| 159 | ignore_unavailable => "boolean", | ||
| 160 | percolate_index => "string", | ||
| 161 | percolate_type => "string", | ||
| 162 | preference => "string", | ||
| 163 | routing => "list", | ||
| 164 | version => "number", | ||
| 165 | version_type => "enum", | ||
| 166 | }, | ||
| 167 | }, | ||
| 168 | |||
| 169 | 'create' => { | ||
| 170 | body => { required => 1 }, | ||
| 171 | doc => "docs-index_", | ||
| 172 | method => "PUT", | ||
| 173 | parts => { | ||
| 174 | id => { required => 1 }, | ||
| 175 | index => { required => 1 }, | ||
| 176 | type => { required => 1 }, | ||
| 177 | }, | ||
| 178 | paths => [ | ||
| 179 | [ { id => 2, index => 0, type => 1 }, | ||
| 180 | "{index}", "{type}", "{id}", "_create", | ||
| 181 | ], | ||
| 182 | ], | ||
| 183 | qs => { | ||
| 184 | error_trace => "boolean", | ||
| 185 | filter_path => "list", | ||
| 186 | human => "boolean", | ||
| 187 | parent => "string", | ||
| 188 | pipeline => "string", | ||
| 189 | refresh => "enum", | ||
| 190 | routing => "string", | ||
| 191 | timeout => "time", | ||
| 192 | timestamp => "time", | ||
| 193 | ttl => "time", | ||
| 194 | version => "number", | ||
| 195 | version_type => "enum", | ||
| 196 | wait_for_active_shards => "string", | ||
| 197 | }, | ||
| 198 | }, | ||
| 199 | |||
| 200 | 'delete' => { | ||
| 201 | doc => "docs-delete", | ||
| 202 | method => "DELETE", | ||
| 203 | parts => { | ||
| 204 | id => { required => 1 }, | ||
| 205 | index => { required => 1 }, | ||
| 206 | type => { required => 1 }, | ||
| 207 | }, | ||
| 208 | paths => [ | ||
| 209 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 210 | "{type}", "{id}" | ||
| 211 | ], | ||
| 212 | ], | ||
| 213 | qs => { | ||
| 214 | error_trace => "boolean", | ||
| 215 | filter_path => "list", | ||
| 216 | human => "boolean", | ||
| 217 | parent => "string", | ||
| 218 | refresh => "enum", | ||
| 219 | routing => "string", | ||
| 220 | timeout => "time", | ||
| 221 | version => "number", | ||
| 222 | version_type => "enum", | ||
| 223 | wait_for_active_shards => "string", | ||
| 224 | }, | ||
| 225 | }, | ||
| 226 | |||
| 227 | 'delete_by_query' => { | ||
| 228 | body => { required => 1 }, | ||
| 229 | doc => "docs-delete-by-query", | ||
| 230 | method => "POST", | ||
| 231 | parts => { | ||
| 232 | index => { multi => 1, required => 1 }, | ||
| 233 | type => { multi => 1 } | ||
| 234 | }, | ||
| 235 | paths => [ | ||
| 236 | [ { index => 0, type => 1 }, "{index}", | ||
| 237 | "{type}", "_delete_by_query", | ||
| 238 | ], | ||
| 239 | [ { index => 0 }, "{index}", "_delete_by_query" ], | ||
| 240 | ], | ||
| 241 | qs => { | ||
| 242 | _source => "list", | ||
| 243 | _source_exclude => "list", | ||
| 244 | _source_include => "list", | ||
| 245 | allow_no_indices => "boolean", | ||
| 246 | analyze_wildcard => "boolean", | ||
| 247 | analyzer => "string", | ||
| 248 | conflicts => "enum", | ||
| 249 | default_operator => "enum", | ||
| 250 | df => "string", | ||
| 251 | error_trace => "boolean", | ||
| 252 | expand_wildcards => "enum", | ||
| 253 | filter_path => "list", | ||
| 254 | from => "number", | ||
| 255 | human => "boolean", | ||
| 256 | ignore_unavailable => "boolean", | ||
| 257 | lenient => "boolean", | ||
| 258 | preference => "string", | ||
| 259 | q => "string", | ||
| 260 | refresh => "boolean", | ||
| 261 | request_cache => "boolean", | ||
| 262 | requests_per_second => "number", | ||
| 263 | routing => "list", | ||
| 264 | scroll => "time", | ||
| 265 | scroll_size => "number", | ||
| 266 | search_timeout => "time", | ||
| 267 | search_type => "enum", | ||
| 268 | size => "number", | ||
| 269 | slices => "number", | ||
| 270 | sort => "list", | ||
| 271 | stats => "list", | ||
| 272 | terminate_after => "number", | ||
| 273 | timeout => "time", | ||
| 274 | version => "boolean", | ||
| 275 | wait_for_active_shards => "string", | ||
| 276 | wait_for_completion => "boolean", | ||
| 277 | }, | ||
| 278 | }, | ||
| 279 | |||
| 280 | 'delete_script' => { | ||
| 281 | doc => "modules-scripting", | ||
| 282 | method => "DELETE", | ||
| 283 | parts => { id => { required => 1 }, lang => { required => 1 } }, | ||
| 284 | paths => [ | ||
| 285 | [ { id => 2, lang => 1 }, "_scripts", "{lang}", "{id}" ], | ||
| 286 | [ { lang => 1 }, "_scripts", "{lang}" ], | ||
| 287 | ], | ||
| 288 | qs => { | ||
| 289 | error_trace => "boolean", | ||
| 290 | filter_path => "list", | ||
| 291 | human => "boolean", | ||
| 292 | master_timeout => "time", | ||
| 293 | timeout => "time", | ||
| 294 | }, | ||
| 295 | }, | ||
| 296 | |||
| 297 | 'delete_template' => { | ||
| 298 | doc => "search-template", | ||
| 299 | method => "DELETE", | ||
| 300 | parts => { id => { required => 1 } }, | ||
| 301 | paths => [ [ { id => 2 }, "_search", "template", "{id}" ] ], | ||
| 302 | qs => { | ||
| 303 | error_trace => "boolean", | ||
| 304 | filter_path => "list", | ||
| 305 | human => "boolean" | ||
| 306 | }, | ||
| 307 | }, | ||
| 308 | |||
| 309 | 'exists' => { | ||
| 310 | doc => "docs-get", | ||
| 311 | method => "HEAD", | ||
| 312 | parts => { | ||
| 313 | id => { required => 1 }, | ||
| 314 | index => { required => 1 }, | ||
| 315 | type => { required => 1 }, | ||
| 316 | }, | ||
| 317 | paths => [ | ||
| 318 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 319 | "{type}", "{id}" | ||
| 320 | ], | ||
| 321 | ], | ||
| 322 | qs => { | ||
| 323 | _source => "list", | ||
| 324 | _source_exclude => "list", | ||
| 325 | _source_include => "list", | ||
| 326 | error_trace => "boolean", | ||
| 327 | filter_path => "list", | ||
| 328 | human => "boolean", | ||
| 329 | parent => "string", | ||
| 330 | preference => "string", | ||
| 331 | realtime => "boolean", | ||
| 332 | refresh => "boolean", | ||
| 333 | routing => "string", | ||
| 334 | stored_fields => "list", | ||
| 335 | version => "number", | ||
| 336 | version_type => "enum", | ||
| 337 | }, | ||
| 338 | }, | ||
| 339 | |||
| 340 | 'exists_source' => { | ||
| 341 | doc => "docs-get", | ||
| 342 | method => "HEAD", | ||
| 343 | parts => { | ||
| 344 | id => { required => 1 }, | ||
| 345 | index => { required => 1 }, | ||
| 346 | type => { required => 1 }, | ||
| 347 | }, | ||
| 348 | paths => [ | ||
| 349 | [ { id => 2, index => 0, type => 1 }, | ||
| 350 | "{index}", "{type}", "{id}", "_source", | ||
| 351 | ], | ||
| 352 | ], | ||
| 353 | qs => { | ||
| 354 | _source => "list", | ||
| 355 | _source_exclude => "list", | ||
| 356 | _source_include => "list", | ||
| 357 | error_trace => "boolean", | ||
| 358 | filter_path => "list", | ||
| 359 | human => "boolean", | ||
| 360 | parent => "string", | ||
| 361 | preference => "string", | ||
| 362 | realtime => "boolean", | ||
| 363 | refresh => "boolean", | ||
| 364 | routing => "string", | ||
| 365 | version => "number", | ||
| 366 | version_type => "enum", | ||
| 367 | }, | ||
| 368 | }, | ||
| 369 | |||
| 370 | 'explain' => { | ||
| 371 | body => {}, | ||
| 372 | doc => "search-explain", | ||
| 373 | parts => { | ||
| 374 | id => { required => 1 }, | ||
| 375 | index => { required => 1 }, | ||
| 376 | type => { required => 1 }, | ||
| 377 | }, | ||
| 378 | paths => [ | ||
| 379 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 380 | "{type}", "{id}", | ||
| 381 | "_explain", | ||
| 382 | ], | ||
| 383 | ], | ||
| 384 | qs => { | ||
| 385 | _source => "list", | ||
| 386 | _source_exclude => "list", | ||
| 387 | _source_include => "list", | ||
| 388 | analyze_wildcard => "boolean", | ||
| 389 | analyzer => "string", | ||
| 390 | default_operator => "enum", | ||
| 391 | df => "string", | ||
| 392 | error_trace => "boolean", | ||
| 393 | filter_path => "list", | ||
| 394 | human => "boolean", | ||
| 395 | lenient => "boolean", | ||
| 396 | parent => "string", | ||
| 397 | preference => "string", | ||
| 398 | q => "string", | ||
| 399 | routing => "string", | ||
| 400 | stored_fields => "list", | ||
| 401 | }, | ||
| 402 | }, | ||
| 403 | |||
| 404 | 'field_caps' => { | ||
| 405 | body => {}, | ||
| 406 | doc => "search-field-caps", | ||
| 407 | parts => { index => { multi => 1 } }, | ||
| 408 | paths => [ | ||
| 409 | [ { index => 0 }, "{index}", "_field_caps" ], | ||
| 410 | [ {}, "_field_caps" ], | ||
| 411 | ], | ||
| 412 | qs => { | ||
| 413 | allow_no_indices => "boolean", | ||
| 414 | error_trace => "boolean", | ||
| 415 | expand_wildcards => "enum", | ||
| 416 | fields => "list", | ||
| 417 | filter_path => "list", | ||
| 418 | human => "boolean", | ||
| 419 | ignore_unavailable => "boolean", | ||
| 420 | }, | ||
| 421 | }, | ||
| 422 | |||
| 423 | 'field_stats' => { | ||
| 424 | body => {}, | ||
| 425 | doc => "search-field-stats", | ||
| 426 | parts => { index => { multi => 1 } }, | ||
| 427 | paths => [ | ||
| 428 | [ { index => 0 }, "{index}", "_field_stats" ], | ||
| 429 | [ {}, "_field_stats" ], | ||
| 430 | ], | ||
| 431 | qs => { | ||
| 432 | allow_no_indices => "boolean", | ||
| 433 | error_trace => "boolean", | ||
| 434 | expand_wildcards => "enum", | ||
| 435 | fields => "list", | ||
| 436 | filter_path => "list", | ||
| 437 | human => "boolean", | ||
| 438 | ignore_unavailable => "boolean", | ||
| 439 | level => "enum", | ||
| 440 | }, | ||
| 441 | }, | ||
| 442 | |||
| 443 | 'get' => { | ||
| 444 | doc => "docs-get", | ||
| 445 | parts => { | ||
| 446 | id => { required => 1 }, | ||
| 447 | index => { required => 1 }, | ||
| 448 | type => { required => 1 }, | ||
| 449 | }, | ||
| 450 | paths => [ | ||
| 451 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 452 | "{type}", "{id}" | ||
| 453 | ], | ||
| 454 | ], | ||
| 455 | qs => { | ||
| 456 | _source => "list", | ||
| 457 | _source_exclude => "list", | ||
| 458 | _source_include => "list", | ||
| 459 | error_trace => "boolean", | ||
| 460 | filter_path => "list", | ||
| 461 | human => "boolean", | ||
| 462 | parent => "string", | ||
| 463 | preference => "string", | ||
| 464 | realtime => "boolean", | ||
| 465 | refresh => "boolean", | ||
| 466 | routing => "string", | ||
| 467 | stored_fields => "list", | ||
| 468 | version => "number", | ||
| 469 | version_type => "enum", | ||
| 470 | }, | ||
| 471 | }, | ||
| 472 | |||
| 473 | 'get_script' => { | ||
| 474 | doc => "modules-scripting", | ||
| 475 | parts => { id => { required => 1 }, lang => { required => 1 } }, | ||
| 476 | paths => [ | ||
| 477 | [ { id => 2, lang => 1 }, "_scripts", "{lang}", "{id}" ], | ||
| 478 | [ { lang => 1 }, "_scripts", "{lang}" ], | ||
| 479 | ], | ||
| 480 | qs => { | ||
| 481 | error_trace => "boolean", | ||
| 482 | filter_path => "list", | ||
| 483 | human => "boolean" | ||
| 484 | }, | ||
| 485 | }, | ||
| 486 | |||
| 487 | 'get_source' => { | ||
| 488 | doc => "docs-get", | ||
| 489 | parts => { | ||
| 490 | id => { required => 1 }, | ||
| 491 | index => { required => 1 }, | ||
| 492 | type => { required => 1 }, | ||
| 493 | }, | ||
| 494 | paths => [ | ||
| 495 | [ { id => 2, index => 0, type => 1 }, | ||
| 496 | "{index}", "{type}", "{id}", "_source", | ||
| 497 | ], | ||
| 498 | ], | ||
| 499 | qs => { | ||
| 500 | _source => "list", | ||
| 501 | _source_exclude => "list", | ||
| 502 | _source_include => "list", | ||
| 503 | error_trace => "boolean", | ||
| 504 | filter_path => "list", | ||
| 505 | human => "boolean", | ||
| 506 | parent => "string", | ||
| 507 | preference => "string", | ||
| 508 | realtime => "boolean", | ||
| 509 | refresh => "boolean", | ||
| 510 | routing => "string", | ||
| 511 | version => "number", | ||
| 512 | version_type => "enum", | ||
| 513 | }, | ||
| 514 | }, | ||
| 515 | |||
| 516 | 'get_template' => { | ||
| 517 | doc => "search-template", | ||
| 518 | parts => { id => { required => 1 } }, | ||
| 519 | paths => [ [ { id => 2 }, "_search", "template", "{id}" ] ], | ||
| 520 | qs => { | ||
| 521 | error_trace => "boolean", | ||
| 522 | filter_path => "list", | ||
| 523 | human => "boolean" | ||
| 524 | }, | ||
| 525 | }, | ||
| 526 | |||
| 527 | 'index' => { | ||
| 528 | body => { required => 1 }, | ||
| 529 | doc => "docs-index_", | ||
| 530 | method => "POST", | ||
| 531 | parts => { | ||
| 532 | id => {}, | ||
| 533 | index => { required => 1 }, | ||
| 534 | type => { required => 1 } | ||
| 535 | }, | ||
| 536 | paths => [ | ||
| 537 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 538 | "{type}", "{id}" | ||
| 539 | ], | ||
| 540 | [ { index => 0, type => 1 }, "{index}", "{type}" ], | ||
| 541 | ], | ||
| 542 | qs => { | ||
| 543 | error_trace => "boolean", | ||
| 544 | filter_path => "list", | ||
| 545 | human => "boolean", | ||
| 546 | op_type => "enum", | ||
| 547 | parent => "string", | ||
| 548 | pipeline => "string", | ||
| 549 | refresh => "enum", | ||
| 550 | routing => "string", | ||
| 551 | timeout => "time", | ||
| 552 | timestamp => "time", | ||
| 553 | ttl => "time", | ||
| 554 | version => "number", | ||
| 555 | version_type => "enum", | ||
| 556 | wait_for_active_shards => "string", | ||
| 557 | }, | ||
| 558 | }, | ||
| 559 | |||
| 560 | 'info' => { | ||
| 561 | doc => "", | ||
| 562 | parts => {}, | ||
| 563 | paths => [ [ {} ] ], | ||
| 564 | qs => { | ||
| 565 | error_trace => "boolean", | ||
| 566 | filter_path => "list", | ||
| 567 | human => "boolean" | ||
| 568 | }, | ||
| 569 | }, | ||
| 570 | |||
| 571 | 'mget' => { | ||
| 572 | body => { required => 1 }, | ||
| 573 | doc => "docs-multi-get", | ||
| 574 | parts => { index => {}, type => {} }, | ||
| 575 | paths => [ | ||
| 576 | [ { index => 0, type => 1 }, "{index}", "{type}", "_mget" ], | ||
| 577 | [ { index => 0 }, "{index}", "_mget" ], | ||
| 578 | [ {}, "_mget" ], | ||
| 579 | ], | ||
| 580 | qs => { | ||
| 581 | _source => "list", | ||
| 582 | _source_exclude => "list", | ||
| 583 | _source_include => "list", | ||
| 584 | error_trace => "boolean", | ||
| 585 | filter_path => "list", | ||
| 586 | human => "boolean", | ||
| 587 | preference => "string", | ||
| 588 | realtime => "boolean", | ||
| 589 | refresh => "boolean", | ||
| 590 | routing => "string", | ||
| 591 | stored_fields => "list", | ||
| 592 | }, | ||
| 593 | }, | ||
| 594 | |||
| 595 | 'mpercolate' => { | ||
| 596 | body => { required => 1 }, | ||
| 597 | doc => "search-percolate", | ||
| 598 | parts => { index => {}, type => {} }, | ||
| 599 | paths => [ | ||
| 600 | [ { index => 0, type => 1 }, "{index}", "{type}", "_mpercolate" ], | ||
| 601 | [ { index => 0 }, "{index}", "_mpercolate" ], | ||
| 602 | [ {}, "_mpercolate" ], | ||
| 603 | ], | ||
| 604 | qs => { | ||
| 605 | allow_no_indices => "boolean", | ||
| 606 | error_trace => "boolean", | ||
| 607 | expand_wildcards => "enum", | ||
| 608 | filter_path => "list", | ||
| 609 | human => "boolean", | ||
| 610 | ignore_unavailable => "boolean", | ||
| 611 | }, | ||
| 612 | serialize => "bulk", | ||
| 613 | }, | ||
| 614 | |||
| 615 | 'msearch' => { | ||
| 616 | body => { required => 1 }, | ||
| 617 | doc => "search-multi-search", | ||
| 618 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 619 | paths => [ | ||
| 620 | [ { index => 0, type => 1 }, "{index}", "{type}", "_msearch" ], | ||
| 621 | [ { index => 0 }, "{index}", "_msearch" ], | ||
| 622 | [ {}, "_msearch" ], | ||
| 623 | ], | ||
| 624 | qs => { | ||
| 625 | error_trace => "boolean", | ||
| 626 | filter_path => "list", | ||
| 627 | human => "boolean", | ||
| 628 | max_concurrent_searches => "number", | ||
| 629 | pre_filter_shard_size => "number", | ||
| 630 | search_type => "enum", | ||
| 631 | typed_keys => "boolean", | ||
| 632 | }, | ||
| 633 | serialize => "bulk", | ||
| 634 | }, | ||
| 635 | |||
| 636 | 'msearch_template' => { | ||
| 637 | body => { required => 1 }, | ||
| 638 | doc => "search-template", | ||
| 639 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 640 | paths => [ | ||
| 641 | [ { index => 0, type => 1 }, "{index}", | ||
| 642 | "{type}", "_msearch", | ||
| 643 | "template", | ||
| 644 | ], | ||
| 645 | [ { index => 0 }, "{index}", "_msearch", "template" ], | ||
| 646 | [ {}, "_msearch", "template" ], | ||
| 647 | ], | ||
| 648 | qs => { | ||
| 649 | error_trace => "boolean", | ||
| 650 | filter_path => "list", | ||
| 651 | human => "boolean", | ||
| 652 | max_concurrent_searches => "number", | ||
| 653 | search_type => "enum", | ||
| 654 | typed_keys => "boolean", | ||
| 655 | }, | ||
| 656 | serialize => "bulk", | ||
| 657 | }, | ||
| 658 | |||
| 659 | 'mtermvectors' => { | ||
| 660 | body => {}, | ||
| 661 | doc => "docs-multi-termvectors", | ||
| 662 | parts => { index => {}, type => {} }, | ||
| 663 | paths => [ | ||
| 664 | [ { index => 0, type => 1 }, "{index}", | ||
| 665 | "{type}", "_mtermvectors" | ||
| 666 | ], | ||
| 667 | [ { index => 0 }, "{index}", "_mtermvectors" ], | ||
| 668 | [ {}, "_mtermvectors" ], | ||
| 669 | ], | ||
| 670 | qs => { | ||
| 671 | error_trace => "boolean", | ||
| 672 | field_statistics => "boolean", | ||
| 673 | fields => "list", | ||
| 674 | filter_path => "list", | ||
| 675 | human => "boolean", | ||
| 676 | ids => "list", | ||
| 677 | offsets => "boolean", | ||
| 678 | parent => "string", | ||
| 679 | payloads => "boolean", | ||
| 680 | positions => "boolean", | ||
| 681 | preference => "string", | ||
| 682 | realtime => "boolean", | ||
| 683 | routing => "string", | ||
| 684 | term_statistics => "boolean", | ||
| 685 | version => "number", | ||
| 686 | version_type => "enum", | ||
| 687 | }, | ||
| 688 | }, | ||
| 689 | |||
| 690 | 'percolate' => { | ||
| 691 | body => {}, | ||
| 692 | doc => "search-percolate", | ||
| 693 | parts => { | ||
| 694 | id => {}, | ||
| 695 | index => { required => 1 }, | ||
| 696 | type => { required => 1 } | ||
| 697 | }, | ||
| 698 | paths => [ | ||
| 699 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 700 | "{type}", "{id}", | ||
| 701 | "_percolate", | ||
| 702 | ], | ||
| 703 | [ { index => 0, type => 1 }, "{index}", "{type}", "_percolate" ], | ||
| 704 | ], | ||
| 705 | qs => { | ||
| 706 | allow_no_indices => "boolean", | ||
| 707 | error_trace => "boolean", | ||
| 708 | expand_wildcards => "enum", | ||
| 709 | filter_path => "list", | ||
| 710 | human => "boolean", | ||
| 711 | ignore_unavailable => "boolean", | ||
| 712 | percolate_format => "enum", | ||
| 713 | percolate_index => "string", | ||
| 714 | percolate_preference => "string", | ||
| 715 | percolate_routing => "string", | ||
| 716 | percolate_type => "string", | ||
| 717 | preference => "string", | ||
| 718 | routing => "list", | ||
| 719 | version => "number", | ||
| 720 | version_type => "enum", | ||
| 721 | }, | ||
| 722 | }, | ||
| 723 | |||
| 724 | 'ping' => { | ||
| 725 | doc => "", | ||
| 726 | method => "HEAD", | ||
| 727 | parts => {}, | ||
| 728 | paths => [ [ {} ] ], | ||
| 729 | qs => { | ||
| 730 | error_trace => "boolean", | ||
| 731 | filter_path => "list", | ||
| 732 | human => "boolean" | ||
| 733 | }, | ||
| 734 | }, | ||
| 735 | |||
| 736 | 'put_script' => { | ||
| 737 | body => { required => 1 }, | ||
| 738 | doc => "modules-scripting", | ||
| 739 | method => "PUT", | ||
| 740 | parts => { id => { required => 1 }, lang => { required => 1 } }, | ||
| 741 | paths => [ | ||
| 742 | [ { id => 2, lang => 1 }, "_scripts", "{lang}", "{id}" ], | ||
| 743 | [ { lang => 1 }, "_scripts", "{lang}" ], | ||
| 744 | ], | ||
| 745 | qs => { | ||
| 746 | error_trace => "boolean", | ||
| 747 | filter_path => "list", | ||
| 748 | human => "boolean", | ||
| 749 | master_timeout => "time", | ||
| 750 | timeout => "time", | ||
| 751 | }, | ||
| 752 | }, | ||
| 753 | |||
| 754 | 'put_template' => { | ||
| 755 | body => { required => 1 }, | ||
| 756 | doc => "search-template", | ||
| 757 | method => "PUT", | ||
| 758 | parts => { id => { required => 1 } }, | ||
| 759 | paths => [ [ { id => 2 }, "_search", "template", "{id}" ] ], | ||
| 760 | qs => { | ||
| 761 | error_trace => "boolean", | ||
| 762 | filter_path => "list", | ||
| 763 | human => "boolean" | ||
| 764 | }, | ||
| 765 | }, | ||
| 766 | |||
| 767 | 'reindex' => { | ||
| 768 | body => { required => 1 }, | ||
| 769 | doc => "docs-reindex", | ||
| 770 | method => "POST", | ||
| 771 | parts => {}, | ||
| 772 | paths => [ [ {}, "_reindex" ] ], | ||
| 773 | qs => { | ||
| 774 | error_trace => "boolean", | ||
| 775 | filter_path => "list", | ||
| 776 | human => "boolean", | ||
| 777 | refresh => "boolean", | ||
| 778 | requests_per_second => "number", | ||
| 779 | slices => "number", | ||
| 780 | timeout => "time", | ||
| 781 | wait_for_active_shards => "string", | ||
| 782 | wait_for_completion => "boolean", | ||
| 783 | }, | ||
| 784 | }, | ||
| 785 | |||
| 786 | 'reindex_rethrottle' => { | ||
| 787 | doc => "docs-reindex", | ||
| 788 | method => "POST", | ||
| 789 | parts => { task_id => {} }, | ||
| 790 | paths => | ||
| 791 | [ [ { task_id => 1 }, "_reindex", "{task_id}", "_rethrottle" ] ], | ||
| 792 | qs => { | ||
| 793 | error_trace => "boolean", | ||
| 794 | filter_path => "list", | ||
| 795 | human => "boolean", | ||
| 796 | requests_per_second => "number", | ||
| 797 | }, | ||
| 798 | }, | ||
| 799 | |||
| 800 | 'render_search_template' => { | ||
| 801 | body => {}, | ||
| 802 | doc => "search-template", | ||
| 803 | parts => { id => {} }, | ||
| 804 | paths => [ | ||
| 805 | [ { id => 2 }, "_render", "template", "{id}" ], | ||
| 806 | [ {}, "_render", "template" ], | ||
| 807 | ], | ||
| 808 | qs => { | ||
| 809 | error_trace => "boolean", | ||
| 810 | filter_path => "list", | ||
| 811 | human => "boolean" | ||
| 812 | }, | ||
| 813 | }, | ||
| 814 | |||
| 815 | 'scroll' => { | ||
| 816 | body => {}, | ||
| 817 | doc => "search-request-scroll", | ||
| 818 | parts => { scroll_id => {} }, | ||
| 819 | paths => [ | ||
| 820 | [ { scroll_id => 2 }, "_search", "scroll", "{scroll_id}" ], | ||
| 821 | [ {}, "_search", "scroll" ], | ||
| 822 | ], | ||
| 823 | qs => { | ||
| 824 | error_trace => "boolean", | ||
| 825 | filter_path => "list", | ||
| 826 | human => "boolean", | ||
| 827 | scroll => "time", | ||
| 828 | }, | ||
| 829 | }, | ||
| 830 | |||
| 831 | 'search' => { | ||
| 832 | body => {}, | ||
| 833 | doc => "search-search", | ||
| 834 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 835 | paths => [ | ||
| 836 | [ { index => 0, type => 1 }, "{index}", "{type}", "_search" ], | ||
| 837 | [ { index => 0 }, "{index}", "_search" ], | ||
| 838 | [ {}, "_search" ], | ||
| 839 | ], | ||
| 840 | qs => { | ||
| 841 | _source => "list", | ||
| 842 | _source_exclude => "list", | ||
| 843 | _source_include => "list", | ||
| 844 | allow_no_indices => "boolean", | ||
| 845 | analyze_wildcard => "boolean", | ||
| 846 | analyzer => "string", | ||
| 847 | batched_reduce_size => "number", | ||
| 848 | default_operator => "enum", | ||
| 849 | df => "string", | ||
| 850 | docvalue_fields => "list", | ||
| 851 | error_trace => "boolean", | ||
| 852 | expand_wildcards => "enum", | ||
| 853 | explain => "boolean", | ||
| 854 | fielddata_fields => "list", | ||
| 855 | filter_path => "list", | ||
| 856 | from => "number", | ||
| 857 | human => "boolean", | ||
| 858 | ignore_unavailable => "boolean", | ||
| 859 | lenient => "boolean", | ||
| 860 | max_concurrent_shard_requests => "number", | ||
| 861 | pre_filter_shard_size => "number", | ||
| 862 | preference => "string", | ||
| 863 | q => "string", | ||
| 864 | request_cache => "boolean", | ||
| 865 | routing => "list", | ||
| 866 | scroll => "time", | ||
| 867 | search_type => "enum", | ||
| 868 | size => "number", | ||
| 869 | sort => "list", | ||
| 870 | stats => "list", | ||
| 871 | stored_fields => "list", | ||
| 872 | suggest_field => "string", | ||
| 873 | suggest_mode => "enum", | ||
| 874 | suggest_size => "number", | ||
| 875 | suggest_text => "string", | ||
| 876 | terminate_after => "number", | ||
| 877 | timeout => "time", | ||
| 878 | track_scores => "boolean", | ||
| 879 | typed_keys => "boolean", | ||
| 880 | version => "boolean", | ||
| 881 | }, | ||
| 882 | }, | ||
| 883 | |||
| 884 | 'search_shards' => { | ||
| 885 | doc => "search-shards", | ||
| 886 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 887 | paths => [ | ||
| 888 | [ { index => 0, type => 1 }, "{index}", | ||
| 889 | "{type}", "_search_shards", | ||
| 890 | ], | ||
| 891 | [ { index => 0 }, "{index}", "_search_shards" ], | ||
| 892 | [ {}, "_search_shards" ], | ||
| 893 | ], | ||
| 894 | qs => { | ||
| 895 | allow_no_indices => "boolean", | ||
| 896 | error_trace => "boolean", | ||
| 897 | expand_wildcards => "enum", | ||
| 898 | filter_path => "list", | ||
| 899 | human => "boolean", | ||
| 900 | ignore_unavailable => "boolean", | ||
| 901 | local => "boolean", | ||
| 902 | preference => "string", | ||
| 903 | routing => "string", | ||
| 904 | }, | ||
| 905 | }, | ||
| 906 | |||
| 907 | 'search_template' => { | ||
| 908 | body => {}, | ||
| 909 | doc => "search-template", | ||
| 910 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 911 | paths => [ | ||
| 912 | [ { index => 0, type => 1 }, "{index}", | ||
| 913 | "{type}", "_search", | ||
| 914 | "template", | ||
| 915 | ], | ||
| 916 | [ { index => 0 }, "{index}", "_search", "template" ], | ||
| 917 | [ {}, "_search", "template" ], | ||
| 918 | ], | ||
| 919 | qs => { | ||
| 920 | allow_no_indices => "boolean", | ||
| 921 | error_trace => "boolean", | ||
| 922 | expand_wildcards => "enum", | ||
| 923 | explain => "boolean", | ||
| 924 | filter_path => "list", | ||
| 925 | human => "boolean", | ||
| 926 | ignore_unavailable => "boolean", | ||
| 927 | preference => "string", | ||
| 928 | profile => "boolean", | ||
| 929 | routing => "list", | ||
| 930 | scroll => "time", | ||
| 931 | search_type => "enum", | ||
| 932 | typed_keys => "boolean", | ||
| 933 | }, | ||
| 934 | }, | ||
| 935 | |||
| 936 | 'suggest' => { | ||
| 937 | body => { required => 1 }, | ||
| 938 | doc => "search-suggesters", | ||
| 939 | method => "POST", | ||
| 940 | parts => { index => { multi => 1 } }, | ||
| 941 | paths => | ||
| 942 | [ [ { index => 0 }, "{index}", "_suggest" ], [ {}, "_suggest" ] ], | ||
| 943 | qs => { | ||
| 944 | allow_no_indices => "boolean", | ||
| 945 | error_trace => "boolean", | ||
| 946 | expand_wildcards => "enum", | ||
| 947 | filter_path => "list", | ||
| 948 | human => "boolean", | ||
| 949 | ignore_unavailable => "boolean", | ||
| 950 | preference => "string", | ||
| 951 | routing => "string", | ||
| 952 | }, | ||
| 953 | }, | ||
| 954 | |||
| 955 | 'termvectors' => { | ||
| 956 | body => {}, | ||
| 957 | doc => "docs-termvectors", | ||
| 958 | parts => { | ||
| 959 | id => {}, | ||
| 960 | index => { required => 1 }, | ||
| 961 | type => { required => 1 } | ||
| 962 | }, | ||
| 963 | paths => [ | ||
| 964 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 965 | "{type}", "{id}", | ||
| 966 | "_termvectors", | ||
| 967 | ], | ||
| 968 | [ { index => 0, type => 1 }, "{index}", "{type}", | ||
| 969 | "_termvectors" | ||
| 970 | ], | ||
| 971 | ], | ||
| 972 | qs => { | ||
| 973 | error_trace => "boolean", | ||
| 974 | field_statistics => "boolean", | ||
| 975 | fields => "list", | ||
| 976 | filter_path => "list", | ||
| 977 | human => "boolean", | ||
| 978 | offsets => "boolean", | ||
| 979 | parent => "string", | ||
| 980 | payloads => "boolean", | ||
| 981 | positions => "boolean", | ||
| 982 | preference => "string", | ||
| 983 | realtime => "boolean", | ||
| 984 | routing => "string", | ||
| 985 | term_statistics => "boolean", | ||
| 986 | version => "number", | ||
| 987 | version_type => "enum", | ||
| 988 | }, | ||
| 989 | }, | ||
| 990 | |||
| 991 | 'update' => { | ||
| 992 | body => {}, | ||
| 993 | doc => "docs-update", | ||
| 994 | method => "POST", | ||
| 995 | parts => { | ||
| 996 | id => { required => 1 }, | ||
| 997 | index => { required => 1 }, | ||
| 998 | type => { required => 1 }, | ||
| 999 | }, | ||
| 1000 | paths => [ | ||
| 1001 | [ { id => 2, index => 0, type => 1 }, | ||
| 1002 | "{index}", "{type}", "{id}", "_update", | ||
| 1003 | ], | ||
| 1004 | ], | ||
| 1005 | qs => { | ||
| 1006 | _source => "list", | ||
| 1007 | _source_exclude => "list", | ||
| 1008 | _source_include => "list", | ||
| 1009 | error_trace => "boolean", | ||
| 1010 | fields => "list", | ||
| 1011 | filter_path => "list", | ||
| 1012 | human => "boolean", | ||
| 1013 | lang => "string", | ||
| 1014 | parent => "string", | ||
| 1015 | refresh => "enum", | ||
| 1016 | retry_on_conflict => "number", | ||
| 1017 | routing => "string", | ||
| 1018 | timeout => "time", | ||
| 1019 | timestamp => "time", | ||
| 1020 | ttl => "time", | ||
| 1021 | version => "number", | ||
| 1022 | version_type => "enum", | ||
| 1023 | wait_for_active_shards => "string", | ||
| 1024 | }, | ||
| 1025 | }, | ||
| 1026 | |||
| 1027 | 'update_by_query' => { | ||
| 1028 | body => {}, | ||
| 1029 | doc => "docs-update-by-query", | ||
| 1030 | method => "POST", | ||
| 1031 | parts => { | ||
| 1032 | index => { multi => 1, required => 1 }, | ||
| 1033 | type => { multi => 1 } | ||
| 1034 | }, | ||
| 1035 | paths => [ | ||
| 1036 | [ { index => 0, type => 1 }, "{index}", | ||
| 1037 | "{type}", "_update_by_query", | ||
| 1038 | ], | ||
| 1039 | [ { index => 0 }, "{index}", "_update_by_query" ], | ||
| 1040 | ], | ||
| 1041 | qs => { | ||
| 1042 | _source => "list", | ||
| 1043 | _source_exclude => "list", | ||
| 1044 | _source_include => "list", | ||
| 1045 | allow_no_indices => "boolean", | ||
| 1046 | analyze_wildcard => "boolean", | ||
| 1047 | analyzer => "string", | ||
| 1048 | conflicts => "enum", | ||
| 1049 | default_operator => "enum", | ||
| 1050 | df => "string", | ||
| 1051 | error_trace => "boolean", | ||
| 1052 | expand_wildcards => "enum", | ||
| 1053 | filter_path => "list", | ||
| 1054 | from => "number", | ||
| 1055 | human => "boolean", | ||
| 1056 | ignore_unavailable => "boolean", | ||
| 1057 | lenient => "boolean", | ||
| 1058 | pipeline => "string", | ||
| 1059 | preference => "string", | ||
| 1060 | q => "string", | ||
| 1061 | refresh => "boolean", | ||
| 1062 | request_cache => "boolean", | ||
| 1063 | requests_per_second => "number", | ||
| 1064 | routing => "list", | ||
| 1065 | scroll => "time", | ||
| 1066 | scroll_size => "number", | ||
| 1067 | search_timeout => "time", | ||
| 1068 | search_type => "enum", | ||
| 1069 | size => "number", | ||
| 1070 | slices => "number", | ||
| 1071 | sort => "list", | ||
| 1072 | stats => "list", | ||
| 1073 | terminate_after => "number", | ||
| 1074 | timeout => "time", | ||
| 1075 | version => "boolean", | ||
| 1076 | version_type => "boolean", | ||
| 1077 | wait_for_active_shards => "string", | ||
| 1078 | wait_for_completion => "boolean", | ||
| 1079 | }, | ||
| 1080 | }, | ||
| 1081 | |||
| 1082 | 'cat.aliases' => { | ||
| 1083 | doc => "cat-alias", | ||
| 1084 | parts => { name => { multi => 1 } }, | ||
| 1085 | paths => [ | ||
| 1086 | [ { name => 2 }, "_cat", "aliases", "{name}" ], | ||
| 1087 | [ {}, "_cat", "aliases" ], | ||
| 1088 | ], | ||
| 1089 | qs => { | ||
| 1090 | error_trace => "boolean", | ||
| 1091 | filter_path => "list", | ||
| 1092 | format => "string", | ||
| 1093 | h => "list", | ||
| 1094 | help => "boolean", | ||
| 1095 | human => "boolean", | ||
| 1096 | local => "boolean", | ||
| 1097 | master_timeout => "time", | ||
| 1098 | s => "list", | ||
| 1099 | v => "boolean", | ||
| 1100 | }, | ||
| 1101 | }, | ||
| 1102 | |||
| 1103 | 'cat.allocation' => { | ||
| 1104 | doc => "cat-allocation", | ||
| 1105 | parts => { node_id => { multi => 1 } }, | ||
| 1106 | paths => [ | ||
| 1107 | [ { node_id => 2 }, "_cat", "allocation", "{node_id}" ], | ||
| 1108 | [ {}, "_cat", "allocation" ], | ||
| 1109 | ], | ||
| 1110 | qs => { | ||
| 1111 | bytes => "enum", | ||
| 1112 | error_trace => "boolean", | ||
| 1113 | filter_path => "list", | ||
| 1114 | format => "string", | ||
| 1115 | h => "list", | ||
| 1116 | help => "boolean", | ||
| 1117 | human => "boolean", | ||
| 1118 | local => "boolean", | ||
| 1119 | master_timeout => "time", | ||
| 1120 | s => "list", | ||
| 1121 | v => "boolean", | ||
| 1122 | }, | ||
| 1123 | }, | ||
| 1124 | |||
| 1125 | 'cat.count' => { | ||
| 1126 | doc => "cat-count", | ||
| 1127 | parts => { index => { multi => 1 } }, | ||
| 1128 | paths => [ | ||
| 1129 | [ { index => 2 }, "_cat", "count", "{index}" ], | ||
| 1130 | [ {}, "_cat", "count" ], | ||
| 1131 | ], | ||
| 1132 | qs => { | ||
| 1133 | error_trace => "boolean", | ||
| 1134 | filter_path => "list", | ||
| 1135 | format => "string", | ||
| 1136 | h => "list", | ||
| 1137 | help => "boolean", | ||
| 1138 | human => "boolean", | ||
| 1139 | local => "boolean", | ||
| 1140 | master_timeout => "time", | ||
| 1141 | s => "list", | ||
| 1142 | v => "boolean", | ||
| 1143 | }, | ||
| 1144 | }, | ||
| 1145 | |||
| 1146 | 'cat.fielddata' => { | ||
| 1147 | doc => "cat-fielddata", | ||
| 1148 | parts => { fields => { multi => 1 } }, | ||
| 1149 | paths => [ | ||
| 1150 | [ { fields => 2 }, "_cat", "fielddata", "{fields}" ], | ||
| 1151 | [ {}, "_cat", "fielddata" ], | ||
| 1152 | ], | ||
| 1153 | qs => { | ||
| 1154 | bytes => "enum", | ||
| 1155 | error_trace => "boolean", | ||
| 1156 | filter_path => "list", | ||
| 1157 | format => "string", | ||
| 1158 | h => "list", | ||
| 1159 | help => "boolean", | ||
| 1160 | human => "boolean", | ||
| 1161 | local => "boolean", | ||
| 1162 | master_timeout => "time", | ||
| 1163 | s => "list", | ||
| 1164 | v => "boolean", | ||
| 1165 | }, | ||
| 1166 | }, | ||
| 1167 | |||
| 1168 | 'cat.health' => { | ||
| 1169 | doc => "cat-health", | ||
| 1170 | parts => {}, | ||
| 1171 | paths => [ [ {}, "_cat", "health" ] ], | ||
| 1172 | qs => { | ||
| 1173 | error_trace => "boolean", | ||
| 1174 | filter_path => "list", | ||
| 1175 | format => "string", | ||
| 1176 | h => "list", | ||
| 1177 | help => "boolean", | ||
| 1178 | human => "boolean", | ||
| 1179 | local => "boolean", | ||
| 1180 | master_timeout => "time", | ||
| 1181 | s => "list", | ||
| 1182 | ts => "boolean", | ||
| 1183 | v => "boolean", | ||
| 1184 | }, | ||
| 1185 | }, | ||
| 1186 | |||
| 1187 | 'cat.help' => { | ||
| 1188 | doc => "cat", | ||
| 1189 | parts => {}, | ||
| 1190 | paths => [ [ {}, "_cat" ] ], | ||
| 1191 | qs => { | ||
| 1192 | error_trace => "boolean", | ||
| 1193 | filter_path => "list", | ||
| 1194 | help => "boolean", | ||
| 1195 | human => "boolean", | ||
| 1196 | s => "list", | ||
| 1197 | }, | ||
| 1198 | }, | ||
| 1199 | |||
| 1200 | 'cat.indices' => { | ||
| 1201 | doc => "cat-indices", | ||
| 1202 | parts => { index => { multi => 1 } }, | ||
| 1203 | paths => [ | ||
| 1204 | [ { index => 2 }, "_cat", "indices", "{index}" ], | ||
| 1205 | [ {}, "_cat", "indices" ], | ||
| 1206 | ], | ||
| 1207 | qs => { | ||
| 1208 | bytes => "enum", | ||
| 1209 | error_trace => "boolean", | ||
| 1210 | filter_path => "list", | ||
| 1211 | format => "string", | ||
| 1212 | h => "list", | ||
| 1213 | health => "enum", | ||
| 1214 | help => "boolean", | ||
| 1215 | human => "boolean", | ||
| 1216 | local => "boolean", | ||
| 1217 | master_timeout => "time", | ||
| 1218 | pri => "boolean", | ||
| 1219 | s => "list", | ||
| 1220 | v => "boolean", | ||
| 1221 | }, | ||
| 1222 | }, | ||
| 1223 | |||
| 1224 | 'cat.master' => { | ||
| 1225 | doc => "cat-master", | ||
| 1226 | parts => {}, | ||
| 1227 | paths => [ [ {}, "_cat", "master" ] ], | ||
| 1228 | qs => { | ||
| 1229 | error_trace => "boolean", | ||
| 1230 | filter_path => "list", | ||
| 1231 | format => "string", | ||
| 1232 | h => "list", | ||
| 1233 | help => "boolean", | ||
| 1234 | human => "boolean", | ||
| 1235 | local => "boolean", | ||
| 1236 | master_timeout => "time", | ||
| 1237 | s => "list", | ||
| 1238 | v => "boolean", | ||
| 1239 | }, | ||
| 1240 | }, | ||
| 1241 | |||
| 1242 | 'cat.nodeattrs' => { | ||
| 1243 | doc => "cat-nodeattrs", | ||
| 1244 | parts => {}, | ||
| 1245 | paths => [ [ {}, "_cat", "nodeattrs" ] ], | ||
| 1246 | qs => { | ||
| 1247 | error_trace => "boolean", | ||
| 1248 | filter_path => "list", | ||
| 1249 | format => "string", | ||
| 1250 | h => "list", | ||
| 1251 | help => "boolean", | ||
| 1252 | human => "boolean", | ||
| 1253 | local => "boolean", | ||
| 1254 | master_timeout => "time", | ||
| 1255 | s => "list", | ||
| 1256 | v => "boolean", | ||
| 1257 | }, | ||
| 1258 | }, | ||
| 1259 | |||
| 1260 | 'cat.nodes' => { | ||
| 1261 | doc => "cat-nodes", | ||
| 1262 | parts => {}, | ||
| 1263 | paths => [ [ {}, "_cat", "nodes" ] ], | ||
| 1264 | qs => { | ||
| 1265 | error_trace => "boolean", | ||
| 1266 | filter_path => "list", | ||
| 1267 | format => "string", | ||
| 1268 | full_id => "boolean", | ||
| 1269 | h => "list", | ||
| 1270 | help => "boolean", | ||
| 1271 | human => "boolean", | ||
| 1272 | local => "boolean", | ||
| 1273 | master_timeout => "time", | ||
| 1274 | s => "list", | ||
| 1275 | v => "boolean", | ||
| 1276 | }, | ||
| 1277 | }, | ||
| 1278 | |||
| 1279 | 'cat.pending_tasks' => { | ||
| 1280 | doc => "cat-pending-tasks", | ||
| 1281 | parts => {}, | ||
| 1282 | paths => [ [ {}, "_cat", "pending_tasks" ] ], | ||
| 1283 | qs => { | ||
| 1284 | error_trace => "boolean", | ||
| 1285 | filter_path => "list", | ||
| 1286 | format => "string", | ||
| 1287 | h => "list", | ||
| 1288 | help => "boolean", | ||
| 1289 | human => "boolean", | ||
| 1290 | local => "boolean", | ||
| 1291 | master_timeout => "time", | ||
| 1292 | s => "list", | ||
| 1293 | v => "boolean", | ||
| 1294 | }, | ||
| 1295 | }, | ||
| 1296 | |||
| 1297 | 'cat.plugins' => { | ||
| 1298 | doc => "cat-plugins", | ||
| 1299 | parts => {}, | ||
| 1300 | paths => [ [ {}, "_cat", "plugins" ] ], | ||
| 1301 | qs => { | ||
| 1302 | error_trace => "boolean", | ||
| 1303 | filter_path => "list", | ||
| 1304 | format => "string", | ||
| 1305 | h => "list", | ||
| 1306 | help => "boolean", | ||
| 1307 | human => "boolean", | ||
| 1308 | local => "boolean", | ||
| 1309 | master_timeout => "time", | ||
| 1310 | s => "list", | ||
| 1311 | v => "boolean", | ||
| 1312 | }, | ||
| 1313 | }, | ||
| 1314 | |||
| 1315 | 'cat.recovery' => { | ||
| 1316 | doc => "cat-recovery", | ||
| 1317 | parts => { index => { multi => 1 } }, | ||
| 1318 | paths => [ | ||
| 1319 | [ { index => 2 }, "_cat", "recovery", "{index}" ], | ||
| 1320 | [ {}, "_cat", "recovery" ], | ||
| 1321 | ], | ||
| 1322 | qs => { | ||
| 1323 | bytes => "enum", | ||
| 1324 | error_trace => "boolean", | ||
| 1325 | filter_path => "list", | ||
| 1326 | format => "string", | ||
| 1327 | h => "list", | ||
| 1328 | help => "boolean", | ||
| 1329 | human => "boolean", | ||
| 1330 | master_timeout => "time", | ||
| 1331 | s => "list", | ||
| 1332 | v => "boolean", | ||
| 1333 | }, | ||
| 1334 | }, | ||
| 1335 | |||
| 1336 | 'cat.repositories' => { | ||
| 1337 | doc => "cat-repositories", | ||
| 1338 | parts => {}, | ||
| 1339 | paths => [ [ {}, "_cat", "repositories" ] ], | ||
| 1340 | qs => { | ||
| 1341 | error_trace => "boolean", | ||
| 1342 | filter_path => "list", | ||
| 1343 | format => "string", | ||
| 1344 | h => "list", | ||
| 1345 | help => "boolean", | ||
| 1346 | human => "boolean", | ||
| 1347 | local => "boolean", | ||
| 1348 | master_timeout => "time", | ||
| 1349 | s => "list", | ||
| 1350 | v => "boolean", | ||
| 1351 | }, | ||
| 1352 | }, | ||
| 1353 | |||
| 1354 | 'cat.segments' => { | ||
| 1355 | doc => "cat-segments", | ||
| 1356 | parts => { index => { multi => 1 } }, | ||
| 1357 | paths => [ | ||
| 1358 | [ { index => 2 }, "_cat", "segments", "{index}" ], | ||
| 1359 | [ {}, "_cat", "segments" ], | ||
| 1360 | ], | ||
| 1361 | qs => { | ||
| 1362 | bytes => "enum", | ||
| 1363 | error_trace => "boolean", | ||
| 1364 | filter_path => "list", | ||
| 1365 | format => "string", | ||
| 1366 | h => "list", | ||
| 1367 | help => "boolean", | ||
| 1368 | human => "boolean", | ||
| 1369 | s => "list", | ||
| 1370 | v => "boolean", | ||
| 1371 | }, | ||
| 1372 | }, | ||
| 1373 | |||
| 1374 | 'cat.shards' => { | ||
| 1375 | doc => "cat-shards", | ||
| 1376 | parts => { index => { multi => 1 } }, | ||
| 1377 | paths => [ | ||
| 1378 | [ { index => 2 }, "_cat", "shards", "{index}" ], | ||
| 1379 | [ {}, "_cat", "shards" ], | ||
| 1380 | ], | ||
| 1381 | qs => { | ||
| 1382 | bytes => "enum", | ||
| 1383 | error_trace => "boolean", | ||
| 1384 | filter_path => "list", | ||
| 1385 | format => "string", | ||
| 1386 | h => "list", | ||
| 1387 | help => "boolean", | ||
| 1388 | human => "boolean", | ||
| 1389 | local => "boolean", | ||
| 1390 | master_timeout => "time", | ||
| 1391 | s => "list", | ||
| 1392 | v => "boolean", | ||
| 1393 | }, | ||
| 1394 | }, | ||
| 1395 | |||
| 1396 | 'cat.snapshots' => { | ||
| 1397 | doc => "cat-snapshots", | ||
| 1398 | parts => { repository => { multi => 1, required => 1 } }, | ||
| 1399 | paths => [ | ||
| 1400 | [ { repository => 2 }, "_cat", "snapshots", "{repository}" ], | ||
| 1401 | [ {}, "_cat", "snapshots" ], | ||
| 1402 | ], | ||
| 1403 | qs => { | ||
| 1404 | error_trace => "boolean", | ||
| 1405 | filter_path => "list", | ||
| 1406 | format => "string", | ||
| 1407 | h => "list", | ||
| 1408 | help => "boolean", | ||
| 1409 | human => "boolean", | ||
| 1410 | ignore_unavailable => "boolean", | ||
| 1411 | master_timeout => "time", | ||
| 1412 | s => "list", | ||
| 1413 | v => "boolean", | ||
| 1414 | }, | ||
| 1415 | }, | ||
| 1416 | |||
| 1417 | 'cat.tasks' => { | ||
| 1418 | doc => "tasks", | ||
| 1419 | parts => {}, | ||
| 1420 | paths => [ [ {}, "_cat", "tasks" ] ], | ||
| 1421 | qs => { | ||
| 1422 | actions => "list", | ||
| 1423 | detailed => "boolean", | ||
| 1424 | error_trace => "boolean", | ||
| 1425 | filter_path => "list", | ||
| 1426 | format => "string", | ||
| 1427 | h => "list", | ||
| 1428 | help => "boolean", | ||
| 1429 | human => "boolean", | ||
| 1430 | node_id => "list", | ||
| 1431 | parent_node => "string", | ||
| 1432 | parent_task => "number", | ||
| 1433 | s => "list", | ||
| 1434 | v => "boolean", | ||
| 1435 | }, | ||
| 1436 | }, | ||
| 1437 | |||
| 1438 | 'cat.templates' => { | ||
| 1439 | doc => "cat-templates", | ||
| 1440 | parts => { name => {} }, | ||
| 1441 | paths => [ | ||
| 1442 | [ { name => 2 }, "_cat", "templates", "{name}" ], | ||
| 1443 | [ {}, "_cat", "templates" ], | ||
| 1444 | ], | ||
| 1445 | qs => { | ||
| 1446 | error_trace => "boolean", | ||
| 1447 | filter_path => "list", | ||
| 1448 | format => "string", | ||
| 1449 | h => "list", | ||
| 1450 | help => "boolean", | ||
| 1451 | human => "boolean", | ||
| 1452 | local => "boolean", | ||
| 1453 | master_timeout => "time", | ||
| 1454 | s => "list", | ||
| 1455 | v => "boolean", | ||
| 1456 | }, | ||
| 1457 | }, | ||
| 1458 | |||
| 1459 | 'cat.thread_pool' => { | ||
| 1460 | doc => "cat-thread-pool", | ||
| 1461 | parts => { thread_pool_patterns => { multi => 1 } }, | ||
| 1462 | paths => [ | ||
| 1463 | [ { thread_pool_patterns => 2 }, "_cat", | ||
| 1464 | "thread_pool", "{thread_pool_patterns}", | ||
| 1465 | ], | ||
| 1466 | [ {}, "_cat", "thread_pool" ], | ||
| 1467 | ], | ||
| 1468 | qs => { | ||
| 1469 | error_trace => "boolean", | ||
| 1470 | filter_path => "list", | ||
| 1471 | format => "string", | ||
| 1472 | h => "list", | ||
| 1473 | help => "boolean", | ||
| 1474 | human => "boolean", | ||
| 1475 | local => "boolean", | ||
| 1476 | master_timeout => "time", | ||
| 1477 | s => "list", | ||
| 1478 | size => "enum", | ||
| 1479 | v => "boolean", | ||
| 1480 | }, | ||
| 1481 | }, | ||
| 1482 | |||
| 1483 | 'cluster.allocation_explain' => { | ||
| 1484 | body => {}, | ||
| 1485 | doc => "cluster-allocation-explain", | ||
| 1486 | parts => {}, | ||
| 1487 | paths => [ [ {}, "_cluster", "allocation", "explain" ] ], | ||
| 1488 | qs => { | ||
| 1489 | error_trace => "boolean", | ||
| 1490 | filter_path => "list", | ||
| 1491 | human => "boolean", | ||
| 1492 | include_disk_info => "boolean", | ||
| 1493 | include_yes_decisions => "boolean", | ||
| 1494 | }, | ||
| 1495 | }, | ||
| 1496 | |||
| 1497 | 'cluster.get_settings' => { | ||
| 1498 | doc => "cluster-update-settings", | ||
| 1499 | parts => {}, | ||
| 1500 | paths => [ [ {}, "_cluster", "settings" ] ], | ||
| 1501 | qs => { | ||
| 1502 | error_trace => "boolean", | ||
| 1503 | filter_path => "list", | ||
| 1504 | flat_settings => "boolean", | ||
| 1505 | human => "boolean", | ||
| 1506 | include_defaults => "boolean", | ||
| 1507 | master_timeout => "time", | ||
| 1508 | timeout => "time", | ||
| 1509 | }, | ||
| 1510 | }, | ||
| 1511 | |||
| 1512 | 'cluster.health' => { | ||
| 1513 | doc => "cluster-health", | ||
| 1514 | parts => { index => { multi => 1 } }, | ||
| 1515 | paths => [ | ||
| 1516 | [ { index => 2 }, "_cluster", "health", "{index}" ], | ||
| 1517 | [ {}, "_cluster", "health" ], | ||
| 1518 | ], | ||
| 1519 | qs => { | ||
| 1520 | error_trace => "boolean", | ||
| 1521 | filter_path => "list", | ||
| 1522 | human => "boolean", | ||
| 1523 | level => "enum", | ||
| 1524 | local => "boolean", | ||
| 1525 | master_timeout => "time", | ||
| 1526 | timeout => "time", | ||
| 1527 | wait_for_active_shards => "string", | ||
| 1528 | wait_for_events => "enum", | ||
| 1529 | wait_for_no_relocating_shards => "boolean", | ||
| 1530 | wait_for_nodes => "string", | ||
| 1531 | wait_for_status => "enum", | ||
| 1532 | }, | ||
| 1533 | }, | ||
| 1534 | |||
| 1535 | 'cluster.pending_tasks' => { | ||
| 1536 | doc => "cluster-pending", | ||
| 1537 | parts => {}, | ||
| 1538 | paths => [ [ {}, "_cluster", "pending_tasks" ] ], | ||
| 1539 | qs => { | ||
| 1540 | error_trace => "boolean", | ||
| 1541 | filter_path => "list", | ||
| 1542 | human => "boolean", | ||
| 1543 | local => "boolean", | ||
| 1544 | master_timeout => "time", | ||
| 1545 | }, | ||
| 1546 | }, | ||
| 1547 | |||
| 1548 | 'cluster.put_settings' => { | ||
| 1549 | body => {}, | ||
| 1550 | doc => "cluster-update-settings", | ||
| 1551 | method => "PUT", | ||
| 1552 | parts => {}, | ||
| 1553 | paths => [ [ {}, "_cluster", "settings" ] ], | ||
| 1554 | qs => { | ||
| 1555 | error_trace => "boolean", | ||
| 1556 | filter_path => "list", | ||
| 1557 | flat_settings => "boolean", | ||
| 1558 | human => "boolean", | ||
| 1559 | master_timeout => "time", | ||
| 1560 | timeout => "time", | ||
| 1561 | }, | ||
| 1562 | }, | ||
| 1563 | |||
| 1564 | 'cluster.reroute' => { | ||
| 1565 | body => {}, | ||
| 1566 | doc => "cluster-reroute", | ||
| 1567 | method => "POST", | ||
| 1568 | parts => {}, | ||
| 1569 | paths => [ [ {}, "_cluster", "reroute" ] ], | ||
| 1570 | qs => { | ||
| 1571 | dry_run => "boolean", | ||
| 1572 | error_trace => "boolean", | ||
| 1573 | explain => "boolean", | ||
| 1574 | filter_path => "list", | ||
| 1575 | human => "boolean", | ||
| 1576 | master_timeout => "time", | ||
| 1577 | metric => "list", | ||
| 1578 | retry_failed => "boolean", | ||
| 1579 | timeout => "time", | ||
| 1580 | }, | ||
| 1581 | }, | ||
| 1582 | |||
| 1583 | 'cluster.state' => { | ||
| 1584 | doc => "cluster-state", | ||
| 1585 | parts => { index => { multi => 1 }, metric => { multi => 1 } }, | ||
| 1586 | paths => [ | ||
| 1587 | [ { index => 3, metric => 2 }, "_cluster", | ||
| 1588 | "state", "{metric}", | ||
| 1589 | "{index}", | ||
| 1590 | ], | ||
| 1591 | [ { metric => 2 }, "_cluster", "state", "{metric}" ], | ||
| 1592 | [ {}, "_cluster", "state" ], | ||
| 1593 | ], | ||
| 1594 | qs => { | ||
| 1595 | allow_no_indices => "boolean", | ||
| 1596 | error_trace => "boolean", | ||
| 1597 | expand_wildcards => "enum", | ||
| 1598 | filter_path => "list", | ||
| 1599 | flat_settings => "boolean", | ||
| 1600 | human => "boolean", | ||
| 1601 | ignore_unavailable => "boolean", | ||
| 1602 | local => "boolean", | ||
| 1603 | master_timeout => "time", | ||
| 1604 | }, | ||
| 1605 | }, | ||
| 1606 | |||
| 1607 | 'cluster.stats' => { | ||
| 1608 | doc => "cluster-stats", | ||
| 1609 | parts => { node_id => { multi => 1 } }, | ||
| 1610 | paths => [ | ||
| 1611 | [ { node_id => 3 }, "_cluster", "stats", "nodes", "{node_id}" ], | ||
| 1612 | [ {}, "_cluster", "stats" ], | ||
| 1613 | ], | ||
| 1614 | qs => { | ||
| 1615 | error_trace => "boolean", | ||
| 1616 | filter_path => "list", | ||
| 1617 | flat_settings => "boolean", | ||
| 1618 | human => "boolean", | ||
| 1619 | timeout => "time", | ||
| 1620 | }, | ||
| 1621 | }, | ||
| 1622 | |||
| 1623 | 'indices.analyze' => { | ||
| 1624 | body => {}, | ||
| 1625 | doc => "indices-analyze", | ||
| 1626 | parts => { index => {} }, | ||
| 1627 | paths => | ||
| 1628 | [ [ { index => 0 }, "{index}", "_analyze" ], [ {}, "_analyze" ] ], | ||
| 1629 | qs => { | ||
| 1630 | analyzer => "string", | ||
| 1631 | attributes => "list", | ||
| 1632 | char_filter => "list", | ||
| 1633 | error_trace => "boolean", | ||
| 1634 | explain => "boolean", | ||
| 1635 | field => "string", | ||
| 1636 | filter => "list", | ||
| 1637 | filter_path => "list", | ||
| 1638 | format => "enum", | ||
| 1639 | human => "boolean", | ||
| 1640 | prefer_local => "boolean", | ||
| 1641 | text => "list", | ||
| 1642 | tokenizer => "string", | ||
| 1643 | }, | ||
| 1644 | }, | ||
| 1645 | |||
| 1646 | 'indices.clear_cache' => { | ||
| 1647 | doc => "indices-clearcache", | ||
| 1648 | method => "POST", | ||
| 1649 | parts => { index => { multi => 1 } }, | ||
| 1650 | paths => [ | ||
| 1651 | [ { index => 0 }, "{index}", "_cache", "clear" ], | ||
| 1652 | [ {}, "_cache", "clear" ], | ||
| 1653 | ], | ||
| 1654 | qs => { | ||
| 1655 | allow_no_indices => "boolean", | ||
| 1656 | error_trace => "boolean", | ||
| 1657 | expand_wildcards => "enum", | ||
| 1658 | fielddata => "boolean", | ||
| 1659 | fields => "list", | ||
| 1660 | filter_path => "list", | ||
| 1661 | human => "boolean", | ||
| 1662 | ignore_unavailable => "boolean", | ||
| 1663 | query => "boolean", | ||
| 1664 | recycler => "boolean", | ||
| 1665 | request => "boolean", | ||
| 1666 | request_cache => "boolean", | ||
| 1667 | }, | ||
| 1668 | }, | ||
| 1669 | |||
| 1670 | 'indices.close' => { | ||
| 1671 | doc => "indices-open-close", | ||
| 1672 | method => "POST", | ||
| 1673 | parts => { index => { multi => 1, required => 1 } }, | ||
| 1674 | paths => [ [ { index => 0 }, "{index}", "_close" ] ], | ||
| 1675 | qs => { | ||
| 1676 | allow_no_indices => "boolean", | ||
| 1677 | error_trace => "boolean", | ||
| 1678 | expand_wildcards => "enum", | ||
| 1679 | filter_path => "list", | ||
| 1680 | human => "boolean", | ||
| 1681 | ignore_unavailable => "boolean", | ||
| 1682 | master_timeout => "time", | ||
| 1683 | timeout => "time", | ||
| 1684 | }, | ||
| 1685 | }, | ||
| 1686 | |||
| 1687 | 'indices.create' => { | ||
| 1688 | body => {}, | ||
| 1689 | doc => "indices-create-index", | ||
| 1690 | method => "PUT", | ||
| 1691 | parts => { index => { required => 1 } }, | ||
| 1692 | paths => [ [ { index => 0 }, "{index}" ] ], | ||
| 1693 | qs => { | ||
| 1694 | error_trace => "boolean", | ||
| 1695 | filter_path => "list", | ||
| 1696 | human => "boolean", | ||
| 1697 | master_timeout => "time", | ||
| 1698 | timeout => "time", | ||
| 1699 | update_all_types => "boolean", | ||
| 1700 | wait_for_active_shards => "string", | ||
| 1701 | }, | ||
| 1702 | }, | ||
| 1703 | |||
| 1704 | 'indices.delete' => { | ||
| 1705 | doc => "indices-delete-index", | ||
| 1706 | method => "DELETE", | ||
| 1707 | parts => { index => { multi => 1, required => 1 } }, | ||
| 1708 | paths => [ [ { index => 0 }, "{index}" ] ], | ||
| 1709 | qs => { | ||
| 1710 | error_trace => "boolean", | ||
| 1711 | filter_path => "list", | ||
| 1712 | human => "boolean", | ||
| 1713 | master_timeout => "time", | ||
| 1714 | timeout => "time", | ||
| 1715 | }, | ||
| 1716 | }, | ||
| 1717 | |||
| 1718 | 'indices.delete_alias' => { | ||
| 1719 | doc => "indices-aliases", | ||
| 1720 | method => "DELETE", | ||
| 1721 | parts => { | ||
| 1722 | index => { multi => 1, required => 1 }, | ||
| 1723 | name => { multi => 1, required => 1 }, | ||
| 1724 | }, | ||
| 1725 | paths => | ||
| 1726 | [ [ { index => 0, name => 2 }, "{index}", "_alias", "{name}" ] ], | ||
| 1727 | qs => { | ||
| 1728 | error_trace => "boolean", | ||
| 1729 | filter_path => "list", | ||
| 1730 | human => "boolean", | ||
| 1731 | master_timeout => "time", | ||
| 1732 | timeout => "time", | ||
| 1733 | }, | ||
| 1734 | }, | ||
| 1735 | |||
| 1736 | 'indices.delete_template' => { | ||
| 1737 | doc => "indices-templates", | ||
| 1738 | method => "DELETE", | ||
| 1739 | parts => { name => { required => 1 } }, | ||
| 1740 | paths => [ [ { name => 1 }, "_template", "{name}" ] ], | ||
| 1741 | qs => { | ||
| 1742 | error_trace => "boolean", | ||
| 1743 | filter_path => "list", | ||
| 1744 | human => "boolean", | ||
| 1745 | master_timeout => "time", | ||
| 1746 | timeout => "time", | ||
| 1747 | }, | ||
| 1748 | }, | ||
| 1749 | |||
| 1750 | 'indices.exists' => { | ||
| 1751 | doc => "indices-exists", | ||
| 1752 | method => "HEAD", | ||
| 1753 | parts => { index => { multi => 1, required => 1 } }, | ||
| 1754 | paths => [ [ { index => 0 }, "{index}" ] ], | ||
| 1755 | qs => { | ||
| 1756 | allow_no_indices => "boolean", | ||
| 1757 | error_trace => "boolean", | ||
| 1758 | expand_wildcards => "enum", | ||
| 1759 | filter_path => "list", | ||
| 1760 | flat_settings => "boolean", | ||
| 1761 | human => "boolean", | ||
| 1762 | ignore_unavailable => "boolean", | ||
| 1763 | include_defaults => "boolean", | ||
| 1764 | local => "boolean", | ||
| 1765 | }, | ||
| 1766 | }, | ||
| 1767 | |||
| 1768 | 'indices.exists_alias' => { | ||
| 1769 | doc => "indices-aliases", | ||
| 1770 | method => "HEAD", | ||
| 1771 | parts => { index => { multi => 1 }, name => { multi => 1 } }, | ||
| 1772 | paths => [ | ||
| 1773 | [ { index => 0, name => 2 }, "{index}", "_alias", "{name}" ], | ||
| 1774 | [ { name => 1 }, "_alias", "{name}" ], | ||
| 1775 | ], | ||
| 1776 | qs => { | ||
| 1777 | allow_no_indices => "boolean", | ||
| 1778 | error_trace => "boolean", | ||
| 1779 | expand_wildcards => "enum", | ||
| 1780 | filter_path => "list", | ||
| 1781 | human => "boolean", | ||
| 1782 | ignore_unavailable => "boolean", | ||
| 1783 | local => "boolean", | ||
| 1784 | }, | ||
| 1785 | }, | ||
| 1786 | |||
| 1787 | 'indices.exists_template' => { | ||
| 1788 | doc => "indices-templates", | ||
| 1789 | method => "HEAD", | ||
| 1790 | parts => { name => { multi => 1, required => 1 } }, | ||
| 1791 | paths => [ [ { name => 1 }, "_template", "{name}" ] ], | ||
| 1792 | qs => { | ||
| 1793 | error_trace => "boolean", | ||
| 1794 | filter_path => "list", | ||
| 1795 | flat_settings => "boolean", | ||
| 1796 | human => "boolean", | ||
| 1797 | local => "boolean", | ||
| 1798 | master_timeout => "time", | ||
| 1799 | }, | ||
| 1800 | }, | ||
| 1801 | |||
| 1802 | 'indices.exists_type' => { | ||
| 1803 | doc => "indices-types-exists", | ||
| 1804 | method => "HEAD", | ||
| 1805 | parts => { | ||
| 1806 | index => { multi => 1, required => 1 }, | ||
| 1807 | type => { multi => 1, required => 1 }, | ||
| 1808 | }, | ||
| 1809 | paths => [ | ||
| 1810 | [ { index => 0, type => 2 }, "{index}", "_mapping", "{type}" ] | ||
| 1811 | ], | ||
| 1812 | qs => { | ||
| 1813 | allow_no_indices => "boolean", | ||
| 1814 | error_trace => "boolean", | ||
| 1815 | expand_wildcards => "enum", | ||
| 1816 | filter_path => "list", | ||
| 1817 | human => "boolean", | ||
| 1818 | ignore_unavailable => "boolean", | ||
| 1819 | local => "boolean", | ||
| 1820 | }, | ||
| 1821 | }, | ||
| 1822 | |||
| 1823 | 'indices.flush' => { | ||
| 1824 | doc => "indices-flush", | ||
| 1825 | method => "POST", | ||
| 1826 | parts => { index => { multi => 1 } }, | ||
| 1827 | paths => | ||
| 1828 | [ [ { index => 0 }, "{index}", "_flush" ], [ {}, "_flush" ] ], | ||
| 1829 | qs => { | ||
| 1830 | allow_no_indices => "boolean", | ||
| 1831 | error_trace => "boolean", | ||
| 1832 | expand_wildcards => "enum", | ||
| 1833 | filter_path => "list", | ||
| 1834 | force => "boolean", | ||
| 1835 | human => "boolean", | ||
| 1836 | ignore_unavailable => "boolean", | ||
| 1837 | wait_if_ongoing => "boolean", | ||
| 1838 | }, | ||
| 1839 | }, | ||
| 1840 | |||
| 1841 | 'indices.flush_synced' => { | ||
| 1842 | doc => "indices-synced-flush", | ||
| 1843 | method => "POST", | ||
| 1844 | parts => { index => { multi => 1 } }, | ||
| 1845 | paths => [ | ||
| 1846 | [ { index => 0 }, "{index}", "_flush", "synced" ], | ||
| 1847 | [ {}, "_flush", "synced" ], | ||
| 1848 | ], | ||
| 1849 | qs => { | ||
| 1850 | allow_no_indices => "boolean", | ||
| 1851 | error_trace => "boolean", | ||
| 1852 | expand_wildcards => "enum", | ||
| 1853 | filter_path => "list", | ||
| 1854 | human => "boolean", | ||
| 1855 | ignore_unavailable => "boolean", | ||
| 1856 | }, | ||
| 1857 | }, | ||
| 1858 | |||
| 1859 | 'indices.forcemerge' => { | ||
| 1860 | doc => "indices-forcemerge", | ||
| 1861 | method => "POST", | ||
| 1862 | parts => { index => { multi => 1 } }, | ||
| 1863 | paths => [ | ||
| 1864 | [ { index => 0 }, "{index}", "_forcemerge" ], | ||
| 1865 | [ {}, "_forcemerge" ], | ||
| 1866 | ], | ||
| 1867 | qs => { | ||
| 1868 | allow_no_indices => "boolean", | ||
| 1869 | error_trace => "boolean", | ||
| 1870 | expand_wildcards => "enum", | ||
| 1871 | filter_path => "list", | ||
| 1872 | flush => "boolean", | ||
| 1873 | human => "boolean", | ||
| 1874 | ignore_unavailable => "boolean", | ||
| 1875 | max_num_segments => "number", | ||
| 1876 | only_expunge_deletes => "boolean", | ||
| 1877 | wait_for_merge => "boolean", | ||
| 1878 | }, | ||
| 1879 | }, | ||
| 1880 | |||
| 1881 | 'indices.get' => { | ||
| 1882 | doc => "indices-get-index", | ||
| 1883 | parts => { | ||
| 1884 | feature => { multi => 1 }, | ||
| 1885 | index => { multi => 1, required => 1 } | ||
| 1886 | }, | ||
| 1887 | paths => [ | ||
| 1888 | [ { feature => 1, index => 0 }, "{index}", "{feature}" ], | ||
| 1889 | [ { index => 0 }, "{index}" ], | ||
| 1890 | ], | ||
| 1891 | qs => { | ||
| 1892 | allow_no_indices => "boolean", | ||
| 1893 | error_trace => "boolean", | ||
| 1894 | expand_wildcards => "enum", | ||
| 1895 | filter_path => "list", | ||
| 1896 | flat_settings => "boolean", | ||
| 1897 | human => "boolean", | ||
| 1898 | ignore_unavailable => "boolean", | ||
| 1899 | include_defaults => "boolean", | ||
| 1900 | local => "boolean", | ||
| 1901 | }, | ||
| 1902 | }, | ||
| 1903 | |||
| 1904 | 'indices.get_alias' => { | ||
| 1905 | doc => "indices-aliases", | ||
| 1906 | parts => { index => { multi => 1 }, name => { multi => 1 } }, | ||
| 1907 | paths => [ | ||
| 1908 | [ { index => 0, name => 2 }, "{index}", "_alias", "{name}" ], | ||
| 1909 | [ { index => 0 }, "{index}", "_alias" ], | ||
| 1910 | [ { name => 1 }, "_alias", "{name}" ], | ||
| 1911 | [ {}, "_alias" ], | ||
| 1912 | ], | ||
| 1913 | qs => { | ||
| 1914 | allow_no_indices => "boolean", | ||
| 1915 | error_trace => "boolean", | ||
| 1916 | expand_wildcards => "enum", | ||
| 1917 | filter_path => "list", | ||
| 1918 | human => "boolean", | ||
| 1919 | ignore_unavailable => "boolean", | ||
| 1920 | local => "boolean", | ||
| 1921 | }, | ||
| 1922 | }, | ||
| 1923 | |||
| 1924 | 'indices.get_field_mapping' => { | ||
| 1925 | doc => "indices-get-field-mapping", | ||
| 1926 | parts => { | ||
| 1927 | fields => { multi => 1, required => 1 }, | ||
| 1928 | index => { multi => 1 }, | ||
| 1929 | type => { multi => 1 }, | ||
| 1930 | }, | ||
| 1931 | paths => [ | ||
| 1932 | [ { fields => 4, index => 0, type => 2 }, "{index}", | ||
| 1933 | "_mapping", "{type}", | ||
| 1934 | "field", "{fields}", | ||
| 1935 | ], | ||
| 1936 | [ { fields => 3, index => 0 }, "{index}", | ||
| 1937 | "_mapping", "field", | ||
| 1938 | "{fields}", | ||
| 1939 | ], | ||
| 1940 | [ { fields => 3, type => 1 }, "_mapping", | ||
| 1941 | "{type}", "field", | ||
| 1942 | "{fields}", | ||
| 1943 | ], | ||
| 1944 | [ { fields => 2 }, "_mapping", "field", "{fields}" ], | ||
| 1945 | ], | ||
| 1946 | qs => { | ||
| 1947 | allow_no_indices => "boolean", | ||
| 1948 | error_trace => "boolean", | ||
| 1949 | expand_wildcards => "enum", | ||
| 1950 | filter_path => "list", | ||
| 1951 | human => "boolean", | ||
| 1952 | ignore_unavailable => "boolean", | ||
| 1953 | include_defaults => "boolean", | ||
| 1954 | local => "boolean", | ||
| 1955 | }, | ||
| 1956 | }, | ||
| 1957 | |||
| 1958 | 'indices.get_mapping' => { | ||
| 1959 | doc => "indices-get-mapping", | ||
| 1960 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 1961 | paths => [ | ||
| 1962 | [ { index => 0, type => 2 }, "{index}", "_mapping", "{type}" ], | ||
| 1963 | [ { index => 0 }, "{index}", "_mapping" ], | ||
| 1964 | [ { type => 1 }, "_mapping", "{type}" ], | ||
| 1965 | [ {}, "_mapping" ], | ||
| 1966 | ], | ||
| 1967 | qs => { | ||
| 1968 | allow_no_indices => "boolean", | ||
| 1969 | error_trace => "boolean", | ||
| 1970 | expand_wildcards => "enum", | ||
| 1971 | filter_path => "list", | ||
| 1972 | human => "boolean", | ||
| 1973 | ignore_unavailable => "boolean", | ||
| 1974 | local => "boolean", | ||
| 1975 | }, | ||
| 1976 | }, | ||
| 1977 | |||
| 1978 | 'indices.get_settings' => { | ||
| 1979 | doc => "indices-get-settings", | ||
| 1980 | parts => { index => { multi => 1 }, name => { multi => 1 } }, | ||
| 1981 | paths => [ | ||
| 1982 | [ { index => 0, name => 2 }, "{index}", "_settings", "{name}" ], | ||
| 1983 | [ { index => 0 }, "{index}", "_settings" ], | ||
| 1984 | [ { name => 1 }, "_settings", "{name}" ], | ||
| 1985 | [ {}, "_settings" ], | ||
| 1986 | ], | ||
| 1987 | qs => { | ||
| 1988 | allow_no_indices => "boolean", | ||
| 1989 | error_trace => "boolean", | ||
| 1990 | expand_wildcards => "enum", | ||
| 1991 | filter_path => "list", | ||
| 1992 | flat_settings => "boolean", | ||
| 1993 | human => "boolean", | ||
| 1994 | ignore_unavailable => "boolean", | ||
| 1995 | include_defaults => "boolean", | ||
| 1996 | local => "boolean", | ||
| 1997 | }, | ||
| 1998 | }, | ||
| 1999 | |||
| 2000 | 'indices.get_template' => { | ||
| 2001 | doc => "indices-templates", | ||
| 2002 | parts => { name => { multi => 1 } }, | ||
| 2003 | paths => | ||
| 2004 | [ [ { name => 1 }, "_template", "{name}" ], [ {}, "_template" ] ], | ||
| 2005 | qs => { | ||
| 2006 | error_trace => "boolean", | ||
| 2007 | filter_path => "list", | ||
| 2008 | flat_settings => "boolean", | ||
| 2009 | human => "boolean", | ||
| 2010 | local => "boolean", | ||
| 2011 | master_timeout => "time", | ||
| 2012 | }, | ||
| 2013 | }, | ||
| 2014 | |||
| 2015 | 'indices.get_upgrade' => { | ||
| 2016 | doc => "indices-upgrade", | ||
| 2017 | parts => { index => { multi => 1 } }, | ||
| 2018 | paths => | ||
| 2019 | [ [ { index => 0 }, "{index}", "_upgrade" ], [ {}, "_upgrade" ] ], | ||
| 2020 | qs => { | ||
| 2021 | allow_no_indices => "boolean", | ||
| 2022 | error_trace => "boolean", | ||
| 2023 | expand_wildcards => "enum", | ||
| 2024 | filter_path => "list", | ||
| 2025 | human => "boolean", | ||
| 2026 | ignore_unavailable => "boolean", | ||
| 2027 | }, | ||
| 2028 | }, | ||
| 2029 | |||
| 2030 | 'indices.open' => { | ||
| 2031 | doc => "indices-open-close", | ||
| 2032 | method => "POST", | ||
| 2033 | parts => { index => { multi => 1, required => 1 } }, | ||
| 2034 | paths => [ [ { index => 0 }, "{index}", "_open" ] ], | ||
| 2035 | qs => { | ||
| 2036 | allow_no_indices => "boolean", | ||
| 2037 | error_trace => "boolean", | ||
| 2038 | expand_wildcards => "enum", | ||
| 2039 | filter_path => "list", | ||
| 2040 | human => "boolean", | ||
| 2041 | ignore_unavailable => "boolean", | ||
| 2042 | master_timeout => "time", | ||
| 2043 | timeout => "time", | ||
| 2044 | }, | ||
| 2045 | }, | ||
| 2046 | |||
| 2047 | 'indices.put_alias' => { | ||
| 2048 | body => {}, | ||
| 2049 | doc => "indices-aliases", | ||
| 2050 | method => "PUT", | ||
| 2051 | parts => { | ||
| 2052 | index => { multi => 1, required => 1 }, | ||
| 2053 | name => { required => 1 } | ||
| 2054 | }, | ||
| 2055 | paths => | ||
| 2056 | [ [ { index => 0, name => 2 }, "{index}", "_alias", "{name}" ] ], | ||
| 2057 | qs => { | ||
| 2058 | error_trace => "boolean", | ||
| 2059 | filter_path => "list", | ||
| 2060 | human => "boolean", | ||
| 2061 | master_timeout => "time", | ||
| 2062 | timeout => "time", | ||
| 2063 | }, | ||
| 2064 | }, | ||
| 2065 | |||
| 2066 | 'indices.put_mapping' => { | ||
| 2067 | body => { required => 1 }, | ||
| 2068 | doc => "indices-put-mapping", | ||
| 2069 | method => "PUT", | ||
| 2070 | parts => { index => { multi => 1 }, type => { required => 1 } }, | ||
| 2071 | paths => [ | ||
| 2072 | [ { index => 0, type => 2 }, "{index}", "_mapping", "{type}" ], | ||
| 2073 | [ { type => 1 }, "_mapping", "{type}" ], | ||
| 2074 | ], | ||
| 2075 | qs => { | ||
| 2076 | allow_no_indices => "boolean", | ||
| 2077 | error_trace => "boolean", | ||
| 2078 | expand_wildcards => "enum", | ||
| 2079 | filter_path => "list", | ||
| 2080 | human => "boolean", | ||
| 2081 | ignore_unavailable => "boolean", | ||
| 2082 | master_timeout => "time", | ||
| 2083 | timeout => "time", | ||
| 2084 | update_all_types => "boolean", | ||
| 2085 | }, | ||
| 2086 | }, | ||
| 2087 | |||
| 2088 | 'indices.put_settings' => { | ||
| 2089 | body => { required => 1 }, | ||
| 2090 | doc => "indices-update-settings", | ||
| 2091 | method => "PUT", | ||
| 2092 | parts => { index => { multi => 1 } }, | ||
| 2093 | paths => [ | ||
| 2094 | [ { index => 0 }, "{index}", "_settings" ], | ||
| 2095 | [ {}, "_settings" ] | ||
| 2096 | ], | ||
| 2097 | qs => { | ||
| 2098 | allow_no_indices => "boolean", | ||
| 2099 | error_trace => "boolean", | ||
| 2100 | expand_wildcards => "enum", | ||
| 2101 | filter_path => "list", | ||
| 2102 | flat_settings => "boolean", | ||
| 2103 | human => "boolean", | ||
| 2104 | ignore_unavailable => "boolean", | ||
| 2105 | master_timeout => "time", | ||
| 2106 | preserve_existing => "boolean", | ||
| 2107 | }, | ||
| 2108 | }, | ||
| 2109 | |||
| 2110 | 'indices.put_template' => { | ||
| 2111 | body => { required => 1 }, | ||
| 2112 | doc => "indices-templates", | ||
| 2113 | method => "PUT", | ||
| 2114 | parts => { name => { required => 1 } }, | ||
| 2115 | paths => [ [ { name => 1 }, "_template", "{name}" ] ], | ||
| 2116 | qs => { | ||
| 2117 | create => "boolean", | ||
| 2118 | error_trace => "boolean", | ||
| 2119 | filter_path => "list", | ||
| 2120 | flat_settings => "boolean", | ||
| 2121 | human => "boolean", | ||
| 2122 | master_timeout => "time", | ||
| 2123 | order => "number", | ||
| 2124 | timeout => "time", | ||
| 2125 | }, | ||
| 2126 | }, | ||
| 2127 | |||
| 2128 | 'indices.recovery' => { | ||
| 2129 | doc => "indices-recovery", | ||
| 2130 | parts => { index => { multi => 1 } }, | ||
| 2131 | paths => [ | ||
| 2132 | [ { index => 0 }, "{index}", "_recovery" ], | ||
| 2133 | [ {}, "_recovery" ] | ||
| 2134 | ], | ||
| 2135 | qs => { | ||
| 2136 | active_only => "boolean", | ||
| 2137 | detailed => "boolean", | ||
| 2138 | error_trace => "boolean", | ||
| 2139 | filter_path => "list", | ||
| 2140 | human => "boolean", | ||
| 2141 | }, | ||
| 2142 | }, | ||
| 2143 | |||
| 2144 | 'indices.refresh' => { | ||
| 2145 | doc => "indices-refresh", | ||
| 2146 | method => "POST", | ||
| 2147 | parts => { index => { multi => 1 } }, | ||
| 2148 | paths => | ||
| 2149 | [ [ { index => 0 }, "{index}", "_refresh" ], [ {}, "_refresh" ] ], | ||
| 2150 | qs => { | ||
| 2151 | allow_no_indices => "boolean", | ||
| 2152 | error_trace => "boolean", | ||
| 2153 | expand_wildcards => "enum", | ||
| 2154 | filter_path => "list", | ||
| 2155 | human => "boolean", | ||
| 2156 | ignore_unavailable => "boolean", | ||
| 2157 | }, | ||
| 2158 | }, | ||
| 2159 | |||
| 2160 | 'indices.rollover' => { | ||
| 2161 | body => {}, | ||
| 2162 | doc => "indices-rollover-index", | ||
| 2163 | method => "POST", | ||
| 2164 | parts => { alias => { required => 1 }, new_index => {} }, | ||
| 2165 | paths => [ | ||
| 2166 | [ { alias => 0, new_index => 2 }, "{alias}", | ||
| 2167 | "_rollover", "{new_index}", | ||
| 2168 | ], | ||
| 2169 | [ { alias => 0 }, "{alias}", "_rollover" ], | ||
| 2170 | ], | ||
| 2171 | qs => { | ||
| 2172 | dry_run => "boolean", | ||
| 2173 | error_trace => "boolean", | ||
| 2174 | filter_path => "list", | ||
| 2175 | human => "boolean", | ||
| 2176 | master_timeout => "time", | ||
| 2177 | timeout => "time", | ||
| 2178 | wait_for_active_shards => "string", | ||
| 2179 | }, | ||
| 2180 | }, | ||
| 2181 | |||
| 2182 | 'indices.segments' => { | ||
| 2183 | doc => "indices-segments", | ||
| 2184 | parts => { index => { multi => 1 } }, | ||
| 2185 | paths => [ | ||
| 2186 | [ { index => 0 }, "{index}", "_segments" ], | ||
| 2187 | [ {}, "_segments" ] | ||
| 2188 | ], | ||
| 2189 | qs => { | ||
| 2190 | allow_no_indices => "boolean", | ||
| 2191 | error_trace => "boolean", | ||
| 2192 | expand_wildcards => "enum", | ||
| 2193 | filter_path => "list", | ||
| 2194 | human => "boolean", | ||
| 2195 | ignore_unavailable => "boolean", | ||
| 2196 | verbose => "boolean", | ||
| 2197 | }, | ||
| 2198 | }, | ||
| 2199 | |||
| 2200 | 'indices.shard_stores' => { | ||
| 2201 | doc => "indices-shards-stores", | ||
| 2202 | parts => { index => { multi => 1 } }, | ||
| 2203 | paths => [ | ||
| 2204 | [ { index => 0 }, "{index}", "_shard_stores" ], | ||
| 2205 | [ {}, "_shard_stores" ], | ||
| 2206 | ], | ||
| 2207 | qs => { | ||
| 2208 | allow_no_indices => "boolean", | ||
| 2209 | error_trace => "boolean", | ||
| 2210 | expand_wildcards => "enum", | ||
| 2211 | filter_path => "list", | ||
| 2212 | human => "boolean", | ||
| 2213 | ignore_unavailable => "boolean", | ||
| 2214 | status => "list", | ||
| 2215 | }, | ||
| 2216 | }, | ||
| 2217 | |||
| 2218 | 'indices.shrink' => { | ||
| 2219 | body => {}, | ||
| 2220 | doc => "indices-shrink-index", | ||
| 2221 | method => "PUT", | ||
| 2222 | parts => { index => { required => 1 }, target => { required => 1 } }, | ||
| 2223 | paths => [ | ||
| 2224 | [ { index => 0, target => 2 }, "{index}", "_shrink", "{target}" ], | ||
| 2225 | ], | ||
| 2226 | qs => { | ||
| 2227 | error_trace => "boolean", | ||
| 2228 | filter_path => "list", | ||
| 2229 | human => "boolean", | ||
| 2230 | master_timeout => "time", | ||
| 2231 | timeout => "time", | ||
| 2232 | wait_for_active_shards => "string", | ||
| 2233 | }, | ||
| 2234 | }, | ||
| 2235 | |||
| 2236 | 'indices.stats' => { | ||
| 2237 | doc => "indices-stats", | ||
| 2238 | parts => { index => { multi => 1 }, metric => { multi => 1 } }, | ||
| 2239 | paths => [ | ||
| 2240 | [ { index => 0, metric => 2 }, "{index}", "_stats", "{metric}" ], | ||
| 2241 | [ { index => 0 }, "{index}", "_stats" ], | ||
| 2242 | [ { metric => 1 }, "_stats", "{metric}" ], | ||
| 2243 | [ {}, "_stats" ], | ||
| 2244 | ], | ||
| 2245 | qs => { | ||
| 2246 | completion_fields => "list", | ||
| 2247 | error_trace => "boolean", | ||
| 2248 | fielddata_fields => "list", | ||
| 2249 | fields => "list", | ||
| 2250 | filter_path => "list", | ||
| 2251 | groups => "list", | ||
| 2252 | human => "boolean", | ||
| 2253 | include_segment_file_sizes => "boolean", | ||
| 2254 | level => "enum", | ||
| 2255 | types => "list", | ||
| 2256 | }, | ||
| 2257 | }, | ||
| 2258 | |||
| 2259 | 'indices.update_aliases' => { | ||
| 2260 | body => { required => 1 }, | ||
| 2261 | doc => "indices-aliases", | ||
| 2262 | method => "POST", | ||
| 2263 | parts => {}, | ||
| 2264 | paths => [ [ {}, "_aliases" ] ], | ||
| 2265 | qs => { | ||
| 2266 | error_trace => "boolean", | ||
| 2267 | filter_path => "list", | ||
| 2268 | human => "boolean", | ||
| 2269 | master_timeout => "time", | ||
| 2270 | timeout => "time", | ||
| 2271 | }, | ||
| 2272 | }, | ||
| 2273 | |||
| 2274 | 'indices.upgrade' => { | ||
| 2275 | doc => "indices-upgrade", | ||
| 2276 | method => "POST", | ||
| 2277 | parts => { index => { multi => 1 } }, | ||
| 2278 | paths => | ||
| 2279 | [ [ { index => 0 }, "{index}", "_upgrade" ], [ {}, "_upgrade" ] ], | ||
| 2280 | qs => { | ||
| 2281 | allow_no_indices => "boolean", | ||
| 2282 | error_trace => "boolean", | ||
| 2283 | expand_wildcards => "enum", | ||
| 2284 | filter_path => "list", | ||
| 2285 | human => "boolean", | ||
| 2286 | ignore_unavailable => "boolean", | ||
| 2287 | only_ancient_segments => "boolean", | ||
| 2288 | wait_for_completion => "boolean", | ||
| 2289 | }, | ||
| 2290 | }, | ||
| 2291 | |||
| 2292 | 'indices.validate_query' => { | ||
| 2293 | body => {}, | ||
| 2294 | doc => "search-validate", | ||
| 2295 | parts => { index => { multi => 1 }, type => { multi => 1 } }, | ||
| 2296 | paths => [ | ||
| 2297 | [ { index => 0, type => 1 }, "{index}", | ||
| 2298 | "{type}", "_validate", | ||
| 2299 | "query", | ||
| 2300 | ], | ||
| 2301 | [ { index => 0 }, "{index}", "_validate", "query" ], | ||
| 2302 | [ {}, "_validate", "query" ], | ||
| 2303 | ], | ||
| 2304 | qs => { | ||
| 2305 | all_shards => "boolean", | ||
| 2306 | allow_no_indices => "boolean", | ||
| 2307 | analyze_wildcard => "boolean", | ||
| 2308 | analyzer => "string", | ||
| 2309 | default_operator => "enum", | ||
| 2310 | df => "string", | ||
| 2311 | error_trace => "boolean", | ||
| 2312 | expand_wildcards => "enum", | ||
| 2313 | explain => "boolean", | ||
| 2314 | filter_path => "list", | ||
| 2315 | human => "boolean", | ||
| 2316 | ignore_unavailable => "boolean", | ||
| 2317 | lenient => "boolean", | ||
| 2318 | q => "string", | ||
| 2319 | rewrite => "boolean", | ||
| 2320 | }, | ||
| 2321 | }, | ||
| 2322 | |||
| 2323 | 'ingest.delete_pipeline' => { | ||
| 2324 | doc => "ingest", | ||
| 2325 | method => "DELETE", | ||
| 2326 | parts => { id => { required => 1 } }, | ||
| 2327 | paths => [ [ { id => 2 }, "_ingest", "pipeline", "{id}" ] ], | ||
| 2328 | qs => { | ||
| 2329 | error_trace => "boolean", | ||
| 2330 | filter_path => "list", | ||
| 2331 | human => "boolean", | ||
| 2332 | master_timeout => "time", | ||
| 2333 | timeout => "time", | ||
| 2334 | }, | ||
| 2335 | }, | ||
| 2336 | |||
| 2337 | 'ingest.get_pipeline' => { | ||
| 2338 | doc => "ingest", | ||
| 2339 | parts => { id => {} }, | ||
| 2340 | paths => [ | ||
| 2341 | [ { id => 2 }, "_ingest", "pipeline", "{id}" ], | ||
| 2342 | [ {}, "_ingest", "pipeline" ], | ||
| 2343 | ], | ||
| 2344 | qs => { | ||
| 2345 | error_trace => "boolean", | ||
| 2346 | filter_path => "list", | ||
| 2347 | human => "boolean", | ||
| 2348 | master_timeout => "time", | ||
| 2349 | }, | ||
| 2350 | }, | ||
| 2351 | |||
| 2352 | 'ingest.processor.grok' => { | ||
| 2353 | doc => "ingest", | ||
| 2354 | parts => {}, | ||
| 2355 | paths => [ [ {}, "_ingest", "processor", "grok" ] ], | ||
| 2356 | qs => { | ||
| 2357 | error_trace => "boolean", | ||
| 2358 | filter_path => "list", | ||
| 2359 | human => "boolean" | ||
| 2360 | }, | ||
| 2361 | }, | ||
| 2362 | |||
| 2363 | 'ingest.put_pipeline' => { | ||
| 2364 | body => { required => 1 }, | ||
| 2365 | doc => "ingest", | ||
| 2366 | method => "PUT", | ||
| 2367 | parts => { id => { required => 1 } }, | ||
| 2368 | paths => [ [ { id => 2 }, "_ingest", "pipeline", "{id}" ] ], | ||
| 2369 | qs => { | ||
| 2370 | error_trace => "boolean", | ||
| 2371 | filter_path => "list", | ||
| 2372 | human => "boolean", | ||
| 2373 | master_timeout => "time", | ||
| 2374 | timeout => "time", | ||
| 2375 | }, | ||
| 2376 | }, | ||
| 2377 | |||
| 2378 | 'ingest.simulate' => { | ||
| 2379 | body => { required => 1 }, | ||
| 2380 | doc => "ingest", | ||
| 2381 | parts => { id => {} }, | ||
| 2382 | paths => [ | ||
| 2383 | [ { id => 2 }, "_ingest", "pipeline", "{id}", "_simulate" ], | ||
| 2384 | [ {}, "_ingest", "pipeline", "_simulate" ], | ||
| 2385 | ], | ||
| 2386 | qs => { | ||
| 2387 | error_trace => "boolean", | ||
| 2388 | filter_path => "list", | ||
| 2389 | human => "boolean", | ||
| 2390 | verbose => "boolean", | ||
| 2391 | }, | ||
| 2392 | }, | ||
| 2393 | |||
| 2394 | 'nodes.hot_threads' => { | ||
| 2395 | doc => "cluster-nodes-hot-threads", | ||
| 2396 | parts => { node_id => { multi => 1 } }, | ||
| 2397 | paths => [ | ||
| 2398 | [ { node_id => 1 }, "_nodes", "{node_id}", "hot_threads" ], | ||
| 2399 | [ {}, "_nodes", "hot_threads" ], | ||
| 2400 | ], | ||
| 2401 | qs => { | ||
| 2402 | error_trace => "boolean", | ||
| 2403 | filter_path => "list", | ||
| 2404 | human => "boolean", | ||
| 2405 | ignore_idle_threads => "boolean", | ||
| 2406 | interval => "time", | ||
| 2407 | snapshots => "number", | ||
| 2408 | threads => "number", | ||
| 2409 | timeout => "time", | ||
| 2410 | type => "enum", | ||
| 2411 | }, | ||
| 2412 | }, | ||
| 2413 | |||
| 2414 | 'nodes.info' => { | ||
| 2415 | doc => "cluster-nodes-info", | ||
| 2416 | parts => { metric => { multi => 1 }, node_id => { multi => 1 } }, | ||
| 2417 | paths => [ | ||
| 2418 | [ { metric => 2, node_id => 1 }, "_nodes", | ||
| 2419 | "{node_id}", "{metric}", | ||
| 2420 | ], | ||
| 2421 | [ { metric => 1 }, "_nodes", "{metric}" ], | ||
| 2422 | [ { node_id => 1 }, "_nodes", "{node_id}" ], | ||
| 2423 | [ {}, "_nodes" ], | ||
| 2424 | ], | ||
| 2425 | qs => { | ||
| 2426 | error_trace => "boolean", | ||
| 2427 | filter_path => "list", | ||
| 2428 | flat_settings => "boolean", | ||
| 2429 | human => "boolean", | ||
| 2430 | timeout => "time", | ||
| 2431 | }, | ||
| 2432 | }, | ||
| 2433 | |||
| 2434 | 'nodes.stats' => { | ||
| 2435 | doc => "cluster-nodes-stats", | ||
| 2436 | parts => { | ||
| 2437 | index_metric => { multi => 1 }, | ||
| 2438 | metric => { multi => 1 }, | ||
| 2439 | node_id => { multi => 1 }, | ||
| 2440 | }, | ||
| 2441 | paths => [ | ||
| 2442 | [ { index_metric => 4, metric => 3, node_id => 1 }, | ||
| 2443 | "_nodes", "{node_id}", "stats", "{metric}", "{index_metric}", | ||
| 2444 | ], | ||
| 2445 | [ { index_metric => 3, metric => 2 }, "_nodes", | ||
| 2446 | "stats", "{metric}", | ||
| 2447 | "{index_metric}", | ||
| 2448 | ], | ||
| 2449 | [ { metric => 3, node_id => 1 }, "_nodes", | ||
| 2450 | "{node_id}", "stats", | ||
| 2451 | "{metric}", | ||
| 2452 | ], | ||
| 2453 | [ { metric => 2 }, "_nodes", "stats", "{metric}" ], | ||
| 2454 | [ { node_id => 1 }, "_nodes", "{node_id}", "stats" ], | ||
| 2455 | [ {}, "_nodes", "stats" ], | ||
| 2456 | ], | ||
| 2457 | qs => { | ||
| 2458 | completion_fields => "list", | ||
| 2459 | error_trace => "boolean", | ||
| 2460 | fielddata_fields => "list", | ||
| 2461 | fields => "list", | ||
| 2462 | filter_path => "list", | ||
| 2463 | groups => "boolean", | ||
| 2464 | human => "boolean", | ||
| 2465 | include_segment_file_sizes => "boolean", | ||
| 2466 | level => "enum", | ||
| 2467 | timeout => "time", | ||
| 2468 | types => "list", | ||
| 2469 | }, | ||
| 2470 | }, | ||
| 2471 | |||
| 2472 | 'remote.info' => { | ||
| 2473 | doc => "cluster-remote-info", | ||
| 2474 | parts => {}, | ||
| 2475 | paths => [ [ {}, "_remote", "info" ] ], | ||
| 2476 | qs => { | ||
| 2477 | error_trace => "boolean", | ||
| 2478 | filter_path => "list", | ||
| 2479 | human => "boolean" | ||
| 2480 | }, | ||
| 2481 | }, | ||
| 2482 | |||
| 2483 | 'snapshot.create' => { | ||
| 2484 | body => {}, | ||
| 2485 | doc => "modules-snapshots", | ||
| 2486 | method => "PUT", | ||
| 2487 | parts => { | ||
| 2488 | repository => { required => 1 }, | ||
| 2489 | snapshot => { required => 1 } | ||
| 2490 | }, | ||
| 2491 | paths => [ | ||
| 2492 | [ { repository => 1, snapshot => 2 }, "_snapshot", | ||
| 2493 | "{repository}", "{snapshot}", | ||
| 2494 | ], | ||
| 2495 | ], | ||
| 2496 | qs => { | ||
| 2497 | error_trace => "boolean", | ||
| 2498 | filter_path => "list", | ||
| 2499 | human => "boolean", | ||
| 2500 | master_timeout => "time", | ||
| 2501 | wait_for_completion => "boolean", | ||
| 2502 | }, | ||
| 2503 | }, | ||
| 2504 | |||
| 2505 | 'snapshot.create_repository' => { | ||
| 2506 | body => { required => 1 }, | ||
| 2507 | doc => "modules-snapshots", | ||
| 2508 | method => "PUT", | ||
| 2509 | parts => { repository => { required => 1 } }, | ||
| 2510 | paths => [ [ { repository => 1 }, "_snapshot", "{repository}" ] ], | ||
| 2511 | qs => { | ||
| 2512 | error_trace => "boolean", | ||
| 2513 | filter_path => "list", | ||
| 2514 | human => "boolean", | ||
| 2515 | master_timeout => "time", | ||
| 2516 | timeout => "time", | ||
| 2517 | verify => "boolean", | ||
| 2518 | }, | ||
| 2519 | }, | ||
| 2520 | |||
| 2521 | 'snapshot.delete' => { | ||
| 2522 | doc => "modules-snapshots", | ||
| 2523 | method => "DELETE", | ||
| 2524 | parts => { | ||
| 2525 | repository => { required => 1 }, | ||
| 2526 | snapshot => { required => 1 } | ||
| 2527 | }, | ||
| 2528 | paths => [ | ||
| 2529 | [ { repository => 1, snapshot => 2 }, "_snapshot", | ||
| 2530 | "{repository}", "{snapshot}", | ||
| 2531 | ], | ||
| 2532 | ], | ||
| 2533 | qs => { | ||
| 2534 | error_trace => "boolean", | ||
| 2535 | filter_path => "list", | ||
| 2536 | human => "boolean", | ||
| 2537 | master_timeout => "time", | ||
| 2538 | }, | ||
| 2539 | }, | ||
| 2540 | |||
| 2541 | 'snapshot.delete_repository' => { | ||
| 2542 | doc => "modules-snapshots", | ||
| 2543 | method => "DELETE", | ||
| 2544 | parts => { repository => { multi => 1, required => 1 } }, | ||
| 2545 | paths => [ [ { repository => 1 }, "_snapshot", "{repository}" ] ], | ||
| 2546 | qs => { | ||
| 2547 | error_trace => "boolean", | ||
| 2548 | filter_path => "list", | ||
| 2549 | human => "boolean", | ||
| 2550 | master_timeout => "time", | ||
| 2551 | timeout => "time", | ||
| 2552 | }, | ||
| 2553 | }, | ||
| 2554 | |||
| 2555 | 'snapshot.get' => { | ||
| 2556 | doc => "modules-snapshots", | ||
| 2557 | parts => { | ||
| 2558 | repository => { required => 1 }, | ||
| 2559 | snapshot => { multi => 1, required => 1 }, | ||
| 2560 | }, | ||
| 2561 | paths => [ | ||
| 2562 | [ { repository => 1, snapshot => 2 }, "_snapshot", | ||
| 2563 | "{repository}", "{snapshot}", | ||
| 2564 | ], | ||
| 2565 | ], | ||
| 2566 | qs => { | ||
| 2567 | error_trace => "boolean", | ||
| 2568 | filter_path => "list", | ||
| 2569 | human => "boolean", | ||
| 2570 | ignore_unavailable => "boolean", | ||
| 2571 | master_timeout => "time", | ||
| 2572 | verbose => "boolean", | ||
| 2573 | }, | ||
| 2574 | }, | ||
| 2575 | |||
| 2576 | 'snapshot.get_repository' => { | ||
| 2577 | doc => "modules-snapshots", | ||
| 2578 | parts => { repository => { multi => 1 } }, | ||
| 2579 | paths => [ | ||
| 2580 | [ { repository => 1 }, "_snapshot", "{repository}" ], | ||
| 2581 | [ {}, "_snapshot" ], | ||
| 2582 | ], | ||
| 2583 | qs => { | ||
| 2584 | error_trace => "boolean", | ||
| 2585 | filter_path => "list", | ||
| 2586 | human => "boolean", | ||
| 2587 | local => "boolean", | ||
| 2588 | master_timeout => "time", | ||
| 2589 | }, | ||
| 2590 | }, | ||
| 2591 | |||
| 2592 | 'snapshot.restore' => { | ||
| 2593 | body => {}, | ||
| 2594 | doc => "modules-snapshots", | ||
| 2595 | method => "POST", | ||
| 2596 | parts => { | ||
| 2597 | repository => { required => 1 }, | ||
| 2598 | snapshot => { required => 1 } | ||
| 2599 | }, | ||
| 2600 | paths => [ | ||
| 2601 | [ { repository => 1, snapshot => 2 }, "_snapshot", | ||
| 2602 | "{repository}", "{snapshot}", | ||
| 2603 | "_restore", | ||
| 2604 | ], | ||
| 2605 | ], | ||
| 2606 | qs => { | ||
| 2607 | error_trace => "boolean", | ||
| 2608 | filter_path => "list", | ||
| 2609 | human => "boolean", | ||
| 2610 | master_timeout => "time", | ||
| 2611 | wait_for_completion => "boolean", | ||
| 2612 | }, | ||
| 2613 | }, | ||
| 2614 | |||
| 2615 | 'snapshot.status' => { | ||
| 2616 | doc => "modules-snapshots", | ||
| 2617 | parts => { repository => {}, snapshot => { multi => 1 } }, | ||
| 2618 | paths => [ | ||
| 2619 | [ { repository => 1, snapshot => 2 }, "_snapshot", | ||
| 2620 | "{repository}", "{snapshot}", | ||
| 2621 | "_status", | ||
| 2622 | ], | ||
| 2623 | [ { repository => 1 }, "_snapshot", "{repository}", "_status" ], | ||
| 2624 | [ {}, "_snapshot", "_status" ], | ||
| 2625 | ], | ||
| 2626 | qs => { | ||
| 2627 | error_trace => "boolean", | ||
| 2628 | filter_path => "list", | ||
| 2629 | human => "boolean", | ||
| 2630 | ignore_unavailable => "boolean", | ||
| 2631 | master_timeout => "time", | ||
| 2632 | }, | ||
| 2633 | }, | ||
| 2634 | |||
| 2635 | 'snapshot.verify_repository' => { | ||
| 2636 | doc => "modules-snapshots", | ||
| 2637 | method => "POST", | ||
| 2638 | parts => { repository => { required => 1 } }, | ||
| 2639 | paths => [ | ||
| 2640 | [ { repository => 1 }, "_snapshot", "{repository}", "_verify" ], | ||
| 2641 | ], | ||
| 2642 | qs => { | ||
| 2643 | error_trace => "boolean", | ||
| 2644 | filter_path => "list", | ||
| 2645 | human => "boolean", | ||
| 2646 | master_timeout => "time", | ||
| 2647 | timeout => "time", | ||
| 2648 | }, | ||
| 2649 | }, | ||
| 2650 | |||
| 2651 | 'tasks.cancel' => { | ||
| 2652 | doc => "tasks", | ||
| 2653 | method => "POST", | ||
| 2654 | parts => { task_id => {} }, | ||
| 2655 | paths => [ | ||
| 2656 | [ { task_id => 1 }, "_tasks", "{task_id}", "_cancel" ], | ||
| 2657 | [ {}, "_tasks", "_cancel" ], | ||
| 2658 | ], | ||
| 2659 | qs => { | ||
| 2660 | actions => "list", | ||
| 2661 | error_trace => "boolean", | ||
| 2662 | filter_path => "list", | ||
| 2663 | human => "boolean", | ||
| 2664 | nodes => "list", | ||
| 2665 | parent_node => "string", | ||
| 2666 | parent_task_id => "string", | ||
| 2667 | }, | ||
| 2668 | }, | ||
| 2669 | |||
| 2670 | 'tasks.get' => { | ||
| 2671 | doc => "tasks", | ||
| 2672 | parts => { task_id => {} }, | ||
| 2673 | paths => [ [ { task_id => 1 }, "_tasks", "{task_id}" ] ], | ||
| 2674 | qs => { | ||
| 2675 | error_trace => "boolean", | ||
| 2676 | filter_path => "list", | ||
| 2677 | human => "boolean", | ||
| 2678 | wait_for_completion => "boolean", | ||
| 2679 | }, | ||
| 2680 | }, | ||
| 2681 | |||
| 2682 | 'tasks.list' => { | ||
| 2683 | doc => "tasks", | ||
| 2684 | parts => {}, | ||
| 2685 | paths => [ [ {}, "_tasks" ] ], | ||
| 2686 | qs => { | ||
| 2687 | actions => "list", | ||
| 2688 | detailed => "boolean", | ||
| 2689 | error_trace => "boolean", | ||
| 2690 | filter_path => "list", | ||
| 2691 | group_by => "enum", | ||
| 2692 | human => "boolean", | ||
| 2693 | nodes => "list", | ||
| 2694 | parent_node => "string", | ||
| 2695 | parent_task_id => "string", | ||
| 2696 | wait_for_completion => "boolean", | ||
| 2697 | }, | ||
| 2698 | }, | ||
| 2699 | |||
| 2700 | #=== AUTOGEN - END === | ||
| 2701 | |||
| 2702 | ); | ||
| 2703 | |||
| 2704 | __PACKAGE__->_qs_init( \%API ); | ||
| 2705 | 1; | ||
| 2706 | |||
| 2707 | =pod | ||
| 2708 | |||
| 2709 | =encoding UTF-8 | ||
| 2710 | |||
| 2711 | =head1 NAME | ||
| 2712 | |||
| 2713 | Search::Elasticsearch::Client::5_0::Role::API - This class contains the spec for the Elasticsearch APIs | ||
| 2714 | |||
| 2715 | =head1 VERSION | ||
| 2716 | |||
| 2717 | version 6.81 | ||
| 2718 | |||
| 2719 | =head1 DESCRIPTION | ||
| 2720 | |||
| 2721 | All of the Elasticsearch APIs are defined in this role. The example given below | ||
| 2722 | is the definition for the L<Search::Elasticsearch::Client::5_0::Direct/index()> method: | ||
| 2723 | |||
| 2724 | 'index' => { | ||
| 2725 | body => { required => 1 }, | ||
| 2726 | doc => "docs-index_", | ||
| 2727 | method => "POST", | ||
| 2728 | parts => { | ||
| 2729 | id => {}, | ||
| 2730 | index => { required => 1 }, | ||
| 2731 | type => { required => 1 } | ||
| 2732 | }, | ||
| 2733 | paths => [ | ||
| 2734 | [ { id => 2, index => 0, type => 1 }, "{index}", | ||
| 2735 | "{type}", "{id}" | ||
| 2736 | ], | ||
| 2737 | [ { index => 0, type => 1 }, "{index}", "{type}" ], | ||
| 2738 | ], | ||
| 2739 | qs => { | ||
| 2740 | filter_path => "list", | ||
| 2741 | op_type => "enum", | ||
| 2742 | parent => "string", | ||
| 2743 | pipeline => "string", | ||
| 2744 | refresh => "enum", | ||
| 2745 | routing => "string", | ||
| 2746 | timeout => "time", | ||
| 2747 | timestamp => "time", | ||
| 2748 | ttl => "time", | ||
| 2749 | version => "number", | ||
| 2750 | version_type => "enum", | ||
| 2751 | wait_for_active_shards => "string", | ||
| 2752 | }, | ||
| 2753 | }, | ||
| 2754 | |||
| 2755 | These definitions can be used by different L<Search::Elasticsearch::Role::Client> | ||
| 2756 | implementations to provide distinct user interfaces. | ||
| 2757 | |||
| 2758 | =head1 METHODS | ||
| 2759 | |||
| 2760 | =head2 C<api()> | ||
| 2761 | |||
| 2762 | $defn = $api->api($name); | ||
| 2763 | |||
| 2764 | The only method in this class is the C<api()> method which takes the name | ||
| 2765 | of the I<action> and returns its definition. Actions in the | ||
| 2766 | C<indices> or C<cluster> namespace use the namespace as a prefix, eg: | ||
| 2767 | |||
| 2768 | $defn = $e->api('indices.create'); | ||
| 2769 | $defn = $e->api('cluster.node_stats'); | ||
| 2770 | |||
| 2771 | =head1 SEE ALSO | ||
| 2772 | |||
| 2773 | =over | ||
| 2774 | |||
| 2775 | =item * | ||
| 2776 | |||
| 2777 | L<Search::Elasticsearch::Role::API> | ||
| 2778 | |||
| 2779 | =item * | ||
| 2780 | |||
| 2781 | L<Search::Elasticsearch::Client::5_0::Direct> | ||
| 2782 | |||
| 2783 | =back | ||
| 2784 | |||
| 2785 | =head1 AUTHOR | ||
| 2786 | |||
| 2787 | Enrico Zimuel <enrico.zimuel@elastic.co> | ||
| 2788 | |||
| 2789 | =head1 COPYRIGHT AND LICENSE | ||
| 2790 | |||
| 2791 | This software is Copyright (c) 2020 by Elasticsearch BV. | ||
| 2792 | |||
| 2793 | This is free software, licensed under: | ||
| 2794 | |||
| 2795 | The Apache License, Version 2.0, January 2004 | ||
| 2796 | |||
| 2797 | =cut | ||
| 2798 | |||
| 2799 | __END__ |