faostat_get_data
Fetch FAOSTAT food and agriculture statistics by domain, filtering by area, item, year, and element; resolve filter codes first to query production, trade, and emissions.
Instructions
Fetch domain data. Resolve filter codes with faostat_search_codes first. Element FILTER codes differ from display codes (QCL Production: filter 2510, display 5510). Filter large queries by area/item/year; check datasize when unsure. Prefer response_format="compact" and fields to save tokens; objects and csv are supported. limit=50; 0 returns all rows. Preserve units when selecting fields.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| area | No | ||
| item | No | ||
| lang | No | en | |
| year | No | ||
| limit | No | ||
| fields | No | ||
| area_cs | No | ||
| element | No | ||
| item_cs | No | ||
| year_cs | No | ||
| show_unit | No | ||
| element_cs | No | ||
| show_codes | No | ||
| show_flags | No | ||
| domain_code | Yes | ||
| null_values | No | ||
| response_format | No | compact |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |