Overview
This API lets you browse the catalog, place orders and follow them from your own website, app or bot — the same things you can do in the store, using your store account and wallet balance.
Base URL — the domain of the store where your account is registered, followed by /api:
{BASE_URL} = https://<store-domain>/api
All requests and responses are JSON over HTTPS. Send these headers on every request:
| Header | Value | |
|---|---|---|
Accept | application/json | Required |
Content-Type | application/json | For POST requests |
Authorization | Bearer {token} | For endpoints marked “Bearer token” |
Accept-Language | en, ar, tr, ku | Optional — language of names and messages |
Response envelope — every response has the same shape:
{
"success": true,
"message": "Human-readable message",
"data": { ... }
}
The login endpoints use { "status", "message", "data", "token" } instead. Prices and amounts are returned in your account currency.
Authentication
- Call
POST {BASE_URL}/loginwith the email (or phone) and password of your store account. - Keep the
tokenfrom the response and send it asAuthorization: Bearer {token}on every protected request. - The token stays valid until you call
POST {BASE_URL}/logoutor change your password. Do not log in before every request.
/login answers 403 with "two_factor_required": true and a "challenge_token". Send challenge_token and code (the 6-digit code from the authenticator app) to POST {BASE_URL}/auth/two-factor to receive the login token. For an automated integration, use an account without 2FA and keep its password safe.Keep the token secret, like a password. Never put it in a public website or app.
Placing an order
- Find the product — browse
GET /services→GET /services/{id}/children(sub-categories) →GET /services/{id}/variants, or search withGET /search?search=…. The product to buy is a variant; keep itsid. - Read its fields —
GET /service-variants/{id}returnsfields: the inputs this product needs (for example a player ID or an IMEI). Each field has akeyandrequired. - Buy —
POST /orders/buy-nowwithservice_variant_id,quantityand the field values inmetadata.provider_inputs, using the exactkeyof each field. The price is taken from your wallet. - Follow the result — many products are delivered within seconds; others take longer. Poll
GET /orders/{id}(every 30–60 seconds is enough) until each line iscompletedorfailed. - Read the result — on a completed line, codes / PINs / the result text are in
fulfillment_deliverables(andcodesfor instant stock products). On a failed line,customer_failure_reasonsays why; the amount is returned to your wallet automatically.
pending or processing is still being handled — do not order it again, or it may be delivered twice.Order statuses
| Line status | Meaning |
|---|---|
pending | Received, not started yet. |
processing | Being executed. Keep polling. |
completed | Delivered. Read fulfillment_deliverables / codes. |
failed | Not delivered. See customer_failure_reason. The amount is refunded to the wallet. |
The order itself has a summary status: pending, completed, partial (some lines failed) or failed.
Each line also has execution_seconds (how long it took) and resolved_at once it is finished.
Errors
| HTTP | Meaning |
|---|---|
200 / 201 | OK. For buy-now, 201 = delivered immediately, 200 = accepted and still processing. |
400 | The order could not be placed (for example the product is unavailable). Read message. |
401 | Missing or expired token — log in again. |
403 | Not allowed (or two-factor code required at login). |
404 | Not found (wrong id, or the order belongs to another account). |
422 | Invalid input. errors lists the problem per field (for example not enough balance or a missing required field). |
429 | Too many requests — slow down and retry later. |
500 | Server error — retry later. If you were placing an order, check GET /orders before ordering again. |
{
"message": "The given data was invalid.",
"errors": { "quantity": ["The quantity field is required."] }
}