Examples

Request Examples

Ready-to-use cURL snippets. Replace YOUR_API_KEY with your key from the dashboard.

Browse Resorts

Fetch European resorts sorted by fresh snow, most snowfall first.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/resorts?continent=Europe&sortBy=snowfall24hCm&sortOrder=desc&limit=10"

Compare Two Resorts

Side-by-side comparison of conditions, trails, lifts, and weather.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/resorts/niseko-united/compare?with=whistler-blackcomb"

Top Snow Right Now

Find the resorts with the highest fresh snowfall in the last 24 hours.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/conditions/top-snow?limit=5"

Storm Watch

Get resorts with significant incoming snowfall — useful for planning ahead.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/conditions/storm-watch?limit=5"

Open Now

Resorts where at least 70% of trails are currently open.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/conditions/open-now?minOpenTrailsPct=70"

Resort Weather Forecast

7-day weather forecast for a specific resort.

curl -H "x-api-key: YOUR_API_KEY" \
  "https://apibarn.com/v1/ski-resort/api/resorts/whistler-blackcomb/weather"

API Health

Check API status — no key required.

curl "https://apibarn.com/v1/ski-resort/health"