Empty arrays hide missing data
An empty array in a JSON payload conveys "no items" but provides no context. For a sports data API, that could mean the competition truly has no matches in the queried window, or it could mean the API chose not to serve data for that competition.
Because the OpenFoot API covers 75 competitions, some may be excluded from a particular request due to plan limits, licensing, or other policy reasons. Returning an empty array without explanation forces the client to guess, which can lead to silent data gaps in downstream applications.
Client‑side handling strategy
First, inspect the response metadata. If `meta.unavailable` is present, log the competition identifier and the supplied reason, then continue processing any other data that was returned.
If the response contains an empty array **without** a `meta.unavailable` entry, interpret it as a genuine lack of matches for the requested window. This situation is common for the default `/v1/matches` query, which only covers today ± three days as described in `meta.scope.window`.
Testing and monitoring
Implement automated tests that simulate both scenarios: an empty array with `meta.unavailable` and an empty array without it. Verify that your client distinguishes the two paths and that it respects quota limits, handling HTTP 429 by backing off until the quota resets on the 1st of the month (UTC).
Monitoring should also capture any 403 responses with `plan_upgrade_required`. Those indicate that the client is requesting a feature—such as lineups, live events, or Expected Goals—that is not part of the current subscription and will need a plan change.
Frequently asked questions
What does an empty array mean in an OpenFoot response?
It can mean either that there are no items for the requested filter, or that the API deliberately omitted a competition. The difference is clarified by the presence or absence of a `meta.unavailable` entry.
How can I tell if a competition was deliberately omitted?
Check the top‑level `meta.unavailable` array. If the competition identifier appears there, the API has supplied a reason for the omission.
Should I retry when I see `meta.unavailable`?
No. `meta.unavailable` is not an error condition; it signals a business decision. Retrying will return the same result. Instead, handle the omission gracefully and consider whether a higher‑tier plan is required.
Sources and further reading
Product descriptions and examples were checked against the OpenFootAPI v1 contract on 1 September 2026.