Reseller API
Sell Digital Store products from your own website, bot or app. Same catalogue and prices as the shop — your customer never sees Digital Store, and you never see our suppliers.
Quickstart
- Generate an API key (Account → API Keys). Copy it once — it is shown only at creation.
- Top up your wallet — pay the admin by bank transfer, Binance Pay or USDT and the admin credits your wallet (for Telegram-linked accounts, your Telegram store wallet).
- Call
GET https://digitalstoredks.com/api/v1/productswith your key. - Create an order with
POST https://digitalstoredks.com/api/v1/orders— the price is taken from your wallet immediately. - Poll
GET https://digitalstoredks.com/api/v1/orders/{code}until the status iscompleted, then show thevalue(the delivered key / account) to your customer.
Base URL
https://digitalstoredks.com/api/v1
Authentication
Send your key in the X-API-Key header on every request. Keep it secret — anyone with the key can spend your wallet. Revoke a leaked key from API Keys and generate a new one.
curl -H "X-API-Key: sk_live_..." https://digitalstoredks.com/api/v1/account/info
Account info
GET /account/info
Your website wallet balance — the money your orders are charged from.
{\n "ok": true,\n "userId": 12,\n "balance": "32.13",\n "currency": "USD",\n "ordersEnabled": true\n}List products
GET /products
Every visible product: id, name, description, price (USD), stock, inStock, category, subcategory, warranty, delivery (instant | manual), requires_input / input_prompt when the product needs customer details.
Get one product
GET /products/{id-or-slug}
Create an order
POST /orders
Headers: X-API-Key and X-Idempotency-Key (a unique string per order — reuse it to safely retry the same order without a double charge). Body:
{\n "productId": "prod_1793988994102_94",\n "quantity": 1,\n "customerDetails": "@customername",\n "customerReference": "my-order-123"\n}customerDetails is required only when the product has requires_input: true (e.g. a Telegram username for Stars, a Gmail for CapCut credits) — send exactly what the product asks for. The wallet is charged only after the product, stock and details checks pass; if the bot order then fails, the wallet is refunded automatically.
{\n "ok": true,\n "order": {\n "orderCode": "DKS-ABC1234567",\n "productId": "prod_1793988994102_94",\n "name": "Gemini plus 6M (NO Card)",\n "quantity": 1,\n "total": "0.98",\n "currency": "USD",\n "status": "completed",\n "value": "XXXX-XXXX-XXXX"\n }\n}status is completed (delivered — value holds the goods), pending (being fulfilled — poll the order), or failed (refunded — see error).
Check an order
GET /orders/{code}
Same order object as above. Poll every 20–30 seconds while pending.
List your orders
GET /orders?limit=20
Your recent orders, newest first. limit 1–100, default 20.
Errors
All errors look like {"ok": false, "error": "code", "message": "..."}:
| HTTP | error | Meaning |
|---|---|---|
| 401 | invalid_api_key | Missing, revoked or wrong key. |
| 402 | insufficient_balance | Top up your website wallet. |
| 404 | product_not_found | No product with that id/slug. |
| 404 | order_not_found | No order with that code. |
| 409 | out_of_stock | The product is out of stock right now. |
| 400 | customer_details_required | This product needs customer details. |
| 400 | missing_product_id | Send productId. |
| 400 | invalid_quantity | quantity must be 1 or more. |
| 429 | rate_limited | Slow down — 120 requests per minute per key. |
| 500 | server_error | Something went wrong on our side — retry with the same idempotency key. |
Safe retries
Every order should carry a unique X-Idempotency-Key. Repeating a request with the same key returns the original order (with duplicate: true) instead of placing a second order or charging twice. Never reuse a key for a different order.
Rate limits
120 requests per minute per API key. Past the limit you get 429 rate_limited — wait a few seconds and retry.
Wallet top-up
The API charges your wallet — for Telegram-linked accounts that is your Telegram store wallet, the same wallet you use in Telegram. To top up, pay the admin by bank transfer, Binance Pay or USDT and the admin credits your wallet (Wallet page → ask the admin). Check your balance anytime with GET /account/info.
Digital