Buy digital products programmatically and resell them in your own shop or bot.
Base URL: https://api.irmarket.store
Prefer interactive testing? Open the Swagger UI
— click Authorize, paste your anb_… key, and try every endpoint live.
Every request needs your API key — either the X-API-Key header (recommended) or a
?key= query parameter. Keys are issued by the administrator. Your purchases are paid
from your wallet balance; top up inside the Telegram bot (USDT or Rial).
curl -H "X-API-Key: anb_..." https://api.irmarket.store/api/buyer/balance
| Endpoint | Description |
|---|---|
GET/api/buyer/products | Product list with your prices and live stock |
GET/api/buyer/balance | Your wallet balance (USD) |
GET/api/buyer/me | Key info + discount |
POST/api/buyer/purchase | Buy a product; returns the delivered accounts |
GET/api/buyer/orders/{id} | Re-fetch an order's status and accounts |
POST/api/buyer/webhook | Register a callback URL for order updates |
Every product in /api/buyer/products carries both the public price and yours,
so you can show your customers what they save without hard-coding a rate:
{
"id": 364,
"name": "Gemini AI Pro 18 Month",
"retail_usd": 12.00, // public price
"price_usd": 9.00, // what YOU pay
"discount_percent": 25.0, // the rate applied to this product
"savings_usd": 3.00,
"effective_discount_percent": 25.0
}
Most products use your blanket rate (/api/buyer/me →
discount_percent), but individual products can be set to a rate of their own —
special_rate_products on /me tells you how many are. Always price from
price_usd rather than applying your blanket rate yourself: a product rate, a
promotion window, or our cost floor can all make the real number differ.
Instead of polling /orders/{id}, register a URL and we POST each order's final
state (delivered / failed) to it as JSON with an
"event": "order.updated" field. Every request is signed: the
X-Signature header is HMAC-SHA256(secret, body) — the secret is returned
once when you register. Re-registering rotates the secret; answer with any 2xx status.
curl -X POST https://api.irmarket.store/api/buyer/webhook \
-H "X-API-Key: anb_..." -H "Content-Type: application/json" \
-d '{"url": "https://your-shop.com/callback"}'
curl -X POST https://api.irmarket.store/api/buyer/purchase \
-H "X-API-Key: anb_..." -H "Content-Type: application/json" \
-d '{"product_id": 42, "quantity": 1, "idempotency_key": "my-shop-order-1001"}'
Response:
{
"success": true,
"order_id": 5130,
"status": "delivered",
"quantity": 1,
"total_usd": 4.51,
"accounts": ["[email protected] : Passw0rd (verify: [email protected])"],
"refunded": false
}
Always send an idempotency_key (your own order id, max 64 chars). If your
request times out, repeat it with the same key — you'll get the original order back instead of
being charged twice. Products flagged requires_email need a
customer_email field in the body.
An SMM service is quoted per 1000 units but ordered in raw units. Check
pricing_unit on every product before you multiply anything:
| Field | Meaning |
|---|---|
pricing_unit | "unit" for ordinary products, "per_1000" for SMM |
price_per_1000_usd | Set only when pricing_unit is per_1000 |
min_qty / max_qty | The panel's own bounds — often a minimum of 100 |
requires_link | Send link: the channel/post the order delivers to |
requires_comments | Send comments, one per line (the panel counts them) |
required_inputs | Extra keys for extras — e.g. ["smm_hashtag"] for a Mentions Hashtag service. Multi-value ones take one per line |
curl -X POST https://api.irmarket.store/api/buyer/purchase \
-H "X-API-Key: anb_..." -H "Content-Type: application/json" \
-d '{"product_id": 1949, "quantity": 5000,
"link": "https://t.me/mychannel",
"idempotency_key": "my-shop-order-1002"}'
5000 units at price_per_1000_usd of $0.18 costs $0.90 — quantity ÷ 1000 × price.
SMM orders fill over minutes to hours, so they come back processing. Poll
/api/buyer/orders/{id} for progress:
{
"order_id": 11702,
"status": "processing",
"quantity": 5000,
"start_count": 1240,
"remains": 3100,
"progress_percent": 38
}
A partially filled order is settled automatically: the delivered portion stands and the undelivered remainder is refunded to your wallet.
| Status | Meaning |
|---|---|
delivered | Done — accounts holds the credentials |
processing | Still fulfilling — poll /api/buyer/orders/{id} |
failed | Could not fulfil — if refunded is true the money is back in your wallet |
cancelled | Never charged |
| HTTP | Meaning |
|---|---|
401 | Missing/invalid/revoked API key |
402 | Insufficient wallet balance |
404 | Unknown or unavailable product/order |
409 | Not enough stock for the requested quantity |
400 | Quantity outside min_qty/max_qty, or a missing link/comments/customer_email, or an extras key named in required_inputs |
429 | Rate limit (120 requests/minute) |
Questions or a new key → contact the shop admin on Telegram.