- Elasticsearch Guide: other versions:
- What’s new in 8.17
- Elasticsearch basics
- Quick starts
- Set up Elasticsearch
- Run Elasticsearch locally
- Installing Elasticsearch
- Configuring Elasticsearch
- Important Elasticsearch configuration
- Secure settings
- Auditing settings
- Circuit breaker settings
- Cluster-level shard allocation and routing settings
- Miscellaneous cluster settings
- Cross-cluster replication settings
- Discovery and cluster formation settings
- Data stream lifecycle settings
- Field data cache settings
- Local gateway settings
- Health Diagnostic settings
- Index lifecycle management settings
- Index management settings
- Index recovery settings
- Indexing buffer settings
- Inference settings
- License settings
- Machine learning settings
- Monitoring settings
- Node settings
- Networking
- Node query cache settings
- Path settings
- Search settings
- Security settings
- Shard request cache settings
- Snapshot and restore settings
- Transforms settings
- Thread pools
- Watcher settings
- Set JVM options
- Important system configuration
- Bootstrap Checks
- Heap size check
- File descriptor check
- Memory lock check
- Maximum number of threads check
- Max file size check
- Maximum size virtual memory check
- Maximum map count check
- Client JVM check
- Use serial collector check
- System call filter check
- OnError and OnOutOfMemoryError checks
- Early-access check
- All permission check
- Discovery configuration check
- Bootstrap Checks for X-Pack
- Starting Elasticsearch
- Stopping Elasticsearch
- Discovery and cluster formation
- Add and remove nodes in your cluster
- Full-cluster restart and rolling restart
- Remote clusters
- Plugins
- Upgrade Elasticsearch
- Index modules
- Mapping
- Dynamic mapping
- Explicit mapping
- Runtime fields
- Field data types
- Aggregate metric
- Alias
- Arrays
- Binary
- Boolean
- Completion
- Date
- Date nanoseconds
- Dense vector
- Flattened
- Geopoint
- Geoshape
- Histogram
- IP
- Join
- Keyword
- Nested
- Numeric
- Object
- Pass-through object
- Percolator
- Point
- Range
- Rank feature
- Rank features
- Search-as-you-type
- Semantic text
- Shape
- Sparse vector
- Text
- Token count
- Unsigned long
- Version
- Metadata fields
- Mapping parameters
analyzer
coerce
copy_to
doc_values
dynamic
eager_global_ordinals
enabled
format
ignore_above
index.mapping.ignore_above
ignore_malformed
index
index_options
index_phrases
index_prefixes
meta
fields
normalizer
norms
null_value
position_increment_gap
properties
search_analyzer
similarity
store
subobjects
term_vector
- Mapping limit settings
- Removal of mapping types
- Text analysis
- Overview
- Concepts
- Configure text analysis
- Built-in analyzer reference
- Tokenizer reference
- Token filter reference
- Apostrophe
- ASCII folding
- CJK bigram
- CJK width
- Classic
- Common grams
- Conditional
- Decimal digit
- Delimited payload
- Dictionary decompounder
- Edge n-gram
- Elision
- Fingerprint
- Flatten graph
- Hunspell
- Hyphenation decompounder
- Keep types
- Keep words
- Keyword marker
- Keyword repeat
- KStem
- Length
- Limit token count
- Lowercase
- MinHash
- Multiplexer
- N-gram
- Normalization
- Pattern capture
- Pattern replace
- Phonetic
- Porter stem
- Predicate script
- Remove duplicates
- Reverse
- Shingle
- Snowball
- Stemmer
- Stemmer override
- Stop
- Synonym
- Synonym graph
- Trim
- Truncate
- Unique
- Uppercase
- Word delimiter
- Word delimiter graph
- Character filters reference
- Normalizers
- Index templates
- Data streams
- Ingest pipelines
- Example: Parse logs
- Enrich your data
- Processor reference
- Append
- Attachment
- Bytes
- Circle
- Community ID
- Convert
- CSV
- Date
- Date index name
- Dissect
- Dot expander
- Drop
- Enrich
- Fail
- Fingerprint
- Foreach
- Geo-grid
- GeoIP
- Grok
- Gsub
- HTML strip
- Inference
- IP Location
- Join
- JSON
- KV
- Lowercase
- Network direction
- Pipeline
- Redact
- Registered domain
- Remove
- Rename
- Reroute
- Script
- Set
- Set security user
- Sort
- Split
- Terminate
- Trim
- Uppercase
- URL decode
- URI parts
- User agent
- Ingest pipelines in Search
- Aliases
- Search your data
- Re-ranking
- Query DSL
- Aggregations
- Bucket aggregations
- Adjacency matrix
- Auto-interval date histogram
- Categorize text
- Children
- Composite
- Date histogram
- Date range
- Diversified sampler
- Filter
- Filters
- Frequent item sets
- Geo-distance
- Geohash grid
- Geohex grid
- Geotile grid
- Global
- Histogram
- IP prefix
- IP range
- Missing
- Multi Terms
- Nested
- Parent
- Random sampler
- Range
- Rare terms
- Reverse nested
- Sampler
- Significant terms
- Significant text
- Terms
- Time series
- Variable width histogram
- Subtleties of bucketing range fields
- Metrics aggregations
- Pipeline aggregations
- Average bucket
- Bucket script
- Bucket count K-S test
- Bucket correlation
- Bucket selector
- Bucket sort
- Change point
- Cumulative cardinality
- Cumulative sum
- Derivative
- Extended stats bucket
- Inference bucket
- Max bucket
- Min bucket
- Moving function
- Moving percentiles
- Normalize
- Percentiles bucket
- Serial differencing
- Stats bucket
- Sum bucket
- Bucket aggregations
- Geospatial analysis
- Connectors
- EQL
- ES|QL
- SQL
- Overview
- Getting Started with SQL
- Conventions and Terminology
- Security
- SQL REST API
- SQL Translate API
- SQL CLI
- SQL JDBC
- SQL ODBC
- SQL Client Applications
- SQL Language
- Functions and Operators
- Comparison Operators
- Logical Operators
- Math Operators
- Cast Operators
- LIKE and RLIKE Operators
- Aggregate Functions
- Grouping Functions
- Date/Time and Interval Functions and Operators
- Full-Text Search Functions
- Mathematical Functions
- String Functions
- Type Conversion Functions
- Geo Functions
- Conditional Functions And Expressions
- System Functions
- Reserved keywords
- SQL Limitations
- Scripting
- Data management
- ILM: Manage the index lifecycle
- Tutorial: Customize built-in policies
- Tutorial: Automate rollover
- Index management in Kibana
- Overview
- Concepts
- Index lifecycle actions
- Configure a lifecycle policy
- Migrate index allocation filters to node roles
- Troubleshooting index lifecycle management errors
- Start and stop index lifecycle management
- Manage existing indices
- Skip rollover
- Restore a managed data stream or index
- Data tiers
- Autoscaling
- Monitor a cluster
- Roll up or transform your data
- Set up a cluster for high availability
- Snapshot and restore
- Secure the Elastic Stack
- Elasticsearch security principles
- Start the Elastic Stack with security enabled automatically
- Manually configure security
- Updating node security certificates
- User authentication
- Built-in users
- Service accounts
- Internal users
- Token-based authentication services
- User profiles
- Realms
- Realm chains
- Security domains
- Active Directory user authentication
- File-based user authentication
- LDAP user authentication
- Native user authentication
- OpenID Connect authentication
- PKI user authentication
- SAML authentication
- Kerberos authentication
- JWT authentication
- Integrating with other authentication systems
- Enabling anonymous access
- Looking up users without authentication
- Controlling the user cache
- Configuring SAML single-sign-on on the Elastic Stack
- Configuring single sign-on to the Elastic Stack using OpenID Connect
- User authorization
- Built-in roles
- Defining roles
- Role restriction
- Security privileges
- Document level security
- Field level security
- Granting privileges for data streams and aliases
- Mapping users and groups to roles
- Setting up field and document level security
- Submitting requests on behalf of other users
- Configuring authorization delegation
- Customizing roles and authorization
- Enable audit logging
- Restricting connections with IP filtering
- Securing clients and integrations
- Operator privileges
- Troubleshooting
- Some settings are not returned via the nodes settings API
- Authorization exceptions
- Users command fails due to extra arguments
- Users are frequently locked out of Active Directory
- Certificate verification fails for curl on Mac
- SSLHandshakeException causes connections to fail
- Common SSL/TLS exceptions
- Common Kerberos exceptions
- Common SAML issues
- Internal Server Error in Kibana
- Setup-passwords command fails due to connection failure
- Failures due to relocation of the configuration files
- Limitations
- Watcher
- Cross-cluster replication
- Data store architecture
- REST APIs
- API conventions
- Common options
- REST API compatibility
- Autoscaling APIs
- Behavioral Analytics APIs
- Compact and aligned text (CAT) APIs
- cat aliases
- cat allocation
- cat anomaly detectors
- cat component templates
- cat count
- cat data frame analytics
- cat datafeeds
- cat fielddata
- cat health
- cat indices
- cat master
- cat nodeattrs
- cat nodes
- cat pending tasks
- cat plugins
- cat recovery
- cat repositories
- cat segments
- cat shards
- cat snapshots
- cat task management
- cat templates
- cat thread pool
- cat trained model
- cat transforms
- Cluster APIs
- Cluster allocation explain
- Cluster get settings
- Cluster health
- Health
- Cluster reroute
- Cluster state
- Cluster stats
- Cluster update settings
- Nodes feature usage
- Nodes hot threads
- Nodes info
- Prevalidate node removal
- Nodes reload secure settings
- Nodes stats
- Cluster Info
- Pending cluster tasks
- Remote cluster info
- Task management
- Voting configuration exclusions
- Create or update desired nodes
- Get desired nodes
- Delete desired nodes
- Get desired balance
- Reset desired balance
- Cross-cluster replication APIs
- Connector APIs
- Create connector
- Delete connector
- Get connector
- List connectors
- Update connector API key id
- Update connector configuration
- Update connector index name
- Update connector features
- Update connector filtering
- Update connector name and description
- Update connector pipeline
- Update connector scheduling
- Update connector service type
- Create connector sync job
- Cancel connector sync job
- Delete connector sync job
- Get connector sync job
- List connector sync jobs
- Check in a connector
- Update connector error
- Update connector last sync stats
- Update connector status
- Check in connector sync job
- Claim connector sync job
- Set connector sync job error
- Set connector sync job stats
- Data stream APIs
- Document APIs
- Enrich APIs
- EQL APIs
- ES|QL APIs
- Features APIs
- Fleet APIs
- Graph explore API
- Index APIs
- Alias exists
- Aliases
- Analyze
- Analyze index disk usage
- Clear cache
- Clone index
- Close index
- Create index
- Create or update alias
- Create or update component template
- Create or update index template
- Create or update index template (legacy)
- Delete component template
- Delete dangling index
- Delete alias
- Delete index
- Delete index template
- Delete index template (legacy)
- Exists
- Field usage stats
- Flush
- Force merge
- Get alias
- Get component template
- Get field mapping
- Get index
- Get index settings
- Get index template
- Get index template (legacy)
- Get mapping
- Import dangling index
- Index recovery
- Index segments
- Index shard stores
- Index stats
- Index template exists (legacy)
- List dangling indices
- Open index
- Refresh
- Resolve index
- Resolve cluster
- Rollover
- Shrink index
- Simulate index
- Simulate template
- Split index
- Unfreeze index
- Update index settings
- Update mapping
- Index lifecycle management APIs
- Create or update lifecycle policy
- Get policy
- Delete policy
- Move to step
- Remove policy
- Retry policy
- Get index lifecycle management status
- Explain lifecycle
- Start index lifecycle management
- Stop index lifecycle management
- Migrate indices, ILM policies, and legacy, composable and component templates to data tiers routing
- Inference APIs
- Delete inference API
- Get inference API
- Perform inference API
- Create inference API
- Stream inference API
- Update inference API
- AlibabaCloud AI Search inference service
- Amazon Bedrock inference service
- Anthropic inference service
- Azure AI studio inference service
- Azure OpenAI inference service
- Cohere inference service
- Elasticsearch inference service
- ELSER inference service
- Google AI Studio inference service
- Google Vertex AI inference service
- HuggingFace inference service
- Mistral inference service
- OpenAI inference service
- Watsonx inference service
- Info API
- Ingest APIs
- Licensing APIs
- Logstash APIs
- Machine learning APIs
- Machine learning anomaly detection APIs
- Add events to calendar
- Add jobs to calendar
- Close jobs
- Create jobs
- Create calendars
- Create datafeeds
- Create filters
- Delete calendars
- Delete datafeeds
- Delete events from calendar
- Delete filters
- Delete forecasts
- Delete jobs
- Delete jobs from calendar
- Delete model snapshots
- Delete expired data
- Estimate model memory
- Flush jobs
- Forecast jobs
- Get buckets
- Get calendars
- Get categories
- Get datafeeds
- Get datafeed statistics
- Get influencers
- Get jobs
- Get job statistics
- Get model snapshots
- Get model snapshot upgrade statistics
- Get overall buckets
- Get scheduled events
- Get filters
- Get records
- Open jobs
- Post data to jobs
- Preview datafeeds
- Reset jobs
- Revert model snapshots
- Start datafeeds
- Stop datafeeds
- Update datafeeds
- Update filters
- Update jobs
- Update model snapshots
- Upgrade model snapshots
- Machine learning data frame analytics APIs
- Create data frame analytics jobs
- Delete data frame analytics jobs
- Evaluate data frame analytics
- Explain data frame analytics
- Get data frame analytics jobs
- Get data frame analytics jobs stats
- Preview data frame analytics
- Start data frame analytics jobs
- Stop data frame analytics jobs
- Update data frame analytics jobs
- Machine learning trained model APIs
- Clear trained model deployment cache
- Create or update trained model aliases
- Create part of a trained model
- Create trained models
- Create trained model vocabulary
- Delete trained model aliases
- Delete trained models
- Get trained models
- Get trained models stats
- Infer trained model
- Start trained model deployment
- Stop trained model deployment
- Update trained model deployment
- Migration APIs
- Node lifecycle APIs
- Query rules APIs
- Reload search analyzers API
- Repositories metering APIs
- Rollup APIs
- Root API
- Script APIs
- Search APIs
- Search Application APIs
- Searchable snapshots APIs
- Security APIs
- Authenticate
- Change passwords
- Clear cache
- Clear roles cache
- Clear privileges cache
- Clear API key cache
- Clear service account token caches
- Create API keys
- Create or update application privileges
- Create or update role mappings
- Create or update roles
- Bulk create or update roles API
- Bulk delete roles API
- Create or update users
- Create service account tokens
- Delegate PKI authentication
- Delete application privileges
- Delete role mappings
- Delete roles
- Delete service account token
- Delete users
- Disable users
- Enable users
- Enroll Kibana
- Enroll node
- Get API key information
- Get application privileges
- Get builtin privileges
- Get role mappings
- Get roles
- Query Role
- Get service accounts
- Get service account credentials
- Get Security settings
- Get token
- Get user privileges
- Get users
- Grant API keys
- Has privileges
- Invalidate API key
- Invalidate token
- OpenID Connect prepare authentication
- OpenID Connect authenticate
- OpenID Connect logout
- Query API key information
- Query User
- Update API key
- Update Security settings
- Bulk update API keys
- SAML prepare authentication
- SAML authenticate
- SAML logout
- SAML invalidate
- SAML complete logout
- SAML service provider metadata
- SSL certificate
- Activate user profile
- Disable user profile
- Enable user profile
- Get user profiles
- Suggest user profile
- Update user profile data
- Has privileges user profile
- Create Cross-Cluster API key
- Update Cross-Cluster API key
- Snapshot and restore APIs
- Snapshot lifecycle management APIs
- SQL APIs
- Synonyms APIs
- Text structure APIs
- Transform APIs
- Usage API
- Watcher APIs
- Definitions
- Command line tools
- elasticsearch-certgen
- elasticsearch-certutil
- elasticsearch-create-enrollment-token
- elasticsearch-croneval
- elasticsearch-keystore
- elasticsearch-node
- elasticsearch-reconfigure-node
- elasticsearch-reset-password
- elasticsearch-saml-metadata
- elasticsearch-service-tokens
- elasticsearch-setup-passwords
- elasticsearch-shard
- elasticsearch-syskeygen
- elasticsearch-users
- Optimizations
- Troubleshooting
- Fix common cluster issues
- Diagnose unassigned shards
- Add a missing tier to the system
- Allow Elasticsearch to allocate the data in the system
- Allow Elasticsearch to allocate the index
- Indices mix index allocation filters with data tiers node roles to move through data tiers
- Not enough nodes to allocate all shard replicas
- Total number of shards for an index on a single node exceeded
- Total number of shards per node has been reached
- Troubleshooting corruption
- Fix data nodes out of disk
- Fix master nodes out of disk
- Fix other role nodes out of disk
- Start index lifecycle management
- Start Snapshot Lifecycle Management
- Restore from snapshot
- Troubleshooting broken repositories
- Addressing repeated snapshot policy failures
- Troubleshooting an unstable cluster
- Troubleshooting discovery
- Troubleshooting monitoring
- Troubleshooting transforms
- Troubleshooting Watcher
- Troubleshooting searches
- Troubleshooting shards capacity health issues
- Troubleshooting an unbalanced cluster
- Capture diagnostics
- Migration guide
- Release notes
- Elasticsearch version 8.17.1
- Elasticsearch version 8.17.0
- Elasticsearch version 8.16.2
- Elasticsearch version 8.16.1
- Elasticsearch version 8.16.0
- Elasticsearch version 8.15.5
- Elasticsearch version 8.15.4
- Elasticsearch version 8.15.3
- Elasticsearch version 8.15.2
- Elasticsearch version 8.15.1
- Elasticsearch version 8.15.0
- Elasticsearch version 8.14.3
- Elasticsearch version 8.14.2
- Elasticsearch version 8.14.1
- Elasticsearch version 8.14.0
- Elasticsearch version 8.13.4
- Elasticsearch version 8.13.3
- Elasticsearch version 8.13.2
- Elasticsearch version 8.13.1
- Elasticsearch version 8.13.0
- Elasticsearch version 8.12.2
- Elasticsearch version 8.12.1
- Elasticsearch version 8.12.0
- Elasticsearch version 8.11.4
- Elasticsearch version 8.11.3
- Elasticsearch version 8.11.2
- Elasticsearch version 8.11.1
- Elasticsearch version 8.11.0
- Elasticsearch version 8.10.4
- Elasticsearch version 8.10.3
- Elasticsearch version 8.10.2
- Elasticsearch version 8.10.1
- Elasticsearch version 8.10.0
- Elasticsearch version 8.9.2
- Elasticsearch version 8.9.1
- Elasticsearch version 8.9.0
- Elasticsearch version 8.8.2
- Elasticsearch version 8.8.1
- Elasticsearch version 8.8.0
- Elasticsearch version 8.7.1
- Elasticsearch version 8.7.0
- Elasticsearch version 8.6.2
- Elasticsearch version 8.6.1
- Elasticsearch version 8.6.0
- Elasticsearch version 8.5.3
- Elasticsearch version 8.5.2
- Elasticsearch version 8.5.1
- Elasticsearch version 8.5.0
- Elasticsearch version 8.4.3
- Elasticsearch version 8.4.2
- Elasticsearch version 8.4.1
- Elasticsearch version 8.4.0
- Elasticsearch version 8.3.3
- Elasticsearch version 8.3.2
- Elasticsearch version 8.3.1
- Elasticsearch version 8.3.0
- Elasticsearch version 8.2.3
- Elasticsearch version 8.2.2
- Elasticsearch version 8.2.1
- Elasticsearch version 8.2.0
- Elasticsearch version 8.1.3
- Elasticsearch version 8.1.2
- Elasticsearch version 8.1.1
- Elasticsearch version 8.1.0
- Elasticsearch version 8.0.1
- Elasticsearch version 8.0.0
- Elasticsearch version 8.0.0-rc2
- Elasticsearch version 8.0.0-rc1
- Elasticsearch version 8.0.0-beta1
- Elasticsearch version 8.0.0-alpha2
- Elasticsearch version 8.0.0-alpha1
- Dependencies and versions
Vector tile search API
editVector tile search API
editSearches a vector tile for geospatial values. Returns results as a binary Mapbox vector tile.
resp = client.search_mvt( index="my-index", field="my-geo-field", zoom="15", x="5271", y="12710", ) print(resp)
const response = await client.searchMvt({ index: "my-index", field: "my-geo-field", zoom: 15, x: 5271, y: 12710, }); console.log(response);
GET my-index/_mvt/my-geo-field/15/5271/12710
Prerequisites
edit- Before using this API, you should be familiar with the Mapbox vector tile specification.
-
If the Elasticsearch security features are enabled, you must have the
read
index privilege for the target data stream, index, or alias. For cross-cluster search, see Remote clusters.
Path parameters
edit-
<target>
-
(Required, string) Comma-separated list of data streams, indices, or aliases to search. Supports wildcards (
*
). To search all data streams and indices, omit this parameter or use*
or_all
.To search a remote cluster, use the
<cluster>:<target>
syntax. See Search across clusters. -
<field>
-
(Required, string) Field containing geospatial values to return. Must be a
geo_point
orgeo_shape
field. The field must have doc values enabled. Cannot be a nested field.Vector tiles do not natively support geometry collections. For
geometrycollection
values in ageo_shape
field, the API returns ahits
layer feature for each element of the collection. This behavior may change in a future release. -
<zoom>
-
(Required, integer) Zoom level for the vector tile to search. Accepts
0
-29
. -
<x>
- (Required, integer) X coordinate for the vector tile to search.
-
<y>
- (Required, integer) Y coordinate for the vector tile to search.
Description
editInternally, Elasticsearch translates a vector tile search API request into a search containing:
-
A
geo_bounding_box
query on the<field>
. The query uses the<zoom>/<x>/<y>
tile as a bounding box. -
A
geotile_grid
orgeohex_grid
aggregation on the<field>
. Thegrid_agg
parameter determines the aggregation type. The aggregation uses the<zoom>/<x>/<y>
tile as a bounding box. -
Optionally, a
geo_bounds
aggregation on the<field>
. The search only includes this aggregation if theexact_bounds
parameter istrue
. -
If the optional parameter
with_labels
is true, the internal search will include a dynamic runtime field that calls thegetLabelPosition
function of the geometry doc value. This enables the generation of new point features containing suggested geometry labels, so that, for example, multi-polygons will have only one label.
For example, Elasticsearch may translate a vector tile search API request with a
grid_agg
argument of geotile
and an exact_bounds
argument of true
into the following search:
resp = client.search( index="my-index", size=10000, query={ "geo_bounding_box": { "my-geo-field": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, aggregations={ "grid": { "geotile_grid": { "field": "my-geo-field", "precision": 11, "size": 65536, "bounds": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, "bounds": { "geo_bounds": { "field": "my-geo-field", "wrap_longitude": False } } }, ) print(resp)
const response = await client.search({ index: "my-index", size: 10000, query: { geo_bounding_box: { "my-geo-field": { top_left: { lat: -40.979898069620134, lon: -45, }, bottom_right: { lat: -66.51326044311186, lon: 0, }, }, }, }, aggregations: { grid: { geotile_grid: { field: "my-geo-field", precision: 11, size: 65536, bounds: { top_left: { lat: -40.979898069620134, lon: -45, }, bottom_right: { lat: -66.51326044311186, lon: 0, }, }, }, }, bounds: { geo_bounds: { field: "my-geo-field", wrap_longitude: false, }, }, }, }); console.log(response);
GET my-index/_search { "size": 10000, "query": { "geo_bounding_box": { "my-geo-field": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, "aggregations": { "grid": { "geotile_grid": { "field": "my-geo-field", "precision": 11, "size": 65536, "bounds": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, "bounds": { "geo_bounds": { "field": "my-geo-field", "wrap_longitude": false } } } }
The API returns results as a binary Mapbox vector tile. Mapbox vector tiles are encoded as Google Protobufs (PBF). By default, the tile contains three layers:
-
A
hits
layer containing a feature for each<field>
value matching thegeo_bounding_box
query. -
An
aggs
layer containing a feature for each cell of thegeotile_grid
orgeohex_grid
. The layer only contains features for cells with matching data. -
A
meta
layer containing:- A feature containing a bounding box. By default, this is the bounding box of the tile.
-
Value ranges for any sub-aggregations on the
geotile_grid
orgeohex_grid
. - Metadata for the search.
The API only returns features that can display at its zoom level. For example, if a polygon feature has no area at its zoom level, the API omits it.
The API returns errors as UTF-8 encoded JSON.
Query parameters
editYou can specify several options for this API as either a query parameter or request body parameter. If you specify both parameters, the query parameter takes precedence.
-
exact_bounds
-
(Optional, Boolean) If
false
, themeta
layer’s feature is the bounding box of the tile. Defaults tofalse
.If
true
, themeta
layer’s feature is a bounding box resulting from ageo_bounds
aggregation. The aggregation runs on<field>
values that intersect the<zoom>/<x>/<y>
tile withwrap_longitude
set tofalse
. The resulting bounding box may be larger than the vector tile.
-
extent
-
(Optional, integer) Size, in pixels, of a side of the tile. Vector tiles are
square with equal sides. Defaults to
4096
.
-
buffer
-
(Optional, integer) Size, in pixels, of a clipping buffer outside the tile.
This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile.
Defaults to
5
.
-
grid_agg
-
(Optional, string) Aggregation used to create a grid for the
<field>
.Valid values for
grid_agg
-
geotile
(Default) -
geotile_grid
aggregation. -
geohex
-
geohex_grid
aggregation.
-
-
grid_precision
-
(Optional, integer) Precision level for cells in the
grid_agg
. Accepts0
-8
. Defaults to8
. If0
, results don’t include theaggs
layer.Grid precision for
geotile
For a
grid_agg
ofgeotile
, you can use cells in theaggs
layer as tiles for lower zoom levels.grid_precision
represents the additional zoom levels available through these cells. The final precision is computed by as follows:<zoom> + grid_precision
For example, if
<zoom>
is7
andgrid_precision
is8
, then thegeotile_grid
aggregation will use a precision of15
. The maximum final precision is29
.The
grid_precision
also determines the number of cells for the grid as follows:(2^grid_precision) x (2^grid_precision)
For example, a value of
8
divides the tile into a grid of 256 x 256 cells. Theaggs
layer only contains features for cells with matching data.Grid precision for
geohex
For a
grid_agg
ofgeohex
, Elasticsearch uses<zoom>
andgrid_precision
to calculate a final precision as follows:<zoom> + grid_precision
This precision determines the H3 resolution of the hexagonal cells produced by the
geohex
aggregation. The following table maps the H3 resolution for each precision.For example, if
<zoom>
is3
andgrid_precision
is3
, the precision is6
. At a precision of6
, hexagonal cells have an H3 resolution of2
. If<zoom>
is3
andgrid_precision
is4
, the precision is7
. At a precision of7
, hexagonal cells have an H3 resolution of3
.Precision Unique tile bins H3 resolution Unique hex bins Ratio 1
4
0
122
30.5
2
16
0
122
7.625
3
64
1
842
13.15625
4
256
1
842
3.2890625
5
1024
2
5882
5.744140625
6
4096
2
5882
1.436035156
7
16384
3
41162
2.512329102
8
65536
3
41162
0.6280822754
9
262144
4
288122
1.099098206
10
1048576
4
288122
0.2747745514
11
4194304
5
2016842
0.4808526039
12
16777216
6
14117882
0.8414913416
13
67108864
6
14117882
0.2103728354
14
268435456
7
98825162
0.3681524172
15
1073741824
8
691776122
0.644266719
16
4294967296
8
691776122
0.1610666797
17
17179869184
9
4842432842
0.2818666889
18
68719476736
10
33897029882
0.4932667053
19
274877906944
11
237279209162
0.8632167343
20
1099511627776
11
237279209162
0.2158041836
21
4398046511104
12
1660954464122
0.3776573213
22
17592186044416
13
11626681248842
0.6609003122
23
70368744177664
13
11626681248842
0.165225078
24
281474976710656
14
81386768741882
0.2891438866
25
1125899906842620
15
569707381193162
0.5060018015
26
4503599627370500
15
569707381193162
0.1265004504
27
18014398509482000
15
569707381193162
0.03162511259
28
72057594037927900
15
569707381193162
0.007906278149
29
288230376151712000
15
569707381193162
0.001976569537
Hexagonal cells don’t align perfectly on a vector tile. Some cells may intersect more than one vector tile. To compute the H3 resolution for each precision, Elasticsearch compares the average density of hexagonal bins at each resolution with the average density of tile bins at each zoom level. Elasticsearch uses the H3 resolution that is closest to the corresponding
geotile
density.
-
grid_type
-
(Optional, string) Determines the geometry type for features in the
aggs
layer. In theaggs
layer, each feature represents a cell in the grid.Valid values for
grid_type
-
grid
(Default) -
Each feature is a
Polygon
of the cell’s geometry. For agrid_agg
ofgeotile
, the feature is the cell’s bounding box. For agrid_agg
ofgeohex
, the feature is the hexagonal cell’s boundaries. -
point
-
Each feature is a
Point
that’s the centroid of the cell. -
centroid
-
Each feature is a
Point
that’s the centroid of the data within the cell. For complex geometries, the actual centroid may be outside the cell. In these cases, the feature is set to the closest point to the centroid inside the cell.
-
-
size
-
(Optional, integer) Maximum number of features to return in the
hits
layer. Accepts0
-10000
. Defaults to10000
. If0
, results don’t include thehits
layer.
-
track_total_hits
-
(Optional, integer or Boolean) Number of hits matching the query to count accurately. Defaults to
10000
.If
true
, the exact number of hits is returned at the cost of some performance. Iffalse
, the response does not include the total number of hits matching the query.
-
with_labels
-
(Optional, Boolean) If true, the hits and aggs layers will contain additional point features representing suggested label positions for the original features.
-
Point
andMultiPoint
features will have one of the points selected. -
Polygon
andMultiPolygon
features will have a single point generated, either the centroid, if it is within the polygon, or another point within the polygon selected from the sorted triangle-tree. -
LineString
features will likewise provide a roughly central point selected from the triangle-tree. - The aggregation results will provide one central point for each aggregation bucket.
All attributes from the original features will also be copied to the new label features. In addition, the new features will be distinguishable using the tag
_mvt_label_position
. -
Request body
edit-
aggs
-
(Optional, aggregation object) Sub-aggregations for the
grid_agg
. Supports the following aggregation types:-
avg
-
boxplot
-
cardinality
-
extended stats
-
max
-
median absolute deviation
-
min
-
percentile
-
percentile-rank
-
stats
-
sum
-
The aggregation names can’t start with
_mvt_
. The_mvt_
prefix is reserved for internal aggregations.
-
-
exact_bounds
-
(Optional, Boolean) If
false
, themeta
layer’s feature is the bounding box of the tile. Defaults tofalse
.If
true
, themeta
layer’s feature is a bounding box resulting from ageo_bounds
aggregation. The aggregation runs on<field>
values that intersect the<zoom>/<x>/<y>
tile withwrap_longitude
set tofalse
. The resulting bounding box may be larger than the vector tile. -
extent
-
(Optional, integer) Size, in pixels, of a side of the tile. Vector tiles are
square with equal sides. Defaults to
4096
. -
buffer
-
(Optional, integer) Size, in pixels, of a clipping buffer outside the tile.
This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile.
Defaults to
5
. -
fields
-
(Optional, array of strings and objects) Fields to return in the
hits
layer. Supports wildcards (*
).This parameter does not support fields with array values. Fields with array values may return inconsistent results.
You can specify fields in the array as a string or object.
Properties of
fields
objects-
field
-
(Required, string) Field to return. Supports wildcards (
*
). -
format
-
(Optional, string) Format for date and geospatial fields. Other field data types do not support this parameter.
date
anddate_nanos
fields accept a date format.geo_point
andgeo_shape
fields accept:-
geojson
(default) - GeoJSON
-
wkt
- Well Known Text
-
mvt(<spec>)
-
Binary Mapbox vector tile. The API returns the tile as a base64-encoded string. The
<spec>
has the format<zoom>/<x>/<y>
with two optional suffixes:@<extent>
and/or:<buffer>
. For example,2/0/1
or2/0/1@4096:5
.mvt
parameters-
<zoom>
-
(Required, integer) Zoom level for the tile. Accepts
0
-29
. -
<x>
- (Required, integer) X coordinate for the tile.
-
<y>
- (Required, integer) Y coordinate for the tile.
-
<extent>
-
(Optional, integer) Size, in pixels, of a side of the tile. Vector tiles are
square with equal sides. Defaults to
4096
. -
<buffer>
-
(Optional, integer) Size, in pixels, of a clipping buffer outside the tile.
This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile. Defaults to
5
.
-
-
-
-
grid_agg
-
(Optional, string) Aggregation used to create a grid for the
<field>
.Valid values for
grid_agg
-
geotile
(Default) -
geotile_grid
aggregation. -
geohex
-
geohex_grid
aggregation.
-
-
grid_precision
-
(Optional, integer) Precision level for cells in the
grid_agg
. Accepts0
-8
. Defaults to8
. If0
, results don’t include theaggs
layer.Grid precision for
geotile
For a
grid_agg
ofgeotile
, you can use cells in theaggs
layer as tiles for lower zoom levels.grid_precision
represents the additional zoom levels available through these cells. The final precision is computed by as follows:<zoom> + grid_precision
For example, if
<zoom>
is7
andgrid_precision
is8
, then thegeotile_grid
aggregation will use a precision of15
. The maximum final precision is29
.The
grid_precision
also determines the number of cells for the grid as follows:(2^grid_precision) x (2^grid_precision)
For example, a value of
8
divides the tile into a grid of 256 x 256 cells. Theaggs
layer only contains features for cells with matching data.Grid precision for
geohex
For a
grid_agg
ofgeohex
, Elasticsearch uses<zoom>
andgrid_precision
to calculate a final precision as follows:<zoom> + grid_precision
This precision determines the H3 resolution of the hexagonal cells produced by the
geohex
aggregation. The following table maps the H3 resolution for each precision.For example, if
<zoom>
is3
andgrid_precision
is3
, the precision is6
. At a precision of6
, hexagonal cells have an H3 resolution of2
. If<zoom>
is3
andgrid_precision
is4
, the precision is7
. At a precision of7
, hexagonal cells have an H3 resolution of3
.Precision Unique tile bins H3 resolution Unique hex bins Ratio 1
4
0
122
30.5
2
16
0
122
7.625
3
64
1
842
13.15625
4
256
1
842
3.2890625
5
1024
2
5882
5.744140625
6
4096
2
5882
1.436035156
7
16384
3
41162
2.512329102
8
65536
3
41162
0.6280822754
9
262144
4
288122
1.099098206
10
1048576
4
288122
0.2747745514
11
4194304
5
2016842
0.4808526039
12
16777216
6
14117882
0.8414913416
13
67108864
6
14117882
0.2103728354
14
268435456
7
98825162
0.3681524172
15
1073741824
8
691776122
0.644266719
16
4294967296
8
691776122
0.1610666797
17
17179869184
9
4842432842
0.2818666889
18
68719476736
10
33897029882
0.4932667053
19
274877906944
11
237279209162
0.8632167343
20
1099511627776
11
237279209162
0.2158041836
21
4398046511104
12
1660954464122
0.3776573213
22
17592186044416
13
11626681248842
0.6609003122
23
70368744177664
13
11626681248842
0.165225078
24
281474976710656
14
81386768741882
0.2891438866
25
1125899906842620
15
569707381193162
0.5060018015
26
4503599627370500
15
569707381193162
0.1265004504
27
18014398509482000
15
569707381193162
0.03162511259
28
72057594037927900
15
569707381193162
0.007906278149
29
288230376151712000
15
569707381193162
0.001976569537
Hexagonal cells don’t align perfectly on a vector tile. Some cells may intersect more than one vector tile. To compute the H3 resolution for each precision, Elasticsearch compares the average density of hexagonal bins at each resolution with the average density of tile bins at each zoom level. Elasticsearch uses the H3 resolution that is closest to the corresponding
geotile
density. -
grid_type
-
(Optional, string) Determines the geometry type for features in the
aggs
layer. In theaggs
layer, each feature represents a cell in the grid.Valid values for
grid_type
-
grid
(Default) -
Each feature is a
Polygon
of the cell’s geometry. For agrid_agg
ofgeotile
, the feature is the cell’s bounding box. For agrid_agg
ofgeohex
, the feature is the hexagonal cell’s boundaries. -
point
-
Each feature is a
Point
that’s the centroid of the cell. -
centroid
-
Each feature is a
Point
that’s the centroid of the data within the cell. For complex geometries, the actual centroid may be outside the cell. In these cases, the feature is set to the closest point to the centroid inside the cell.
-
-
query
- (Optional, object) Query DSL used to filter documents for the search.
-
runtime_mappings
-
(Optional, object of objects) Defines one or more runtime fields in the search request. These fields take precedence over mapped fields with the same name.
Properties of
runtime_mappings
objects-
<field-name>
-
(Required, object) Configuration for the runtime field. The key is the field name.
Properties of
<field-name>
-
type
-
(Required, string) Field type, which can be any of the following:
-
boolean
-
composite
-
date
-
double
-
geo_point
-
ip
-
keyword
-
long
-
lookup
-
-
script
-
(Optional, string) Painless script executed at query time. The script has access to the entire context of a document, including the original
_source
and any mapped fields plus their values.This script must include
emit
to return calculated values. For example:"script": "emit(doc['@timestamp'].value.dayOfWeekEnum.toString())"
-
-
-
size
-
(Optional, integer) Maximum number of features to return in the
hits
layer. Accepts0
-10000
. Defaults to10000
. If0
, results don’t include thehits
layer. -
sort
-
(Optional, array of sort objects) Sorts features in the
hits
layer.By default, the API calculates a bounding box for each feature. It sorts features based on this box’s diagonal length, from longest to shortest.
-
track_total_hits
-
(Optional, integer or Boolean) Number of hits matching the query to count accurately. Defaults to
10000
.If
true
, the exact number of hits is returned at the cost of some performance. Iffalse
, the response does not include the total number of hits matching the query. -
with_labels
-
(Optional, Boolean) If true, the hits and aggs layers will contain additional point features representing suggested label positions for the original features.
-
Point
andMultiPoint
features will have one of the points selected. -
Polygon
andMultiPolygon
features will have a single point generated, either the centroid, if it is within the polygon, or another point within the polygon selected from the sorted triangle-tree. -
LineString
features will likewise provide a roughly central point selected from the triangle-tree. - The aggregation results will provide one central point for each aggregation bucket.
All attributes from the original features will also be copied to the new label features. In addition, the new features will be distinguishable using the tag
_mvt_label_position
. -
Response
editReturned vector tiles contain the following data:
-
hits
-
(object) Layer containing results for the
geo_bounding_box
query.Properties of
hits
-
extent
- (integer) Size, in pixels, of a side of the tile. Vector tiles are square with equal sides.
-
version
- (integer) Major version number of the Mapbox vector tile specification.
-
features
-
(array of objects) Array of features. Contains a feature for each
<field>
value that matches thegeo_bounding_box
query.Properties of
features
objects-
geometry
-
(object) Geometry for the feature.
Properties of
geometry
-
type
-
(string) Geometry type for the feature. Valid values are:
-
UNKNOWN
-
POINT
-
LINESTRING
-
POLYGON
-
-
coordinates
- (array of integers or array of arrays) Tile coordinates for the feature.
-
-
properties
-
(object) Properties for the feature.
Properties of
properties
-
_id
-
(string) Document
_id
for the feature’s document. -
_index
- (string) Name of the index for the feature’s document.
-
<field>
-
Field value. Only returned for fields in the
fields
parameter.
-
-
type
-
(integer) Identifier for the feature’s geometry type. Values are:
-
1
(POINT
) -
2
(LINESTRING
) -
3
(POLYGON
)
-
-
-
-
aggs
-
(object) Layer containing results for the
grid_agg
aggregation and its sub-aggregations.Properties of
aggs
-
extent
- (integer) Size, in pixels, of a side of the tile. Vector tiles are square with equal sides.
-
version
- (integer) Major version number of the Mapbox vector tile specification.
-
features
-
(array of objects) Array of features. Contains a feature for each cell of the grid.
Properties of
features
objects-
geometry
-
(object) Geometry for the feature.
Properties of
geometry
-
type
-
(string) Geometry type for the feature. Valid values are:
-
UNKNOWN
-
POINT
-
LINESTRING
-
POLYGON
-
-
coordinates
- (array of integers or array of arrays) Tile coordinates for the feature.
-
-
properties
-
(object) Properties for the feature.
Properties of
properties
-
_count
- (long) Count of the cell’s documents.
-
_key
-
(string) Bucket key of the cell in the format
<zoom>/<x>/<y>
. -
<sub-aggregation>.value
-
Sub-aggregation results for the cell. Only returned for sub-aggregations in the
aggs
parameter.
-
-
type
-
(integer) Identifier for the feature’s geometry type. Values are:
-
1
(POINT
) -
2
(LINESTRING
) -
3
(POLYGON
)
-
-
-
-
meta
-
(object) Layer containing metadata for the request.
Properties of
meta
-
extent
- (integer) Size, in pixels, of a side of the tile. Vector tiles are square with equal sides.
-
version
- (integer) Major version number of the Mapbox vector tile specification.
-
features
-
(array of objects) Contains a feature for a bounding box.
Properties of
features
objects-
geometry
-
(object) Geometry for the feature.
Properties of
geometry
-
type
-
(string) Geometry type for the feature. Valid values are:
-
UNKNOWN
-
POINT
-
LINESTRING
-
POLYGON
-
-
coordinates
- (array of integers or array of arrays) Tile coordinates for the feature.
-
-
properties
-
(object) Properties for the feature.
Properties of
properties
-
_shards.failed
-
(integer) Number of shards that failed to execute the search. See the search
API’s
shards
response property. -
_shards.skipped
-
(integer) Number of shards that skipped the search. See the search
API’s
shards
response property. -
_shards.successful
-
(integer) Number of shards that executed the search successfully. See the
search API’s
shards
response property. -
_shards.total
-
(integer) Total number of shards that required querying, including unallocated
shards. See the search API’s
shards
response property. -
aggregations._count.avg
-
(float) Average
_count
value for features in theaggs
layer. -
aggregations._count.count
-
(integer) Number of unique
_count
values for features in theaggs
layer. -
aggregations._count.max
-
(float) Largest
_count
value for features in theaggs
layer. -
aggregations._count.min
-
(float) Smallest
_count
value for features in theaggs
layer. -
aggregations._count.sum
-
(float) Sum of
_count
values for features in theaggs
layer. -
aggregations.<sub-aggregation>.avg
- (float) Average value for the sub-aggregation’s results.
-
aggregations.<agg_name>.count
- (integer) Number of unique values from the sub-aggregation’s results.
-
aggregations.<agg_name>.max
- (float) Largest value from the sub-aggregation’s results.
-
aggregations.<agg_name>.min
- (float) Smallest value from the sub-aggregation’s results.
-
aggregations.<agg_name>.sum
- (float) Sum of values for the sub-aggregation’s results.
-
hits.max_score
-
(float) Highest document
_score
for the search’s hits. -
hits.total.relation
-
(string) Indicates whether
hits.total.value
is accurate or a lower bound. Possible values are:-
eq
- Accurate
-
gte
- Lower bound
-
-
hits.total.value
- (integer) Total number of hits for the search.
-
timed_out
-
(Boolean) If
true
, the search timed out before completion. Results may be partial or empty. -
took
-
(integer) Milliseconds it took Elasticsearch to run the search. See the search API’s
took
response property.
-
-
type
-
(integer) Identifier for the feature’s geometry type. Values are:
-
1
(POINT
) -
2
(LINESTRING
) -
3
(POLYGON
)
-
-
-
Examples
editThe following requests create the museum
index and add several geospatial
location
values.
resp = client.indices.create( index="museums", mappings={ "properties": { "location": { "type": "geo_point" }, "name": { "type": "keyword" }, "price": { "type": "long" }, "included": { "type": "boolean" } } }, ) print(resp) resp1 = client.bulk( index="museums", refresh=True, operations=[ { "index": { "_id": "1" } }, { "location": "POINT (4.912350 52.374081)", "name": "NEMO Science Museum", "price": 1750, "included": True }, { "index": { "_id": "2" } }, { "location": "POINT (4.901618 52.369219)", "name": "Museum Het Rembrandthuis", "price": 1500, "included": False }, { "index": { "_id": "3" } }, { "location": "POINT (4.914722 52.371667)", "name": "Nederlands Scheepvaartmuseum", "price": 1650, "included": True }, { "index": { "_id": "4" } }, { "location": "POINT (4.914722 52.371667)", "name": "Amsterdam Centre for Architecture", "price": 0, "included": True } ], ) print(resp1)
response = client.indices.create( index: 'museums', body: { mappings: { properties: { location: { type: 'geo_point' }, name: { type: 'keyword' }, price: { type: 'long' }, included: { type: 'boolean' } } } } ) puts response response = client.bulk( index: 'museums', refresh: true, body: [ { index: { _id: '1' } }, { location: 'POINT (4.912350 52.374081)', name: 'NEMO Science Museum', price: 1750, included: true }, { index: { _id: '2' } }, { location: 'POINT (4.901618 52.369219)', name: 'Museum Het Rembrandthuis', price: 1500, included: false }, { index: { _id: '3' } }, { location: 'POINT (4.914722 52.371667)', name: 'Nederlands Scheepvaartmuseum', price: 1650, included: true }, { index: { _id: '4' } }, { location: 'POINT (4.914722 52.371667)', name: 'Amsterdam Centre for Architecture', price: 0, included: true } ] ) puts response
const response = await client.indices.create({ index: "museums", mappings: { properties: { location: { type: "geo_point", }, name: { type: "keyword", }, price: { type: "long", }, included: { type: "boolean", }, }, }, }); console.log(response); const response1 = await client.bulk({ index: "museums", refresh: "true", operations: [ { index: { _id: "1", }, }, { location: "POINT (4.912350 52.374081)", name: "NEMO Science Museum", price: 1750, included: true, }, { index: { _id: "2", }, }, { location: "POINT (4.901618 52.369219)", name: "Museum Het Rembrandthuis", price: 1500, included: false, }, { index: { _id: "3", }, }, { location: "POINT (4.914722 52.371667)", name: "Nederlands Scheepvaartmuseum", price: 1650, included: true, }, { index: { _id: "4", }, }, { location: "POINT (4.914722 52.371667)", name: "Amsterdam Centre for Architecture", price: 0, included: true, }, ], }); console.log(response1);
PUT museums { "mappings": { "properties": { "location": { "type": "geo_point" }, "name": { "type": "keyword" }, "price": { "type": "long" }, "included": { "type": "boolean" } } } } POST museums/_bulk?refresh { "index": { "_id": "1" } } { "location": "POINT (4.912350 52.374081)", "name": "NEMO Science Museum", "price": 1750, "included": true } { "index": { "_id": "2" } } { "location": "POINT (4.901618 52.369219)", "name": "Museum Het Rembrandthuis", "price": 1500, "included": false } { "index": { "_id": "3" } } { "location": "POINT (4.914722 52.371667)", "name": "Nederlands Scheepvaartmuseum", "price":1650, "included": true } { "index": { "_id": "4" } } { "location": "POINT (4.914722 52.371667)", "name": "Amsterdam Centre for Architecture", "price":0, "included": true }
The following request searches the index for location
values that intersect
the 13/4207/2692
vector tile.
resp = client.search_mvt( index="museums", field="location", zoom="13", x="4207", y="2692", grid_agg="geotile", grid_precision=2, fields=[ "name", "price" ], query={ "term": { "included": True } }, aggs={ "min_price": { "min": { "field": "price" } }, "max_price": { "max": { "field": "price" } }, "avg_price": { "avg": { "field": "price" } } }, ) print(resp)
const response = await client.searchMvt({ index: "museums", field: "location", zoom: 13, x: 4207, y: 2692, grid_agg: "geotile", grid_precision: 2, fields: ["name", "price"], query: { term: { included: true, }, }, aggs: { min_price: { min: { field: "price", }, }, max_price: { max: { field: "price", }, }, avg_price: { avg: { field: "price", }, }, }, }); console.log(response);
GET museums/_mvt/location/13/4207/2692 { "grid_agg": "geotile", "grid_precision": 2, "fields": [ "name", "price" ], "query": { "term": { "included": true } }, "aggs": { "min_price": { "min": { "field": "price" } }, "max_price": { "max": { "field": "price" } }, "avg_price": { "avg": { "field": "price" } } } }
The API returns results as a binary vector tile. When decoded into JSON, the tile contains the following data:
{ "hits": { "extent": 4096, "version": 2, "features": [ { "geometry": { "type": "Point", "coordinates": [ 3208, 3864 ] }, "properties": { "_id": "1", "_index": "museums", "name": "NEMO Science Museum", "price": 1750 }, "type": 1 }, { "geometry": { "type": "Point", "coordinates": [ 3429, 3496 ] }, "properties": { "_id": "3", "_index": "museums", "name": "Nederlands Scheepvaartmuseum", "price": 1650 }, "type": 1 }, { "geometry": { "type": "Point", "coordinates": [ 3429, 3496 ] }, "properties": { "_id": "4", "_index": "museums", "name": "Amsterdam Centre for Architecture", "price": 0 }, "type": 1 } ] }, "aggs": { "extent": 4096, "version": 2, "features": [ { "geometry": { "type": "Polygon", "coordinates": [ [ [ 3072, 3072 ], [ 4096, 3072 ], [ 4096, 4096 ], [ 3072, 4096 ], [ 3072, 3072 ] ] ] }, "properties": { "_count": 3, "max_price.value": 1750.0, "min_price.value": 0.0, "avg_price.value": 1133.3333333333333 }, "type": 3 } ] }, "meta": { "extent": 4096, "version": 2, "features": [ { "geometry": { "type": "Polygon", "coordinates": [ [ [ 0, 0 ], [ 4096, 0 ], [ 4096, 4096 ], [ 0, 4096 ], [ 0, 0 ] ] ] }, "properties": { "_shards.failed": 0, "_shards.skipped": 0, "_shards.successful": 1, "_shards.total": 1, "aggregations._count.avg": 3.0, "aggregations._count.count": 1, "aggregations._count.max": 3.0, "aggregations._count.min": 3.0, "aggregations._count.sum": 3.0, "aggregations.avg_price.avg": 1133.3333333333333, "aggregations.avg_price.count": 1, "aggregations.avg_price.max": 1133.3333333333333, "aggregations.avg_price.min": 1133.3333333333333, "aggregations.avg_price.sum": 1133.3333333333333, "aggregations.max_price.avg": 1750.0, "aggregations.max_price.count": 1, "aggregations.max_price.max": 1750.0, "aggregations.max_price.min": 1750.0, "aggregations.max_price.sum": 1750.0, "aggregations.min_price.avg": 0.0, "aggregations.min_price.count": 1, "aggregations.min_price.max": 0.0, "aggregations.min_price.min": 0.0, "aggregations.min_price.sum": 0.0, "hits.max_score": 0.0, "hits.total.relation": "eq", "hits.total.value": 3, "timed_out": false, "took": 2 }, "type": 3 } ] } }
On this page