Разработчикам

API v2

Один эндпоинт, только POST, ответ JSON. Тот же каталог и те же цены, что в панели, с вашего сайта, бота или таблицы.

Четыре вещи, которые нужно знать сразу

01

Ваш ключ — это ваш кошелёк

Сгенерируйте его на странице аккаунта. Он разрешает списания, поэтому его место — в конфигурации сервера. Смените его, если он хоть раз попал в браузер, в чат или на скриншот.

02

Лимиты у каждой услуги свои

Минимальное и максимальное количество задаётся отдельно: одна услуга стартует с 10 единиц, следующая — с 500 000. Читайте их из services и проверяйте перед отправкой заказа.

03

Заказы списываются с баланса

Шага со счётом на оплату нет. add проходит только пока баланса хватает на заказ, поэтому опрашивайте balance и останавливайте очередь, прежде чем он дойдёт до нуля.

04

Уже есть панель? Код не нужен

PerfectPanel и большинство панельных скриптов читают этот формат нативно. В своей админке зайдите в Providers → Add provider и вставьте адрес сайтаhttps://autosmo.com/, только его, не endpoint. Добавьте свой ключ, синхронизируйте каталог, задайте наценку.

Один запрос от начала до конца

разобранный пример
оформить заказ и прочитать его обратно
curl -X POST https://autosmo.com/api/v2 \\
  -d key=YOUR_KEY \\
  -d action=add \\
  -d service=6758 \\
  -d link=https://instagram.com/yourprofile \\
  -d quantity=100

{"order": 8231455}

curl -X POST https://autosmo.com/api/v2 -d key=YOUR_KEY -d action=status -d order=8231455

{"charge": "0.016", "start_count": "2841", "status": "Completed",
 "remains": "0", "currency": "USD"}

Услуга 6758 — реальный id из каталога. Количества ниже минимума услуги отклоняются, а не округляются вверх.

Передайте это агенту

скопировать & вставить

Вставьте это в ChatGPT, Claude или Cursor, назовите свой язык — и получите рабочий клиент. Он несёт полный список вызовов плюс поведение, в котором легко ошибиться.

промпт для интеграции
Build me a client for the AutoSMO SMM API (v2), in a language I will name.

ENDPOINT
POST https://autosmo.com/api/v2 — form-encoded body, JSON response, no other verbs.
Authentication is the field `key`, sent with every call. Server-side only.

CALLS
action=services -> array of { service, name, type, category, rate (per 1000),
                              min, max, refill:bool, cancel:bool }
action=add      params: service, link, quantity [, runs, interval]  -> { "order": id }
                custom comments: service, link, comments
action=status   params: order | orders (comma separated, max 100)
                -> { charge, start_count, status, remains, currency }
action=refill   params: order | orders (max 100)   -> { "refill": id }
action=refill_status  params: refill | refills     -> { "status": ... }
action=cancel   params: orders (max 100)
action=balance                                      -> { balance, currency }

BEHAVIOUR THAT COSTS MONEY IF IGNORED
- A timed-out `add` is not a failed `add`. The order may exist and be paid for.
  Surface it for a human; do not resend it on a timer.
- Quantity outside a service's own min/max is refused outright, so read those
  bounds from the catalogue and check before sending.
- Status is polled with `orders` and up to 100 ids at once. Per-order polling
  works in testing and dies in production.
- A 200 response can still contain per-entry errors when several ids were
  requested. Walk the entries; do not trust the envelope.
- "Partial" is a delivery that stopped early: `remains` is the shortfall and
  `charge` is the real cost. Pass that difference back to your buyer.
- Refill and cancel exist only where the catalogue flags say so.

WHAT I EXPECT FROM YOU
- One function per call, with the response parsed into typed structures.
- My order reference stored next to the id this API returns.
- Two background jobs: refresh the catalogue, and follow orders still open.
- A rehearsal switch that logs calls without sending them, and a single
  end-to-end test using the cheapest service in the catalogue.

