egdata API

Request essentials

Choose a country and locale, page through results, and handle errors.

Country and region

Country-aware endpoints accept a two-letter country query parameter, such as US, GB, or ES. The API maps the country to an Epic pricing region. Where a country is omitted, many storefront routes use the EGDATA_COUNTRY cookie or default to US; pass country explicitly for predictable server-to-server requests. Unsupported countries can return 404.

Locale

Offer endpoints accept locale; an omitted or blank value defaults to en-US. Locale syntax is validated and an invalid value returns 400. Localization uses exact locale matches: es-MX does not fall back to es-ES. When the requested translation is missing for an offer, its text remains in canonical en-US and the offer includes localeStatus: "fallback". Only public offer text and content fields are localized. Prices, availability, assets, builds, and other operational data remain canonical.

{
  "title": "Example Game",
  "locale": "es-MX",
  "localeStatus": "fallback",
  "canonicalLocale": "en-US"
}

Pagination

Pagination is route-specific. Search and profile connections use 1-based page values. Search limit defaults to 10 and is capped at 100; free-game history caps limit at 25; changelog lists cap it at 50. Some endpoints use offset or another cursor. Check the endpoint's reference for its parameter names and maximum. Follow hasNextPage, totalPages, or equivalent metadata when the endpoint returns it.

Errors

Check response.ok or the status code before treating a response as data. Many errors have a JSON message or error field; its shape can vary by route.

For example, an offer may return canonical English text when the exact requested locale is unavailable:

const response = await fetch(
  "https://api.egdata.app/offers/offer-id?country=GB&locale=es-MX",
);
const response = await fetch(url);
if (!response.ok) {
  const detail = await response.json().catch(() => null);
  throw new Error(`Request failed (${response.status}): ${detail?.message ?? ""}`);
}
const data = await response.json();

Common statuses are 400 for invalid input, 404 for missing or unavailable data, 429 for rate limiting, and 5xx for a server or upstream failure. Treat nullable fields as optional and ignore response fields your client does not use.

On this page