Skip to content

Search the docs

Jump to any page or section

REST API v3

REST API v3

A JSON API with bearer authentication, structured errors, cursor pagination and idempotent order creation. Use it for your own tooling; panels can stay on v2.

Base URL and format

GET/api/v3
  • Every path below is relative to https://ultrasmm.io/api/v3.
  • Send JSON with Content-Type: application/json. Responses are always JSON.
  • Reads are GET; anything that changes state is POST. Successful creates answer 201, everything else 200.

Authentication

Send your key as a bearer token on every request except GET /status. There is no key parameter in v3.

curl https://ultrasmm.io/api/v3/balance \
  -H 'Authorization: Bearer tk_live_your_key_here'

Keys, scopes and IP allowlists are shared with v2 — see Authentication. Each endpoint below names the scope it needs.

Errors

Failures use the HTTP status that fits (400, 401, 402, 403, 404, 409, 422, 429, 500) and always the same body. Switch on code, which never changes; show message to your staff, which says how to fix the problem.

Response409Conflict
{
  "error": {
    "code": "duplicate_active_order",
    "message": "Order 184610 for this link and service is still running. Wait for it to finish — two orders on one link make start counts unreliable.",
    "param": "link",
    "details": {
      "order": 184610
    },
    "doc_url": "/docs/errors#duplicate_active_order",
    "request_id": "req_f8xrrISYryqXQcXJ3x"
  }
}
codestring
Stable, machine-readable code. Switch on this. Every code is listed on Errors.
messagestring
What went wrong and how to fix it, in plain English. Safe to show to your staff; wording may change.
paramstring
Only when relevant
The request field at fault, when there is one (link, quantity, …).
detailsobject
Only when relevant
Extra values for some codes, for example retry_after or the conflicting order.
doc_urlstring
Where this code is documented: /docs/errors#<code>.
request_idstring
The request ID (req_…), also sent as X-Request-Id. Quote it to support.

Any endpoint that needs a key can return these, checked in this order:

Every code, with its fix, is on Errors. doc_url links straight to it.

Pagination

GET /orders and GET /transactions return newest first, a page at a time, as a list object:

List shape
{
  "object": "list",
  "data": [
    "…"
  ],
  "has_more": true,
  "next_cursor": "184610"
}
  1. Ask for up to 100 items with limit (default 25). Values outside 1–100 are clamped, not rejected.
  2. While has_more is true, pass next_cursor back as starting_after to get the next, older page.
  3. Cursors are IDs (an order ID, or a txn_… transaction ID), so pages stay stable while new items arrive.
curl "https://ultrasmm.io/api/v3/orders?limit=100&starting_after=184610" \
  -H 'Authorization: Bearer tk_live_your_key_here'

Idempotency

Networks fail after requests arrive. To retry POST /orders safely, send an Idempotency-Key header — any unique string up to 200 characters, such as your panel’s own order ID or a UUID.

  • Same key, same body: we don’t place a second order. You get the original response again (status 201 and the order as it was when created) with an Idempotent-Replayed: true header.
  • Same key, different body: refused with idempotency_conflict (409). Bodies are compared after JSON parsing, so whitespace doesn’t matter but field order and values do — resend exactly what you sent.
  • Only successful creates are remembered. If the first attempt failed (say, insufficient_funds), retrying with the same key runs the request again.
  • Keys belong to your account; two accounts can use the same string without colliding.
curl https://ultrasmm.io/api/v3/orders \
  -H 'Authorization: Bearer tk_live_your_key_here' \
  -H 'Content-Type: application/json' \
  -H 'Idempotency-Key: panel-48213' \
  -d '{
  "service": 102,
  "link": "https://www.tiktok.com/@mila.makes",
  "quantity": 1000
}'
A replayed response
HTTP/1.1 201 Created
Content-Type: application/json
Idempotent-Replayed: true
X-Request-Id: req_Q2m8VdT0aXk4LpRw1c

{"id":184610,"object":"order","status":"pending", …}

A replay has a new X-Request-Id but no Location header. To see the order’s current state, follow up with GET /orders/{id}.

Rate limit headers

Every authenticated response tells you where you stand. Each key has a bucket of 120 requests that refills at 2 per second, shared between v2 and v3.

Rate limit headers
HeaderMeaning
X-RateLimit-LimitBucket size: 120.
X-RateLimit-RemainingWhole requests left right now.
X-RateLimit-ResetSeconds until the bucket is full again. A duration, not a timestamp.
Retry-AfterOnly on 429: seconds to wait before retrying.

More on Rate limits.

Request IDs

Every response has an X-Request-Id header (req_…), repeated as request_id in error bodies. Every request with a valid key is logged with its parameters and our response in Dashboard → Request logs, searchable by that ID. Quote it when you contact support.

Money, IDs and timestamps

  • Money is a decimal string in USD: "2.20800". Charges and balances carry five decimals; service rates carry four. Parse with a decimal type, not a float.
  • Order and refill IDs are integers, the same numbers v2 uses. Transaction IDs are strings like txn_lgWDr5M6xpGd6V.
  • Timestamps are ISO 8601 in UTC: 2026-11-15T10:14:03.532Z. Fields that haven’t happened yet are null, never missing.
  • Every object has an object field (order, refill, list, …) so you can tell payloads apart.

Endpoints

ServicesThe catalog with your rates and each service’s delivery record.
System statusPublic platform and service status. No key needed.

Objects: Order, Order event, Refill, Service, Balance, Transaction, Status.

OpenAPI spec

The whole v3 API is described in OpenAPI 3.1 — every path, parameter, schema, example and error code. Import it into Postman or Insomnia, or generate a typed client.

openapi.json
/api/v3/openapi.json
Open the spec
Generate a TypeScript client
npx openapi-typescript https://ultrasmm.io/api/v3/openapi.json -o tiksmm.d.ts

Versioning

v3 changes only by adding things: new endpoints, new optional parameters, new fields on objects, new error codes and new event types. Write clients that ignore fields they don’t know. Anything that would break an existing client ships as a new version, and v2’s responses never change shape. See the changelog.

New to v3? The Create an order endpoint is the place to start.

Something unclear or out of date? Write to [email protected] and quote the page.