How to Connect a Digital Goods Catalog to a Marketplace
Short Answer
Connecting digital goods to a marketplace means integrating a supplier API into your existing marketplace infrastructure to add gift cards, game top-ups, and similar products as a new category. The integration has three phases: catalog import (pull products from supplier and create listings), order flow (trigger supplier API on purchase), and stock management (keep listings in sync with supplier availability). The technical work is a one-time build; ongoing operations are automated.
Definition: Connecting a digital goods catalog to a marketplace means using a wholesale supplier's API to populate a new product category, automatically fulfill orders, and maintain accurate stock and pricing β without the marketplace operator handling any physical inventory.
Key takeaway: Digital goods are the most backend-integration-friendly product category for marketplace expansion. No warehouse, no logistics, no returns process. The entire fulfillment chain is: API call in β code out. The complexity is in catalog management (region accuracy, naming, pricing) and order flow reliability β not in physical operations.
Who This Guide Is For
- Marketplace operators adding digital goods as a new product category
- Developers integrating a digital goods supplier API into an existing platform
- Product managers defining the integration requirements for digital goods
Integration Architecture Overview
Marketplace Supplier API
β β
ββ Phase 1: Catalog Import ββββββΆ GET /api/products/?category_id_or_slug=...
β Pull all products Returns product ids, names, prices, regions
β Create marketplace listings (run daily or on change)
β β
ββ Phase 2: Stock Sync ββββββββββΆ GET /api/products/{id_or_slug}
β Check before showing product Availability reflected in product data
β (real-time on product page) β
β β
ββ Phase 3: Order Flow ββββββββββΆ POST /api/orders/
β Buyer completes checkout { "items": [{ "itemId": "product_01k...", "quantity": N }] }
β Marketplace deducts payment β
β βββββββ€ { order_id, items[].externalData when completed }
β Deliver code to buyer β
β β
ββ Phase 4: Reconciliation ββββββΆ GET /api/orders/?statuses=completed&limit=200&offset=0
Daily finance export Paginate to reconcile all completed orders
Phase 1: Catalog Import
What the API Returns
A typical supplier catalog endpoint returns:
{
"results": [
{
"id": "product_01krgfgww8eth9xvvysd6y7r4j",
"name": "Steam Gift Card $20",
"region": "US",
"currency": "USD",
"face_value": 20.00,
"price": 18.40,
"category": "gaming",
"available": true
}
]
}
How to Map to Marketplace Listings
| Supplier Field | Marketplace Listing Field |
|---|---|
| name + region | Product title ("Steam Gift Card $20 β US") |
| id | Internal reference (store product id as itemId for order placement) |
| face_value | Display price |
| price | Your cost (internal; set your retail price above this) |
| category | Marketplace category ("Gift Cards" β "Gaming") |
| region | Product attribute; used for filtering |
Rules:
- One marketplace listing per supplier product id β no merging
- Include region in the product title always
- Store the supplier product
idin your database to use asitemIdwhen placing orders
Catalog Update Schedule
| Trigger | Action |
|---|---|
| Daily scheduled job | Pull full catalog via GET /api/products/?category_id_or_slug=...; update prices; deactivate removed products |
| Stock change (polling) | Poll product data on a schedule; FoxReload does not send webhook stock updates β availability is in the product listing |
| Pre-order check | GET /api/products/{id_or_slug} before displaying "Add to Cart" β availability is reflected in the product |
Phase 2: Stock Management
Show only in-stock products to buyers. Check availability at two points:
- Product listing page load β query
GET /api/products/{id_or_slug}to show "In Stock" or "Currently Unavailable" (availability is reflected in the product data) - Checkout initiation β check availability again; block checkout if out of stock since page load
GET /api/products/steam-20-usd
β { "id": "product_01k...", "name": "Steam Gift Card $20", "available": true, ... }
Cache product responses for 5β15 minutes (not longer) to reduce API load while staying current.
Phase 3: Order Flow
When a buyer completes checkout:
1. Marketplace confirms payment (buyer charged)
2. Call POST /api/orders/ with { "items": [{ "itemId": "product_01k...", "quantity": N }] }
3. Receive codes in response (synchronous) or by polling GET /api/orders/{order_id} until completed (FoxReload has no webhooks); codes are in items[].externalData
4. Store order_id and codes in your database
5. Deliver code to buyer (in-app notification, email, or order history page)
6. Mark order as completed
Error handling:
| Scenario | Response |
|---|---|
| Supplier API timeout | Retry once after 5 seconds; if failed, queue for manual review |
| Out of stock at order time | Refund buyer; notify out of stock; remove listing temporarily |
| Code delivery failed | Do not mark order complete; trigger alert; process manually |
| Order returned invalid code | Submit supplier claim; issue replacement or refund to buyer |
Phase 4: Reconciliation
Pull order history from supplier API daily for finance reconciliation:
GET /api/orders/?statuses=completed&limit=200&offset=0
β [ { order_id, items, timestamp }, ... ] (paginate with offset to cover full period)
Match against your marketplace transaction records. Discrepancies require investigation.
Pricing Strategy for Marketplace Digital Goods
Set retail price above wholesale cost + marketplace commission + payment fee + target margin:
Retail price = Wholesale Γ· (1 β marketplace_commission% β payment_fee% β target_margin%)
Example (marketplace 10% commission, card payment 2.5%, target margin 5%):
Retail = $18.40 Γ· (1 β 0.10 β 0.025 β 0.05)
Retail = $18.40 Γ· 0.825
Retail = $22.30
Verify that this retail price is competitive. If it is not, either negotiate better wholesale pricing or evaluate whether this channel is viable for this product.
Catalog Size Recommendations
Start focused; expand after validating the integration:
| Phase | Products to List |
|---|---|
| Launch | 20β30 high-demand SKUs (top Steam, PSN, Google Play denominations in your primary region) |
| Month 2β3 | Expand to full regional variants for top platforms |
| Month 4+ | Add mobile top-ups, streaming, Amazon, Nintendo |
Starting with 200 SKUs before validating the fulfillment flow creates debugging complexity. Start narrow; scale after the pipeline is proven.
Technical Checklist
Catalog:
- Supplier API credentials configured in production environment
- Catalog import job scheduled (daily minimum) via
GET /api/products/?category_id_or_slug=... - Each supplier product id (
itemId) mapped 1:1 to marketplace listing - Region included in product title for all regional products
- Retail price calculated with margin formula applied per product
Availability:
- Availability check (
GET /api/products/{id_or_slug}) implemented on product page load - Availability check implemented at checkout initiation
- Cache TTL set to 5β15 minutes
- Unavailable products hidden or marked unavailable
Orders:
- Order creation call triggered on payment confirmation (not on payment initiation)
- Supplier order ID stored in your order database
- Code delivered to buyer on order completion
- Error states handled: timeout, failure, out-of-stock
- Alert configured for order failures exceeding threshold
Finance:
- Daily reconciliation job against supplier order API
- Discrepancy alerting configured
- Wholesale cost recorded per order for margin reporting
