API Docs https://aiatera.online

Aiatera API Documentation

Official REST API for integrating Aiatera digital products, automated ordering, and wallet management into your applications.

Base URL: https://aiatera.online

Introduction

The Aiatera API gives you programmatic access to live product catalogs, stock levels, automated ordering, and wallet operations. All requests and responses use JSON. All endpoints are served over HTTPS — plain HTTP is not supported.

Authentication

Authenticate every request with your secret API key, available in the API Key dashboard page. Send it in the X-API-Key header:

X-API-Key: your-api-key-here

Alternatively, a Bearer token format is accepted:

Authorization: Bearer your-api-key-here
⚠️
Keep your API key secret. Never expose it in client-side code, public repositories, or logs. If a key is compromised, regenerate it immediately from the dashboard — the old key stops working instantly.

Rate Limits

ScopeLimitWindow
All API endpoints100 requests15 minutes / IP
Order creation5 requests1 minute / user
Sensitive actions (password, key regen, topup)10 requests15 minutes / user
Authentication endpoints20 requests15 minutes / IP

When you exceed a limit, the API returns 429 Too Many Requests. Back off and retry after the window resets.

Error Codes

HTTPerrorMeaning
400invalidProductMissing or malformed productId
400outOfStockProduct currently out of stock
400insufficientBalanceWallet balance too low for this order
401unauthorizedNo credentials provided
401invalidApiKeyAPI key is wrong or was regenerated
403forbiddenAdmin-only endpoint with non-admin credentials
404productNotFoundProduct ID does not exist in the catalog
429—Rate limit exceeded
500serverErrorUnexpected server error — retry later
ℹ️
Prices are always verified server-side. Any price value sent by the client is ignored — the authoritative catalog price is charged.

Products

GET/api/supplier/products

Returns the full merged catalog with live stock and pricing from all connected suppliers.

curl -s "https://aiatera.online/api/supplier/products" \
  -H "X-API-Key: your-api-key"
{
  "products": [
    {
      "id": "elevenlabs_creator_3_months",
      "name": "ElevenLabs Creator — 3 Months",
      "category": "ai_chat",
      "price": 13.0,
      "originalPrice": 18.2,
      "inStock": true,
      "stock": 42,
      "supplier": "dc"
    }
  ]
}
GET/api/supplier/products/:id

Returns a single product by ID with full details: description, features, stock and price.

curl -s "https://aiatera.online/api/supplier/products/elevenlabs_creator_3_months" \
  -H "X-API-Key: your-api-key"
GET/api/supplier/stock

Lightweight live-stock snapshot. Cache TTL is ~90 seconds — poll no faster than that.

Orders

POST/api/supplier/orders

Places an order and deducts the wallet balance atomically. Processing is automatic — typically seconds.

FieldTypeRequiredDescription
productIdstringrequiredProduct ID from the catalog (max 128 chars)
pricenumberignoredServer always charges the authoritative catalog price
curl -s -X POST "https://aiatera.online/api/supplier/orders" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: your-api-key" \
  -d '{"productId": "elevenlabs_creator_3_months"}'
{
  "success": true,
  "order": {
    "id": "8f2c1a9e-...",
    "productId": "elevenlabs_creator_3_months",
    "amount": 13.0,
    "status": "processing"
  }
}
GET/api/supplier/orders/:id/status

Fetches the latest fulfillment status and delivered credentials for an order. Status values: pending → processing → success / failed. Failed orders are auto-refunded to the wallet.

GET/api/user/orders

Lists your order history. Optional query: ?status=pending|processing|success|failed.

Account & Wallet

GET/api/user/profile

Returns your account profile including current wallet balance.

{
  "user": {
    "id": "3f873642-...",
    "name": "johndoe",
    "email": "john@example.com",
    "balance": 25.4,
    "role": "user"
  }
}
GET/api/user/transactions

Wallet mutation history. Each entry: type (credit/debit), amount, description, created_at.

POST/api/user/topup/create-qris

Creates an instant QRIS deposit (Indonesian e-wallets & banks). Body: { "amount": 10 } (USD, min 1). Then poll GET /api/user/topup/check-qris/:txId every 3s until status: "completed".

POST/api/user/crypto-deposit

Creates a crypto deposit request with automatic blockchain detection. Body: { "amount": 10, "chain": "usdt_bep20" | "usdt_polygon" | "ltc" | "ton" }. The response contains the deposit address plus the exact amount (unique cents) or memo to send. Poll GET /api/user/crypto-deposit/:id/check every 5s — the balance is credited automatically once the on-chain payment is detected.

ChainNetworkIdentification
usdt_bep20Binance Smart ChainUnique amount (e.g. 10.37 USDT)
usdt_polygonPolygonUnique amount (e.g. 10.52 USDT)
ltcLitecoinUnique LTC amount (8 decimals)
tonThe Open Network6-digit memo required

Quickstart

End-to-end example: list products, order one, poll until delivered.

Node.js
const BASE = "https://aiatera.online";
const headers = { "Content-Type": "application/json", "X-API-Key": "your-api-key" };

// 1. Pick a product
const { products } = await fetch(BASE + "/api/supplier/products", { headers }).then(r => r.json());
const product = products.find(p => p.inStock);

// 2. Order it (server verifies price & balance)
const { order } = await fetch(BASE + "/api/supplier/orders", {
  method: "POST", headers,
  body: JSON.stringify({ productId: product.id })
}).then(r => r.json());

// 3. Poll for delivery
let result;
do {
  await new Promise(r => setTimeout(r, 3000));
  result = await fetch(BASE + `/api/supplier/orders/${order.id}/status`, { headers }).then(r => r.json());
} while (result.status === "pending" || result.status === "processing");

console.log("Delivered:", result.result);
Python
import requests, time

BASE = "https://aiatera.online"
headers = {"X-API-Key": "your-api-key", "Content-Type": "application/json"}

# 1. Pick a product
products = requests.get(f"{BASE}/api/supplier/products", headers=headers).json()["products"]
product = next(p for p in products if p["inStock"])

# 2. Order it
order = requests.post(f"{BASE}/api/supplier/orders", headers=headers,
                      json={"productId": product["id"]}).json()["order"]

# 3. Poll for delivery
while True:
    r = requests.get(f"{BASE}/api/supplier/orders/{order['id']}/status", headers=headers).json()
    if r["status"] not in ("pending", "processing"):
        break
    time.sleep(3)

print("Delivered:", r.get("result"))
💡
Need help? Reach support via the Help Center with your order ID and request timestamp.