Чек-лист перед запуском в бой

Ключа нет ни в чём, что может открыть клиент

Ни во фронтенд-JavaScript, ни в мобильной сборке, ни в публичном репозитории. Любой, у кого он есть, может оформлять заказы с вашего баланса.

Таймауты ставятся в очередь на человека, а не повторяются

Поскольку у add нет ключа идемпотентности, автоматический повтор — это способ превратить один заказ клиента в два оплаченных.

Ваша копия каталога обновляется по расписанию

Тарифы, лимиты и доступность меняются, когда их меняют поставщики. Устаревшая локальная копия продаёт по ценам, которых у вас уже нет.

Частичные заказы доходят до клиента как частичные

Заведите remains в свою логику возвратов. Отметить частичную доставку как выполненную — самый быстрый способ заработать чарджбэк.

Вы провели один реальный заказ от начала до конца

Оформите самый маленький заказ, который допускает каталог, опросите его до завершения и убедитесь, что ваша сторона сходится с charge до копейки, прежде чем переключать трафик.

Полный справочник, сгенерированный панелью

API

HTTP-метод POST
URL API https://autosmo.com/api/v2
Формат ответа JSON

Service list

Parameters Description
key Your API key
action services

Пример ответа

[
    {
        "service": 1,
        "name": "Followers",
        "type": "Default",
        "category": "First Category",
        "rate": "0.90",
        "min": "50",
        "max": "10000",
        "refill": true,
        "cancel": true
    },
    {
        "service": 2,
        "name": "Comments",
        "type": "Custom Comments",
        "category": "Second Category",
        "rate": "8",
        "min": "10",
        "max": "1500",
        "refill": false,
        "cancel": true
    }
]

Add order

Пример ответа

{
    "order": 23501
}

Order status

Parameters Description
key Your API key
action status
order Order ID

Пример ответа

{
    "charge": "0.27819",
    "start_count": "3572",
    "status": "Partial",
    "remains": "157",
    "currency": "USD"
}

Multiple orders status

Parameters Description
key Your API key
action status
orders Order IDs (separated by a comma, up to 100 IDs)

Пример ответа

{
    "1": {
        "charge": "0.27819",
        "start_count": "3572",
        "status": "Partial",
        "remains": "157",
        "currency": "USD"
    },
    "10": {
        "error": "Incorrect order ID"
    },
    "100": {
        "charge": "1.44219",
        "start_count": "234",
        "status": "In progress",
        "remains": "10",
        "currency": "USD"
    }
}

Create refill

Parameters Description
key Your API key
action refill
order Order ID

Пример ответа

{
    "refill": "1"
}

Create multiple refill

Parameters Description
key Your API key
action refill
orders Order IDs (separated by a comma, up to 100 IDs)

Пример ответа

[
    {
        "order": 1,
        "refill": 1
    },
    {
        "order": 2,
        "refill": 2
    },
    {
        "order": 3,
        "refill": {
            "error": "Incorrect order ID"
        }
    }
]

Get refill status

Parameters Description
key Your API key
action refill_status
refill Refill ID

Пример ответа

{
    "status": "Completed"
}

Get multiple refill status

Parameters Description
key Your API key
action refill_status
refills Refill IDs (separated by a comma, up to 100 IDs)

Пример ответа

[
    {
        "refill": 1,
        "status": "Completed"
    },
    {
        "refill": 2,
        "status": "Rejected"
    },
    {
        "refill": 3,
        "status": {
            "error": "Refill not found"
        }
    }
]

Create cancel

Parameters Description
key Your API key
action cancel
orders Order IDs (separated by a comma, up to 100 IDs)

Пример ответа

[
    {
        "order": 9,
        "cancel": {
            "error": "Incorrect order ID"
        }
    },
    {
        "order": 2,
        "cancel": 1
    }
]

User balance

Parameters Description
key Your API key
action balance

Пример ответа

{
    "balance": "100.84292",
    "currency": "USD"
}
Пример кода на PHP