---
name: usda-fas-export-sales-api-ingestion
description: "How to get USDA FAS Export Sales Reporting API data into a pandas DataFrame and Parquet: access, the request, the format, limits, quirks and terms."
---

# Load USDA export-sales records into pandas and Parquet

Source entry: https://signal-lab-jet.vercel.app/datasets/usda-fas-export-sales-api
Provider: https://apps.fas.usda.gov/opendataweb/home
Checked against the provider's documentation: 2026-11-01

## Access
- Obtain a free api.data.gov key through the FAS portal signup form.
- Set the key in FAS_API_KEY and send it in the API_KEY header.

## Request
```bash
curl 'https://apps.fas.usda.gov/OpenData/api/esr/exports/commodityCode/104/allCountries/marketYear/2025' -H "API_KEY: $FAS_API_KEY" -H 'Accept: application/json'
```

## Format
JSON array or XML response of weekly U.S. export-sales records for one commodity and market year across destination countries.

## Load into pandas and Parquet
Needs Python 3 with requests, pandas and pyarrow.
```python
"""USDA FAS weekly export-sales records -> pandas -> Parquet."""
import os
import requests
import pandas as pd

URL = "https://apps.fas.usda.gov/OpenData/api/esr/exports/commodityCode/104/allCountries/marketYear/2025"
headers = {"API_KEY": os.environ["FAS_API_KEY"], "Accept": "application/json"}
r = requests.get(URL, headers=headers, timeout=60)
r.raise_for_status()
df = pd.json_normalize(r.json())
df.to_parquet("usda_fas_export_sales_104_2025.parquet", index=False)
print(len(df), "export-sales rows", len(df.columns), "columns")
```
Not run: it needs a free API key.

## Limits
- Rate limit: Not stated.
- Export-data routes select one commodity and market year, optionally narrowed to one country.
- The portal states no numeric response cap.

## Quirks
- Market-year definitions differ by commodity; retain the reported market year and week fields.
- Country, commodity and unit labels are supplied by separate lookup endpoints.
- Release dates are commodity-specific because revisions can affect more than one year.

## Terms and attribution
- Access or use of the FAS API constitutes acceptance of its terms.
- FAS permits services that search, display, analyze, retrieve and view its API data.
- Do not alter or falsely represent content and still claim FAS as the source.
- Terms page: https://apps.fas.usda.gov/opendataweb/home

## Sources
- https://apps.fas.usda.gov/opendatawebV2/main.6da18f8b4fa8a2baed40.js: "USDA's Export Sales Reporting Program monitors U.S. agricultural export sales on a daily and weekly basis."
- https://apps.fas.usda.gov/opendatawebV2/main.6da18f8b4fa8a2baed40.js: "Export sales reporting provides a constant stream of up-to-date market information for 40 U.S. agricultural commodities sold abroad."
- https://apps.fas.usda.gov/opendata/swagger/docs/v1: "Please note that there could be revision on the Export numbers for multiple years on a given commodity"

## Help improve this skill
Missing a source, or see something to improve? Call the MCP tool suggest_source or feedback (or POST /api/suggest or /api/feedback). Reviewed ideas: https://signal-lab-jet.vercel.app/agent-suggestions

Information for educational purposes only. Free tiers, limits and licenses belong to the providers and may change; check the provider's own terms before using the data.
