Query Layer
query_layerQuery an ArcGIS Feature Service / Map Service layer by its url (from search_datasets). SQL-like where, comma-separated out_fields, order_by, limit, offset. Returns attribute rows (and geometry). Use where="1=1" + out_fields="*" to sample.
Example tool call
This call uses example arguments supplied in the tool’s input schema.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"url": "https://services.arcgis.com/dukes-county/arcgis/rest/services/Parcels/FeatureServer/0",
"limit": 50,
"where": "1=1",
"out_fields": "*"
},
"name": "query_layer"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | Feature/Map Service layer url ending in /FeatureServer/<n> or /MapServer/<n>. | |
| limit | No | Max features (1-2000, default 50). | |
| where | No | SQL where clause, e.g. "STATE = 'CA' AND YEAR >= 2020". Default "1=1". | |
| offset | No | Pagination offset. | |
| order_by | No | e.g. "POP DESC". | |
| out_fields | No | Comma-separated field names, or "*" for all (default). |