Elastic · Schema

_types.aggregations.AggregationContainer

SearchAnalyticsObservabilitySecurityVisualizationCloudMonitoring

Properties

Name Type Description
aggregations object Sub-aggregations for this aggregation. Only applies to bucket aggregations.
meta object
adjacency_matrix object A bucket aggregation returning a form of adjacency matrix. The request provides a collection of named filter expressions, similar to the `filters` aggregation. Each bucket in the response represents a
auto_date_histogram object A multi-bucket aggregation similar to the date histogram, except instead of providing an interval to use as the width of each bucket, a target number of buckets is provided.
avg object A single-value metrics aggregation that computes the average of numeric values that are extracted from the aggregated documents.
avg_bucket object A sibling pipeline aggregation which calculates the mean value of a specified metric in a sibling aggregation. The specified metric must be numeric and the sibling aggregation must be a multi-bucket a
boxplot object A metrics aggregation that computes a box plot of numeric values extracted from the aggregated documents.
bucket_script object A parent pipeline aggregation which runs a script which can perform per bucket computations on metrics in the parent multi-bucket aggregation.
bucket_selector object A parent pipeline aggregation which runs a script to determine whether the current bucket will be retained in the parent multi-bucket aggregation.
bucket_sort object A parent pipeline aggregation which sorts the buckets of its parent multi-bucket aggregation.
bucket_count_ks_test object A sibling pipeline aggregation which runs a two sample Kolmogorov–Smirnov test ("K-S test") against a provided distribution and the distribution implied by the documents counts in the configured sibli
bucket_correlation object A sibling pipeline aggregation which runs a correlation function on the configured sibling multi-bucket aggregation.
cardinality object A single-value metrics aggregation that calculates an approximate count of distinct values.
cartesian_bounds object A metric aggregation that computes the spatial bounding box containing all values for a Point or Shape field.
cartesian_centroid object A metric aggregation that computes the weighted centroid from all coordinate values for point and shape fields.
categorize_text object A multi-bucket aggregation that groups semi-structured text into buckets.
change_point object A sibling pipeline that detects, spikes, dips, and change points in a metric. Given a distribution of values provided by the sibling multi-bucket aggregation, this aggregation indicates the bucket of
children object A single bucket aggregation that selects child documents that have the specified type, as defined in a `join` field.
composite object A multi-bucket aggregation that creates composite buckets from different sources. Unlike the other multi-bucket aggregations, you can use the `composite` aggregation to paginate *all* buckets from a m
cumulative_cardinality object A parent pipeline aggregation which calculates the cumulative cardinality in a parent `histogram` or `date_histogram` aggregation.
cumulative_sum object A parent pipeline aggregation which calculates the cumulative sum of a specified metric in a parent `histogram` or `date_histogram` aggregation.
date_histogram object A multi-bucket values source based aggregation that can be applied on date values or date range values extracted from the documents. It dynamically builds fixed size (interval) buckets over the values
date_range object A multi-bucket value source based aggregation that enables the user to define a set of date ranges - each representing a bucket.
derivative object A parent pipeline aggregation which calculates the derivative of a specified metric in a parent `histogram` or `date_histogram` aggregation.
diversified_sampler object A filtering aggregation used to limit any sub aggregations' processing to a sample of the top-scoring documents. Similar to the `sampler` aggregation, but adds the ability to limit the number of match
extended_stats object A multi-value metrics aggregation that computes stats over numeric values extracted from the aggregated documents.
extended_stats_bucket object A sibling pipeline aggregation which calculates a variety of stats across all bucket of a specified metric in a sibling aggregation.
frequent_item_sets object A bucket aggregation which finds frequent item sets, a form of association rules mining that identifies items that often occur together.
filter object A single bucket aggregation that narrows the set of documents to those that match a query.
filters object A multi-bucket aggregation where each bucket contains the documents that match a query.
geo_bounds object A metric aggregation that computes the geographic bounding box containing all values for a Geopoint or Geoshape field.
geo_centroid object A metric aggregation that computes the weighted centroid from all coordinate values for geo fields.
geo_distance object A multi-bucket aggregation that works on `geo_point` fields. Evaluates the distance of each document value from an origin point and determines the buckets it belongs to, based on ranges defined in the
geohash_grid object A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid. Each cell is labeled using a geohash which is of user-definable precision.
geo_line object Aggregates all `geo_point` values within a bucket into a `LineString` ordered by the chosen sort field.
geotile_grid object A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid. Each cell corresponds to a map tile as used by many online map sites.
geohex_grid object A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid. Each cell corresponds to a H3 cell index and is labeled using the H3Index representation.
global object Defines a single bucket of all the documents within the search execution context. This context is defined by the indices and the document types you’re searching on, but is not influenced by the search
histogram object A multi-bucket values source based aggregation that can be applied on numeric values or numeric range values extracted from the documents. It dynamically builds fixed size (interval) buckets over the
ip_range object A multi-bucket value source based aggregation that enables the user to define a set of IP ranges - each representing a bucket.
ip_prefix object A bucket aggregation that groups documents based on the network or sub-network of an IP address.
inference object A parent pipeline aggregation which loads a pre-trained model and performs inference on the collated result fields from the parent bucket aggregation.
line object
matrix_stats object A numeric aggregation that computes the following statistics over a set of document fields: `count`, `mean`, `variance`, `skewness`, `kurtosis`, `covariance`, and `covariance`.
max object A single-value metrics aggregation that returns the maximum value among the numeric values extracted from the aggregated documents.
max_bucket object A sibling pipeline aggregation which identifies the bucket(s) with the maximum value of a specified metric in a sibling aggregation and outputs both the value and the key(s) of the bucket(s).
median_absolute_deviation object A single-value aggregation that approximates the median absolute deviation of its search results.
min object A single-value metrics aggregation that returns the minimum value among numeric values extracted from the aggregated documents.
min_bucket object A sibling pipeline aggregation which identifies the bucket(s) with the minimum value of a specified metric in a sibling aggregation and outputs both the value and the key(s) of the bucket(s).
missing object A field data based single bucket aggregation, that creates a bucket of all documents in the current document set context that are missing a field value (effectively, missing a field or having the conf
moving_avg object
moving_percentiles object Given an ordered series of percentiles, "slides" a window across those percentiles and computes cumulative percentiles.
moving_fn object Given an ordered series of data, "slides" a window across the data and runs a custom script on each window of data. For convenience, a number of common functions are predefined such as `min`, `max`, a
multi_terms object A multi-bucket value source based aggregation where buckets are dynamically built - one per unique set of values.
nested object A special single bucket aggregation that enables aggregating nested documents.
normalize object A parent pipeline aggregation which calculates the specific normalized/rescaled value for a specific bucket value.
parent object A special single bucket aggregation that selects parent documents that have the specified type, as defined in a `join` field.
percentile_ranks object A multi-value metrics aggregation that calculates one or more percentile ranks over numeric values extracted from the aggregated documents.
percentiles object A multi-value metrics aggregation that calculates one or more percentiles over numeric values extracted from the aggregated documents.
percentiles_bucket object A sibling pipeline aggregation which calculates percentiles across all bucket of a specified metric in a sibling aggregation.
range object A multi-bucket value source based aggregation that enables the user to define a set of ranges - each representing a bucket.
rare_terms object A multi-bucket value source based aggregation which finds "rare" terms — terms that are at the long-tail of the distribution and are not frequent.
rate object Calculates a rate of documents or a field in each bucket. Can only be used inside a `date_histogram` or `composite` aggregation.
reverse_nested object A special single bucket aggregation that enables aggregating on parent documents from nested documents. Should only be defined inside a `nested` aggregation.
random_sampler object A single bucket aggregation that randomly includes documents in the aggregated results. Sampling provides significant speed improvement at the cost of accuracy.
sampler object A filtering aggregation used to limit any sub aggregations' processing to a sample of the top-scoring documents.
scripted_metric object A metric aggregation that uses scripts to provide a metric output.
serial_diff object An aggregation that subtracts values in a time series from themselves at different time lags or periods.
significant_terms object Returns interesting or unusual occurrences of terms in a set.
significant_text object Returns interesting or unusual occurrences of free-text terms in a set.
stats object A multi-value metrics aggregation that computes stats over numeric values extracted from the aggregated documents.
stats_bucket object A sibling pipeline aggregation which calculates a variety of stats across all bucket of a specified metric in a sibling aggregation.
string_stats object A multi-value metrics aggregation that computes statistics over string values extracted from the aggregated documents.
sum object A single-value metrics aggregation that sums numeric values that are extracted from the aggregated documents.
sum_bucket object A sibling pipeline aggregation which calculates the sum of a specified metric across all buckets in a sibling aggregation.
terms object A multi-bucket value source based aggregation where buckets are dynamically built - one per unique value.
time_series object The time series aggregation queries data created using a time series index. This is typically data such as metrics or other data streams with a time component, and requires creating an index using the
top_hits object A metric aggregation that returns the top matching documents per bucket.
t_test object A metrics aggregation that performs a statistical hypothesis test in which the test statistic follows a Student’s t-distribution under the null hypothesis on numeric values extracted from the aggregat
top_metrics object A metric aggregation that selects metrics from the document with the largest or smallest sort value.
value_count object A single-value metrics aggregation that counts the number of values that are extracted from the aggregated documents.
weighted_avg object A single-value metrics aggregation that computes the weighted average of numeric values that are extracted from the aggregated documents.
variable_width_histogram object A multi-bucket aggregation similar to the histogram, except instead of providing an interval to use as the width of each bucket, a target number of buckets is provided.
View JSON Schema on GitHub

JSON Schema

elastic-types-aggregations-aggregation-container-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/elastic/json-schema/elastic-types-aggregations-aggregation-container-schema.json",
  "title": "_types.aggregations.AggregationContainer",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/elastic-search-api-openapi.yml#/components/schemas/_types.aggregations.AggregationContainer",
  "allOf": [
    {
      "type": "object",
      "properties": {
        "aggregations": {
          "description": "Sub-aggregations for this aggregation.\nOnly applies to bucket aggregations.",
          "type": "object",
          "additionalProperties": {
            "$ref": "#/$defs/_types.aggregations.AggregationContainer"
          }
        },
        "meta": {
          "allOf": [
            {
              "$ref": "#/$defs/_types.Metadata"
            }
          ]
        }
      }
    },
    {
      "type": "object",
      "properties": {
        "adjacency_matrix": {
          "description": "A bucket aggregation returning a form of adjacency matrix.\nThe request provides a collection of named filter expressions, similar to the `filters` aggregation.\nEach bucket in the response represents a non-empty cell in the matrix of intersecting filters.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.AdjacencyMatrixAggregation"
            }
          ]
        },
        "auto_date_histogram": {
          "description": "A multi-bucket aggregation similar to the date histogram, except instead of providing an interval to use as the width of each bucket, a target number of buckets is provided.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.AutoDateHistogramAggregation"
            }
          ]
        },
        "avg": {
          "description": "A single-value metrics aggregation that computes the average of numeric values that are extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.AverageAggregation"
            }
          ]
        },
        "avg_bucket": {
          "description": "A sibling pipeline aggregation which calculates the mean value of a specified metric in a sibling aggregation.\nThe specified metric must be numeric and the sibling aggregation must be a multi-bucket aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.AverageBucketAggregation"
            }
          ]
        },
        "boxplot": {
          "description": "A metrics aggregation that computes a box plot of numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BoxplotAggregation"
            }
          ]
        },
        "bucket_script": {
          "description": "A parent pipeline aggregation which runs a script which can perform per bucket computations on metrics in the parent multi-bucket aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BucketScriptAggregation"
            }
          ]
        },
        "bucket_selector": {
          "description": "A parent pipeline aggregation which runs a script to determine whether the current bucket will be retained in the parent multi-bucket aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BucketSelectorAggregation"
            }
          ]
        },
        "bucket_sort": {
          "description": "A parent pipeline aggregation which sorts the buckets of its parent multi-bucket aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BucketSortAggregation"
            }
          ]
        },
        "bucket_count_ks_test": {
          "description": "A sibling pipeline aggregation which runs a two sample Kolmogorov–Smirnov test (\"K-S test\") against a provided distribution and the distribution implied by the documents counts in the configured sibling aggregation.",
          "x-state": "Technical preview",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BucketKsAggregation"
            }
          ]
        },
        "bucket_correlation": {
          "description": "A sibling pipeline aggregation which runs a correlation function on the configured sibling multi-bucket aggregation.",
          "x-state": "Technical preview",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.BucketCorrelationAggregation"
            }
          ]
        },
        "cardinality": {
          "description": "A single-value metrics aggregation that calculates an approximate count of distinct values.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CardinalityAggregation"
            }
          ]
        },
        "cartesian_bounds": {
          "description": "A metric aggregation that computes the spatial bounding box containing all values for a Point or Shape field.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CartesianBoundsAggregation"
            }
          ]
        },
        "cartesian_centroid": {
          "description": "A metric aggregation that computes the weighted centroid from all coordinate values for point and shape fields.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CartesianCentroidAggregation"
            }
          ]
        },
        "categorize_text": {
          "description": "A multi-bucket aggregation that groups semi-structured text into buckets.",
          "x-state": "Technical preview",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CategorizeTextAggregation"
            }
          ]
        },
        "change_point": {
          "description": "A sibling pipeline that detects, spikes, dips, and change points in a metric.\nGiven a distribution of values provided by the sibling multi-bucket aggregation,\nthis aggregation indicates the bucket of any spike or dip and/or the bucket at which\nthe largest change in the distribution of values, if they are statistically significant.\nThere must be at least 22 bucketed values. Fewer than 1,000 is preferred.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ChangePointAggregation"
            }
          ]
        },
        "children": {
          "description": "A single bucket aggregation that selects child documents that have the specified type, as defined in a `join` field.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ChildrenAggregation"
            }
          ]
        },
        "composite": {
          "description": "A multi-bucket aggregation that creates composite buckets from different sources.\nUnlike the other multi-bucket aggregations, you can use the `composite` aggregation to paginate *all* buckets from a multi-level aggregation efficiently.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CompositeAggregation"
            }
          ]
        },
        "cumulative_cardinality": {
          "description": "A parent pipeline aggregation which calculates the cumulative cardinality in a parent `histogram` or `date_histogram` aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CumulativeCardinalityAggregation"
            }
          ]
        },
        "cumulative_sum": {
          "description": "A parent pipeline aggregation which calculates the cumulative sum of a specified metric in a parent `histogram` or `date_histogram` aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.CumulativeSumAggregation"
            }
          ]
        },
        "date_histogram": {
          "description": "A multi-bucket values source based aggregation that can be applied on date values or date range values extracted from the documents.\nIt dynamically builds fixed size (interval) buckets over the values.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.DateHistogramAggregation"
            }
          ]
        },
        "date_range": {
          "description": "A multi-bucket value source based aggregation that enables the user to define a set of date ranges - each representing a bucket.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.DateRangeAggregation"
            }
          ]
        },
        "derivative": {
          "description": "A parent pipeline aggregation which calculates the derivative of a specified metric in a parent `histogram` or `date_histogram` aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.DerivativeAggregation"
            }
          ]
        },
        "diversified_sampler": {
          "description": "A filtering aggregation used to limit any sub aggregations' processing to a sample of the top-scoring documents.\nSimilar to the `sampler` aggregation, but adds the ability to limit the number of matches that share a common value.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.DiversifiedSamplerAggregation"
            }
          ]
        },
        "extended_stats": {
          "description": "A multi-value metrics aggregation that computes stats over numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ExtendedStatsAggregation"
            }
          ]
        },
        "extended_stats_bucket": {
          "description": "A sibling pipeline aggregation which calculates a variety of stats across all bucket of a specified metric in a sibling aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ExtendedStatsBucketAggregation"
            }
          ]
        },
        "frequent_item_sets": {
          "description": "A bucket aggregation which finds frequent item sets, a form of association rules mining that identifies items that often occur together.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.FrequentItemSetsAggregation"
            }
          ]
        },
        "filter": {
          "description": "A single bucket aggregation that narrows the set of documents to those that match a query.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.query_dsl.QueryContainer"
            }
          ]
        },
        "filters": {
          "description": "A multi-bucket aggregation where each bucket contains the documents that match a query.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.FiltersAggregation"
            }
          ]
        },
        "geo_bounds": {
          "description": "A metric aggregation that computes the geographic bounding box containing all values for a Geopoint or Geoshape field.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoBoundsAggregation"
            }
          ]
        },
        "geo_centroid": {
          "description": "A metric aggregation that computes the weighted centroid from all coordinate values for geo fields.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoCentroidAggregation"
            }
          ]
        },
        "geo_distance": {
          "description": "A multi-bucket aggregation that works on `geo_point` fields.\nEvaluates the distance of each document value from an origin point and determines the buckets it belongs to, based on ranges defined in the request.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoDistanceAggregation"
            }
          ]
        },
        "geohash_grid": {
          "description": "A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid.\nEach cell is labeled using a geohash which is of user-definable precision.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoHashGridAggregation"
            }
          ]
        },
        "geo_line": {
          "description": "Aggregates all `geo_point` values within a bucket into a `LineString` ordered by the chosen sort field.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoLineAggregation"
            }
          ]
        },
        "geotile_grid": {
          "description": "A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid.\nEach cell corresponds to a map tile as used by many online map sites.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoTileGridAggregation"
            }
          ]
        },
        "geohex_grid": {
          "description": "A multi-bucket aggregation that groups `geo_point` and `geo_shape` values into buckets that represent a grid.\nEach cell corresponds to a H3 cell index and is labeled using the H3Index representation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeohexGridAggregation"
            }
          ]
        },
        "global": {
          "description": "Defines a single bucket of all the documents within the search execution context.\nThis context is defined by the indices and the document types you’re searching on, but is not influenced by the search query itself.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GlobalAggregation"
            }
          ]
        },
        "histogram": {
          "description": "A multi-bucket values source based aggregation that can be applied on numeric values or numeric range values extracted from the documents.\nIt dynamically builds fixed size (interval) buckets over the values.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.HistogramAggregation"
            }
          ]
        },
        "ip_range": {
          "description": "A multi-bucket value source based aggregation that enables the user to define a set of IP ranges - each representing a bucket.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.IpRangeAggregation"
            }
          ]
        },
        "ip_prefix": {
          "description": "A bucket aggregation that groups documents based on the network or sub-network of an IP address.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.IpPrefixAggregation"
            }
          ]
        },
        "inference": {
          "description": "A parent pipeline aggregation which loads a pre-trained model and performs inference on the collated result fields from the parent bucket aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.InferenceAggregation"
            }
          ]
        },
        "line": {
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.GeoLineAggregation"
            }
          ]
        },
        "matrix_stats": {
          "description": "A numeric aggregation that computes the following statistics over a set of document fields: `count`, `mean`, `variance`, `skewness`, `kurtosis`, `covariance`, and `covariance`.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MatrixStatsAggregation"
            }
          ]
        },
        "max": {
          "description": "A single-value metrics aggregation that returns the maximum value among the numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MaxAggregation"
            }
          ]
        },
        "max_bucket": {
          "description": "A sibling pipeline aggregation which identifies the bucket(s) with the maximum value of a specified metric in a sibling aggregation and outputs both the value and the key(s) of the bucket(s).",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MaxBucketAggregation"
            }
          ]
        },
        "median_absolute_deviation": {
          "description": "A single-value aggregation that approximates the median absolute deviation of its search results.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MedianAbsoluteDeviationAggregation"
            }
          ]
        },
        "min": {
          "description": "A single-value metrics aggregation that returns the minimum value among numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MinAggregation"
            }
          ]
        },
        "min_bucket": {
          "description": "A sibling pipeline aggregation which identifies the bucket(s) with the minimum value of a specified metric in a sibling aggregation and outputs both the value and the key(s) of the bucket(s).",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MinBucketAggregation"
            }
          ]
        },
        "missing": {
          "description": "A field data based single bucket aggregation, that creates a bucket of all documents in the current document set context that are missing a field value (effectively, missing a field or having the configured NULL value set).",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MissingAggregation"
            }
          ]
        },
        "moving_avg": {
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MovingAverageAggregation"
            }
          ]
        },
        "moving_percentiles": {
          "description": "Given an ordered series of percentiles, \"slides\" a window across those percentiles and computes cumulative percentiles.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MovingPercentilesAggregation"
            }
          ]
        },
        "moving_fn": {
          "description": "Given an ordered series of data, \"slides\" a window across the data and runs a custom script on each window of data.\nFor convenience, a number of common functions are predefined such as `min`, `max`, and moving averages.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MovingFunctionAggregation"
            }
          ]
        },
        "multi_terms": {
          "description": "A multi-bucket value source based aggregation where buckets are dynamically built - one per unique set of values.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.MultiTermsAggregation"
            }
          ]
        },
        "nested": {
          "description": "A special single bucket aggregation that enables aggregating nested documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.NestedAggregation"
            }
          ]
        },
        "normalize": {
          "description": "A parent pipeline aggregation which calculates the specific normalized/rescaled value for a specific bucket value.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.NormalizeAggregation"
            }
          ]
        },
        "parent": {
          "description": "A special single bucket aggregation that selects parent documents that have the specified type, as defined in a `join` field.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ParentAggregation"
            }
          ]
        },
        "percentile_ranks": {
          "description": "A multi-value metrics aggregation that calculates one or more percentile ranks over numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.PercentileRanksAggregation"
            }
          ]
        },
        "percentiles": {
          "description": "A multi-value metrics aggregation that calculates one or more percentiles over numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.PercentilesAggregation"
            }
          ]
        },
        "percentiles_bucket": {
          "description": "A sibling pipeline aggregation which calculates percentiles across all bucket of a specified metric in a sibling aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.PercentilesBucketAggregation"
            }
          ]
        },
        "range": {
          "description": "A multi-bucket value source based aggregation that enables the user to define a set of ranges - each representing a bucket.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.RangeAggregation"
            }
          ]
        },
        "rare_terms": {
          "description": "A multi-bucket value source based aggregation which finds \"rare\" terms — terms that are at the long-tail of the distribution and are not frequent.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.RareTermsAggregation"
            }
          ]
        },
        "rate": {
          "description": "Calculates a rate of documents or a field in each bucket.\nCan only be used inside a `date_histogram` or `composite` aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.RateAggregation"
            }
          ]
        },
        "reverse_nested": {
          "description": "A special single bucket aggregation that enables aggregating on parent documents from nested documents.\nShould only be defined inside a `nested` aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ReverseNestedAggregation"
            }
          ]
        },
        "random_sampler": {
          "description": "A single bucket aggregation that randomly includes documents in the aggregated results.\nSampling provides significant speed improvement at the cost of accuracy.",
          "x-state": "Technical preview; Added in 8.1.0",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.RandomSamplerAggregation"
            }
          ]
        },
        "sampler": {
          "description": "A filtering aggregation used to limit any sub aggregations' processing to a sample of the top-scoring documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SamplerAggregation"
            }
          ]
        },
        "scripted_metric": {
          "description": "A metric aggregation that uses scripts to provide a metric output.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ScriptedMetricAggregation"
            }
          ]
        },
        "serial_diff": {
          "description": "An aggregation that subtracts values in a time series from themselves at different time lags or periods.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SerialDifferencingAggregation"
            }
          ]
        },
        "significant_terms": {
          "description": "Returns interesting or unusual occurrences of terms in a set.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SignificantTermsAggregation"
            }
          ]
        },
        "significant_text": {
          "description": "Returns interesting or unusual occurrences of free-text terms in a set.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SignificantTextAggregation"
            }
          ]
        },
        "stats": {
          "description": "A multi-value metrics aggregation that computes stats over numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.StatsAggregation"
            }
          ]
        },
        "stats_bucket": {
          "description": "A sibling pipeline aggregation which calculates a variety of stats across all bucket of a specified metric in a sibling aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.StatsBucketAggregation"
            }
          ]
        },
        "string_stats": {
          "description": "A multi-value metrics aggregation that computes statistics over string values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.StringStatsAggregation"
            }
          ]
        },
        "sum": {
          "description": "A single-value metrics aggregation that sums numeric values that are extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SumAggregation"
            }
          ]
        },
        "sum_bucket": {
          "description": "A sibling pipeline aggregation which calculates the sum of a specified metric across all buckets in a sibling aggregation.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.SumBucketAggregation"
            }
          ]
        },
        "terms": {
          "description": "A multi-bucket value source based aggregation where buckets are dynamically built - one per unique value.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.TermsAggregation"
            }
          ]
        },
        "time_series": {
          "description": "The time series aggregation queries data created using a time series index.\nThis is typically data such as metrics or other data streams with a time component, and requires creating an index using the time series mode.",
          "x-state": "Technical preview",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.TimeSeriesAggregation"
            }
          ]
        },
        "top_hits": {
          "description": "A metric aggregation that returns the top matching documents per bucket.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.TopHitsAggregation"
            }
          ]
        },
        "t_test": {
          "description": "A metrics aggregation that performs a statistical hypothesis test in which the test statistic follows a Student’s t-distribution under the null hypothesis on numeric values extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.TTestAggregation"
            }
          ]
        },
        "top_metrics": {
          "description": "A metric aggregation that selects metrics from the document with the largest or smallest sort value.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.TopMetricsAggregation"
            }
          ]
        },
        "value_count": {
          "description": "A single-value metrics aggregation that counts the number of values that are extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.ValueCountAggregation"
            }
          ]
        },
        "weighted_avg": {
          "description": "A single-value metrics aggregation that computes the weighted average of numeric values that are extracted from the aggregated documents.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.WeightedAverageAggregation"
            }
          ]
        },
        "variable_width_histogram": {
          "description": "A multi-bucket aggregation similar to the histogram, except instead of providing an interval to use as the width of each bucket, a target number of buckets is provided.",
          "allOf": [
            {
              "$ref": "#/$defs/_types.aggregations.VariableWidthHistogramAggregation"
            }
          ]
        }
      },
      "minProperties": 1,
      "maxProperties": 1
    }
  ],
  "$defs": {
    "_global.search._types.BoundaryScanner": {
      "type": "string",
      "enum": [
        "chars",
        "sentence",
        "word"
      ]
    },
    "_global.search._types.FieldCollapse": {
      "type": "object",
      "properties": {
        "field": {
          "description": "The field to collapse the result set on",
          "allOf": [
            {
              "$ref": "#/$defs/_types.Field"
            }
          ]
        },
        "inner_hits": {
          "description": "The number of inner hits and their sort order",
          "oneOf": [
            {
              "$ref": "#/$defs/_global.search._types.InnerHits"
            },
            {
              "type": "array",
              "items": {
                "$ref": "#/$defs/_global.search._types.InnerHits"
              }
            }
          ]
        },
        "max_concurrent_group_searches": {
          "description": "The number of concurrent requests allowed to retrieve the inner_hits per group",
          "type": "number"
        },
        "collapse": {
          "allOf": [
            {
              "$ref": "#/$defs/_global.search._types.FieldCollapse"
            }
          ]
        }
      },
      "required": [
        "field"
      ]
    },
    "_global.search._types.Highlight": {
      "allOf": [
        {
          "$ref": "#/$defs/_global.search._types.HighlightBase"
        },
        {
          "type": "object",
          "properties": {
            "encoder": {
              "allOf": [
                {
                  "$ref": "#/$defs/_global.search._types.HighlighterEncoder"
                }
              ]
            },
            "fields": {
              "oneOf": [
                {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/_global.search._types.HighlightField"
                  },
                  "minProperties": 1,
                  "maxProperties": 1
                },
                {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": {
                      "$ref": "#/$defs/_global.search._types.HighlightField"
                    },
                    "minProperties": 1,
                    "maxProperties": 1
                  }
                }
              ]
            }
          },
          "required": [
            "fields"
          ]
        }
      ]
    },
    "_global.search._types.HighlightBase": {
      "type": "object",
      "properties": {
        "type": {
          "description": "\n\nSupported values include:\n  - `plain`: The `plain` highlighter uses the standard Lucene highlighter\n  - `fvh`: The fvh highlighter uses the Lucene Fast Vector highlighter.\n  - `unified`: The unified highlighter uses the Lucene Unified Highlighter.\n\n",
          "allOf": [
            {
              "$ref": "#/$defs/_global.search._types.HighlighterType"
            }
          ]
        },
        "boundary_chars": {
          "description": "A string that contains each boundary character.",
          "default": ".,!? \\t\\n",
          "type": "string"
        },
        "boundary_max_scan": {
          "description": "How far to scan for boundary characters.",
          "default": 20.0,
          "type": "number"
        },
        "boundary_scanner": {
          "description": "Specifies how to break the highlighted fragments: chars, sentence, or word.\nOnly valid for the unified and fvh highlighters.\nDefaults to `sentence` for the `unified` highlighter. Defaults to `chars` for the `fvh` highlighter.\n\nSupported values include:\n  - `chars`: Use the characters specified by `boundary_chars` as highlighting boundaries.\nThe `boundary_max_scan` setting controls how far to scan for boundary charact

# --- truncated at 32 KB (419 KB total) ---
# Full source: https://artifacts.apis.io/elastic/json-schema/elastic-types-aggregations-aggregation-container-schema.json

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/elastic-types-aggregations-aggregation-container"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.