Why Catalog Import Matters
Building a digital goods storefront by hand โ copying product names, descriptions, and prices one by one โ is a one-way ticket to errors and stale listings. A programmatic catalog import means your store always reflects what the supplier actually has in stock, at the correct price, with the right metadata.
FoxReload exposes a full catalog API that returns structured product data for every SKU: Google Play Gift Cards, Apple Gift Cards, Steam Wallet codes, PSN cards, Xbox gift cards, and game top-ups. This guide shows you how to pull that data and load it into your own database or e-commerce platform.
Catalog Endpoint Overview
GET /api/v1/catalog
Authorization: Bearer YOUR_API_KEY
Optional query parameters:
| Parameter | Values | Description |
|---|---|---|
category |
google-play, apple, steam, psn, xbox |
Filter by brand |
currency |
USD, EUR, GBP, TRY, INRโฆ |
Filter by denomination currency |
region |
US, EU, TR, INโฆ |
Filter by regional card |
in_stock |
true |
Return only SKUs with available stock |
Full Catalog Response Structure
{
"updated_at": "2026-05-27T10:00:00Z",
"products": [
{
"id": "gp-usd-10",
"sku": "GP-US-10USD",
"name": "Google Play Gift Card $10 (US)",
"category": "google-play",
"brand": "Google",
"face_value": 10,
"currency": "USD",
"region": "US",
"wholesale_price": 9.10,
"stock": 450,
"image_url": "https://cdn.foxreload.com/products/gp-usd-10.png",
"description": "Redeemable on the Google Play Store in the US region.",
"delivery_type": "instant",
"tags": ["google-play", "us", "usd"]
}
],
"total": 87
}
Step 1 โ Design Your Local Schema
Before importing, map FoxReload fields to your database columns.
CREATE TABLE digital_products (
id VARCHAR(64) PRIMARY KEY, -- FoxReload product id
sku VARCHAR(64),
name VARCHAR(255),
category VARCHAR(64),
face_value DECIMAL(10,2),
currency CHAR(3),
region VARCHAR(10),
cost_price DECIMAL(10,2), -- wholesale_price from API
retail_price DECIMAL(10,2), -- your markup applied here
stock INT,
image_url TEXT,
description TEXT,
active BOOLEAN DEFAULT TRUE,
synced_at TIMESTAMP
);
Step 2 โ Initial Bulk Import
Run this once to populate your catalog from scratch.
import requests, os, psycopg2
from datetime import datetime
API_KEY = os.environ["FOXRELOAD_API_KEY"]
BASE_URL = "https://api.foxreload.com/api/v1"
MARGIN = 1.15 # 15% markup
headers = {"Authorization": f"Bearer {API_KEY}"}
def fetch_all_products():
r = requests.get(f"{BASE_URL}/catalog", headers=headers,
params={"in_stock": "true"})
r.raise_for_status()
return r.json()["products"]
def compute_retail(wholesale):
return round(wholesale * MARGIN, 2)
def import_products(conn, products):
cur = conn.cursor()
for p in products:
cur.execute("""
INSERT INTO digital_products
(id, sku, name, category, face_value, currency, region,
cost_price, retail_price, stock, image_url, description, synced_at)
VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s)
ON CONFLICT (id) DO UPDATE SET
cost_price=EXCLUDED.cost_price,
retail_price=EXCLUDED.retail_price,
stock=EXCLUDED.stock,
synced_at=EXCLUDED.synced_at
""", (
p["id"], p["sku"], p["name"], p["category"],
p["face_value"], p["currency"], p["region"],
p["wholesale_price"], compute_retail(p["wholesale_price"]),
p["stock"], p["image_url"], p["description"],
datetime.utcnow()
))
conn.commit()
conn = psycopg2.connect(os.environ["DATABASE_URL"])
products = fetch_all_products()
import_products(conn, products)
print(f"Imported {len(products)} products.")
Step 3 โ Schedule Incremental Syncs
After the initial import, run a lightweight sync job every 15 minutes to refresh stock and prices.
# cron: */15 * * * * python sync_catalog.py
def sync_catalog():
products = fetch_all_products()
import_products(conn, products)
# Deactivate products no longer in supplier catalog
supplier_ids = {p["id"] for p in products}
cur = conn.cursor()
cur.execute(
"UPDATE digital_products SET active=FALSE WHERE id != ALL(%s)",
(list(supplier_ids),)
)
conn.commit()
Step 4 โ Enrich Your Catalog
The FoxReload catalog gives you the essential data. Add your own layer on top:
- SEO slugs โ generate URL-friendly slugs from
name - Translations โ store product names in multiple languages
- Categories tree โ group by brand and denomination
- Featured flags โ promote high-margin or trending cards
Step 5 โ Display Catalog in Your Storefront
Query active products and render them in your front end.
# Flask example
@app.route("/shop/google-play")
def google_play_shop():
cur.execute("""
SELECT id, name, face_value, currency, retail_price, stock, image_url
FROM digital_products
WHERE category='google-play' AND active=TRUE AND stock > 0
ORDER BY face_value ASC
""")
products = cur.fetchall()
return render_template("shop.html", products=products)
Common Import Mistakes to Avoid
- Importing out-of-stock items โ always filter
stock > 0before displaying - Hardcoding prices โ re-sync prices hourly; wholesale costs change
- Skipping the
regionfield โ selling a Turkish card to a US customer leads to redemption failures - Not handling pagination โ if the catalog grows beyond 100 items, implement
offset/limitpagination
What Comes Next
Once your catalog is imported and syncing, you're ready to:
- Set up order placement when a customer buys a product
- Configure instant code delivery via webhooks
- Build price-update automation tied to supplier cost changes
See Also
- How to connect Google Play Gift Cards to your shop via API
- How to auto-update Google Play Gift Card prices
- How to manage Google Play code inventory
Ready to fill your store? Pull the full FoxReload catalog via API and launch your digital goods shop in hours.

