Overview

Foreca is a professional weather data API used by businesses worldwide, offering global forecasts, current conditions, and weather alerts with high accuracy. It uses OAuth 2.0 authentication, so you first obtain an access token and then use it in subsequent data requests. Foreca is best suited for developers who need reliable, commercial-grade weather data with global coverage.

Beginner Tip

Use the token endpoint to exchange your credentials for a bearer token, then include that token as an Authorization header in every weather data request. Tokens expire, so build token refresh logic into your app from the start.

Available Data

The kind of data this API exposes, based on its documentation. We could not call the endpoint to confirm the exact field names.

temperature
weather conditions
humidity
wind speed
forecast data
Use case: Integrate weather data into web and mobile applications

Example Response

Illustrative shape only — we were not able to call this endpoint (it requires credentials or exposes no public sample URL), so the fields below show the kind of data this API returns rather than a recorded response.

JSON Response · Illustrative
{
  "location": "Tokyo",
  "temperature": {
    "current": 22,
    "feels_like": 24,
    "min": 18,
    "max": 26
  },
  "condition": "Partly Cloudy",
  "humidity": 65,
  "wind": {
    "speed": 12,
    "direction": "NE"
  },
  "forecast": [
    {
      "date": "2025-01-16",
      "high": 25,
      "low": 17,
      "condition": "Sunny"
    }
  ]
}

Field Reference

current.temperature Current air temperature at the requested location in degrees Celsius.
current.symbolPhrase Human-readable weather description such as partly cloudy or heavy rain.
current.windSpeed Current wind speed in km/h.
current.relHumidity Relative humidity as a percentage (0-100).
current.feelsLikeTemp Feels-like temperature in degrees Celsius accounting for wind and humidity.

Implementation Example

Calls a real endpoint of this API. Replace any placeholder credentials with your own key.

Request
const url = "https://pfa.foreca.com/authorize/token?expire_hours=2";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "Authorization": "Bearer YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

Generated guidance based on this API's documentation, not observed by us. Treat it as a starting point and check against the provider's own error reference.

401 Unauthorized on data endpoint The OAuth bearer token is missing or has expired.
Re-authenticate with your credentials to obtain a new access token and include it as Authorization: Bearer YOUR_TOKEN.
Location not found The requested location ID or coordinates do not match a known Foreca location.
Use the /location/search endpoint first to find the correct location ID for your city or coordinates.
429 Too Many Requests Your plan rate limit has been exceeded.
Reduce request frequency, implement caching, or upgrade to a higher-tier subscription.

Metadata Score Breakdown

Estimated from metadata — endpoint not independently tested

This score is estimated from observable metadata — HTTPS support, authentication model, declared CORS, and documentation reachability — because the API requires authentication or exposes no publicly testable endpoint. The five-signal breakdown is only shown for live-tested APIs.

Metadata estimate · endpoint not independently tested

Technical Specifications

Auth OAuth
HTTPS REQUIRED
CORS UNKNOWN
Category Weather
Difficulty Advanced
Listing details not endpoint-verified

Related Tags

Similar APIs

View All →