Публичный REST API v1.1 позволяет связать чекер аккаунтов, ваши внутренние таблицы или нейросеть-оркестратор напрямую с запущенными копиями Aether Instagram и Aether YouTube. Ниже — полная схема без догадок: какие права выдать ключу, какие маршруты вызывать, готовый промпт для ИИ и рабочие примеры на Python и Node.js.
1. Выпуск API-ключа и необходимые права (Scopes)
- Откройте Личный кабинет → API доступ (REST v1.1) (доступно при активной подписке).
- Выдайте новый ключ (
ae_live_*) с двумя правами доступа:account_checker— пакетная аналитика профилей черезPOST /api/v1.1/account-checker;remote— чтение статуса подключённых программ, управление группами БД, пресетами, расписанием и очередью команд.
- Передавайте ключ в каждом запросе через заголовок
Authorization: Bearer YOUR_API_KEYилиX-API-Key: YOUR_API_KEY. Полная документация доступна на /api-docs.
Безопасность: ключ отображается полностью только один раз при выпуске и хранится на сервере в виде хеша. Не публикуйтеae_live_*в открытых репозиториях — держите его в переменной окруженияAETHER_API_KEY.
2. Основные эндпоинты для сценария «прочекал → запустил»
| Метод и URL | Scope | Назначение и ключевые поля |
|---|---|---|
POST /api/v1.1/account-checker |
account_checker |
Принимает JSON {"accounts": ["@u1", ...], "platform": "auto", "force_refresh": false} (до 30 за запрос). Возвращает data.accounts[] со status, followers и блоком analytics (buckets, avg_views, avg_er_pct, zero_views_pct). |
GET /api/v1.1/remote/instances |
remote |
Список ваших ПК/серверов (фильтры ?product=ig&online=1). В ответе: instance_id, state, presets[], db_groups[], active_db_group, scheduler. |
POST /api/v1.1/remote/command |
remote |
Ставит команду в очередь (возвращает 202 и data.command_id): set_db_group, apply_preset, set_mode, set_threads, start, soft_stop, stop, restart, set_scheduler, get_logs. |
GET /api/v1.1/remote/command?id=... |
remote |
Опрос результата команды: pending / acked / done / failed / expired. |
GET / POST /api/v1.1/remote/scheduler |
remote |
Чтение или обновление недельного расписания правил (с мгновенной синхронизацией на подключённую машину). |
3. Готовый промпт для ИИ (генерация вашей связки без ошибок)
Скопируйте этот промпт в ChatGPT, Claude или локальную LLM, если хотите адаптировать пайплайн под свой Google Sheets, Notion или Telegram-триггер:
Напиши сервис автоматизации для Aether Tools REST API v1.1 (базовый URL https://aethertools.com/api/v1.1).
Авторизация: заголовок Authorization: Bearer <AETHER_API_KEY> из env. Лимит: 60 req/min.
Шаг 1: POST /account-checker с {"accounts": [...], "platform": "instagram"}.
Отбери профили, где status == "active" и analytics.avg_views >= 500 и analytics.zero_views_pct < 40.
Шаг 2: GET /remote/instances?product=ig&online=1 — выбери первую онлайн-машину с remote_enabled == true и state != "running".
Шаг 3: Поочерёдно отправь POST /remote/command и дождись status == "done" через GET /remote/command?id=<command_id>:
1) {"instance_id": ID, "command": "set_db_group", "group_name": "Valid accounts"}
2) {"instance_id": ID, "command": "apply_preset", "preset": "Warmup Balanced"}
3) {"instance_id": ID, "command": "start"}
Не придумывай несуществующих маршрутов, обрабатывай HTTP 409 и 429 с экспоненциальной паузой.
4. Рабочий скрипт на Python
import os
import time
import requests
BASE_URL = "https://aethertools.com/api/v1.1"
API_KEY = os.environ["AETHER_API_KEY"]
HEADERS = {"Authorization": f"Bearer {API_KEY}", "Content-Type": "application/json"}
def wait_command(cmd_id: int, timeout_s: int = 45) -> dict:
deadline = time.time() + timeout_s
while time.time() < deadline:
res = requests.get(f"{BASE_URL}/remote/command", params={"id": cmd_id}, headers=HEADERS, timeout=15)
res.raise_for_status()
cmd = res.json()["data"]["command"]
if cmd["status"] in ("done", "failed", "expired"):
return cmd
time.sleep(2)
raise TimeoutError(f"Command {cmd_id} timed out")
def send_and_wait(instance_id: str, command: str, **extra) -> dict:
payload = {"instance_id": instance_id, "command": command, **extra}
res = requests.post(f"{BASE_URL}/remote/command", json=payload, headers=HEADERS, timeout=15)
res.raise_for_status()
cmd_id = res.json()["data"]["command_id"]
return wait_command(cmd_id)
# 1. Пакетная проверка аккаунтов
check_res = requests.post(
f"{BASE_URL}/account-checker",
json={"accounts": ["@brand_one", "@brand_two"], "platform": "instagram"},
headers=HEADERS,
timeout=30,
)
check_res.raise_for_status()
accounts = check_res.json()["data"]["accounts"]
healthy = [
a["handle"]
for a in accounts
if a.get("status") == "active"
and (a.get("analytics") or {}).get("avg_views", 0) >= 500
]
print("Healthy profiles:", healthy)
if healthy:
# 2. Поиск свободной онлайн-машины Aether Instagram
inst_res = requests.get(
f"{BASE_URL}/remote/instances",
params={"product": "ig", "online": 1},
headers=HEADERS,
timeout=15,
)
inst_res.raise_for_status()
instances = [
i for i in inst_res.json()["data"]["instances"]
if i.get("remote_enabled") and i.get("state") in ("idle", "done")
]
if not instances:
raise RuntimeError("No idle online Aether Instagram instances available")
inst_id = instances[0]["instance_id"]
send_and_wait(inst_id, "set_db_group", group_name="Валидные аккаунты")
send_and_wait(inst_id, "set_threads", threads=4)
start_cmd = send_and_wait(inst_id, "start")
print("Run started:", start_cmd["status"], start_cmd["result_text"])
5. Аналогичный сценарий на Node.js (Fetch API)
const BASE_URL = "https://aethertools.com/api/v1.1";
const HEADERS = {
Authorization: `Bearer ${process.env.AETHER_API_KEY}`,
"Content-Type": "application/json",
};
async function api(path, options = {}) {
const res = await fetch(`${BASE_URL}${path}`, { ...options, headers: HEADERS });
const json = await res.json();
if (!res.ok || !json.ok) {
throw new Error(`${res.status} ${json.error || "api_error"}: ${json.message || ""}`);
}
return json.data;
}
async function runCommand(instanceId, command, extra = {}) {
const queued = await api("/remote/command", {
method: "POST",
body: JSON.stringify({ instance_id: instanceId, command, ...extra }),
});
for (let i = 0; i < 22; i++) {
await new Promise((r) => setTimeout(r, 2000));
const { command: cmd } = await api(`/remote/command?id=${queued.command_id}`);
if (["done", "failed", "expired"].includes(cmd.status)) return cmd;
}
throw new Error(`Command ${queued.command_id} timed out`);
}
async function main() {
const check = await api("/account-checker", {
method: "POST",
body: JSON.stringify({ accounts: ["@brand_one", "@brand_two"], platform: "auto" }),
});
const alive = check.accounts.filter((a) => a.status === "active");
if (!alive.length) return console.log("No active profiles to process.");
const { instances } = await api("/remote/instances?product=ig&online=1");
const target = instances.find((i) => i.remote_enabled && i.state !== "running");
if (!target) throw new Error("All online instances are currently busy.");
await runCommand(target.instance_id, "set_mode", { mode: "Прогрев по профилям" });
const started = await runCommand(target.instance_id, "start");
console.log("Started:", started.status, started.result_text);
}
main().catch(console.error);