डिजिटल वस्तुओं का थोक मंच

FoxReload API क्विकस्टार्ट गाइड 2026 — 10 मिनट में पहला कॉल

FoxReload API के साथ 10 मिनट में पहला सफल कॉल। X-API-Key header, /api/categories और /api/products उदाहरण, ऑर्डर बनाना।

FoxReload API क्विकस्टार्ट गाइड 2026 — 10 मिनट में पहला कॉल

यदि आप एक डिस्ट्रिब्यूटर, मार्केटप्लेस या फिनटेक प्लेटफ़ॉर्म हैं और डिजिटल गुड्स (गेम टॉप-अप, गिफ्ट कार्ड, eSIM) को थोक भाव पर खरीदना चाहते हैं — FoxReload का REST API आपको पूरे कैटलॉग तक 10 मिनट में पहुँच देता है।

यह गाइड आपको पहले सफल API कॉल तक ले जाएगी: ऑथेंटिकेशन, कैटलॉग देखना, और ऑर्डर बनाना।

आपको क्या चाहिए

  • FoxReload अकाउंट — वेबसाइट के माध्यम से रजिस्टर करें।
  • API key — डैशबोर्ड में API सेक्शन में मिलेगी।
  • HTTP क्लाइंट — curl, Postman, या आपकी पसंदीदा भाषा (Node.js, Python, Go)।

स्टेप 1: ऑथेंटिकेशन

सभी API रिक्वेस्ट्स के साथ X-API-Key हेडर भेजें:

curl https://public-api.foxreload.com/api/access/me \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

YOUR_API_KEY को डैशबोर्ड से लिए गए असली key से बदलें। Key को सुरक्षित रखें — server-side में env variable के रूप में store करें, client-side code में कभी न डालें।

सफल response:

{
  "email": "you@example.com",
  "firstName": "Arjun",
  "lastName": "Sharma",
  "isActive": true
}

स्टेप 2: Categories और Products देखें

पहले categories list करें:

curl "https://public-api.foxreload.com/api/categories/?limit=20" \
  -H "X-API-Key: YOUR_API_KEY"

फिर किसी category के products देखें (category_id_or_slug required है):

curl "https://public-api.foxreload.com/api/products/?category_id_or_slug=gaming&limit=10" \
  -H "X-API-Key: YOUR_API_KEY"

हर product में id, name, price fields हैं। Product का id वही itemId है जो ऑर्डर में use होगा।

Product search के लिए:

curl "https://public-api.foxreload.com/api/products/search?query=steam&limit=5" \
  -H "X-API-Key: YOUR_API_KEY"

स्टेप 3: Test Order (isMock)

Sandbox नहीं है। Test के लिए isMock: true use करें:

curl https://public-api.foxreload.com/api/orders \
  -X POST \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "items": [
      {
        "itemId": "product_01krgfgww8eth9xvvysd6y7r4j",
        "quantity": 1
      }
    ],
    "isMock": true
  }'

isMock: true के साथ balance debit नहीं होता — fake codes मिलते हैं। Production के लिए isMock: false (या field छोड़ दें)।

स्टेप 4: Order Status Poll करें

FoxReload में webhooks नहीं हैं। Delivery जानने के लिए polling करें:

curl https://public-api.foxreload.com/api/orders/{order_id} \
  -H "X-API-Key: YOUR_API_KEY"

जब status == "completed" हो, items[].externalData[] में codes मिलेंगे।

एरर कोड्स और हैंडलिंग

HTTP Code अर्थ क्या करें
401 Missing/invalid X-API-Key Key check करें
403 Key disabled या IP allowlist block Dashboard में key verify करें
404 Resource नहीं मिला ID/slug check करें
422 Validation error Request body check करें
429 Rate limit Exponential backoff के साथ retry
500 Server error Retry करें

Balance Top-up

ऑर्डर balance से debit होते हैं। Balance कम हो तो BalanceNotEnough error आती है। Crypto से top up करें:

curl -X POST https://public-api.foxreload.com/api/topups/crypto/ \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"chain": "TRX", "asset": "USDT", "balanceCurrency": "USD", "quoteAmount": 100}'

अगले स्टेप्स

API क्विकस्टार्ट पूरा होने के बाद:

  • Products browse/api/categories/ और /api/products/ से पूरा catalog explore करें।
  • Order polling — Reliable polling loop implement करें।
  • Balance monitoring — Low balance alerts set करें।

FoxReload पार्टनर बनकर तुरंत API key पाएं और डिजिटल गुड्स बाज़ार में अपनी रिसेलर बिज़नेस लॉन्च करें।

अक्सर पूछे जाने वाले प्रश्न

FoxReload API key कैसे मिलेगी?
Dashboard → API → नई key बनाएं। Key एक बार दिखती है — server-side environment variable में store करें, बाद में reveal नहीं होगी। Optional: key को IP allowlist से restrict करें (max 10 entries, IPs या CIDR)।
FoxReload API का rate limit क्या है?
Rate limit exceed होने पर HTTP 429 मिलती है। Exponential backoff के साथ retry करें। Specific numeric limits cite नहीं किए जाते — backoff strategy implement करें।
API से order कितनी जल्दी deliver होता है?
Order completed होने पर items[].externalData[] में codes मिलते हैं। Delivery time product और supplier पर depend करती है। GET /api/orders/{id} polling से status track करें।
क्या FoxReload का sandbox environment है?
नहीं। Sandbox नहीं है। Test orders के लिए POST /api/orders में "isMock": true भेजें — balance debit नहीं होता, fake codes मिलते हैं। Production और testing दोनों के लिए base URL https://public-api.foxreload.com ही है।
अगर delivered code customer के पास नहीं चला तो क्या करें?
FoxReload support से संपर्क करें। API में automatic replacement endpoint नहीं है। GET /api/orders/{order_id} से order detail और items[].externalData और items[].error ज़रूर check करें।
FoxReload API एक्सेस पाएं

संबंधित लेख