API v1.0 REST Architecture

API Documentation v1.0

Official developer documentation for programmatic integration with ApKey using Website Keys and User API Keys.

Base Endpoint URL https://apkey.net.royalcrown.id/api/v1

All requests must use the POST method with JSON payload or application/x-www-form-urlencoded.

1. Website Key

Parameter website_key atau header X-Website-Key. Wajib disertakan di semua request endpoint.

2. User API Key

Parameter key. Didapat saat register/login akun user. Wajib untuk transaksi, saldo, riwayat order, dan SMM authenticated endpoints.

Authentication & Response Standard

Setiap endpoint menghasilkan format response JSON standar dengan status success (boolean) dan object data atau string error.

Standard Response Structure application/json
Success Response (HTTP 200)
{
  "success": true,
  "data": {
    "balance": "10000.00",
    "currency": "USD"
  }
}
Error Response (HTTP 4xx/5xx)
{
  "success": false,
  "error": "Invalid API key or IP address not whitelisted."
}
1

1. Auth Endpoints

Registrasi user baru, autentikasi login, dan request reset password. Hanya memerlukan website_key.

POST

User Registration

/auth/register
4 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
name string Required Nama lengkap user
email string Required Alamat email aktif user
password string Required Password akun (min 8 karakter)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "name": "John Doe",
    "email": "john@example.com",
    "api_key": "apk_live_9f83b27e8a91...",
    "balance": "0.00"
  }
}
POST

User Login

/auth/login
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
email string Required Alamat email user terdaftar
password string Required Password akun user

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "name": "John Doe",
    "email": "john@example.com",
    "api_key": "apk_live_9f83b27e8a91...",
    "balance": "150.00"
  }
}
POST

Reset Password

/auth/reset-password
2 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
email string Required Alamat email user untuk link reset

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "message": "Link reset password telah dikirim ke email terdaftar."
  }
}
2

2. Account Data

Informasi profil dan saldo realtime user. Memerlukan website_key dan user API key.

POST

Get User Balance

/data/balance
2 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "balance": "10000.00",
    "currency": "USD"
  }
}
POST

Get User Email

/data/email
2 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "email": "john@example.com"
  }
}
POST

Get Current API Key

/data/api_key
2 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "api_key": "apk_live_9f83b27e8a91..."
  }
}
POST

Regenerate API Key

/data/register
2 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User API key saat ini

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "api_key": "apk_live_new_7c62a14e9b82...",
    "message": "User API key successfully regenerated."
  }
}
3

3. Get History

Melihat riwayat transaksi pesanan SMM, setoran deposit, dan permintaan refill.

POST

Order History

/get-history/order
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
limit integer Optional Jumlah baris data (default: 50, max: 100)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "orders": [
      {
        "id": 23501,
        "invoice": "TRX-82910381",
        "service_name": "Instagram Followers [Instant]",
        "target": "https://instagram.com/username",
        "quantity": 1000,
        "charge": "1.5000",
        "start_count": 520,
        "remains": 0,
        "status": "Completed",
        "created_at": "2026-08-28 10:00:00"
      }
    ]
  }
}
POST

Deposit History

/get-history/deposit
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
limit integer Optional Jumlah baris data (default: 50, max: 100)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "deposits": [
      {
        "invoice": "DEP-71829301",
        "amount": "25.00",
        "currency": "USD",
        "payer_currency": "USDT",
        "network": "TRON",
        "status": "Success",
        "created_at": "2026-08-27 15:30:00"
      }
    ]
  }
}
POST

Refill History

/get-history/refill
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
limit integer Optional Jumlah baris data (default: 50, max: 100)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "refills": [
      {
        "id": 1204,
        "order_id": 23501,
        "invoice": "TRX-82910381",
        "status": "Completed",
        "created_at": "2026-08-28 08:15:00"
      }
    ]
  }
}
4

4. Account Profile

Manajemen password, nama user, dan penghapusan akun.

POST

Update Name

/account/update-name
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
name string Required Nama lengkap baru

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "name": "John Doe",
    "message": "Nama berhasil diperbarui."
  }
}
POST

Update Password

/account/update-password
5 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
current_password string Required Password saat ini
password string Required Password baru (min 8 karakter)
password_confirmation string Required Konfirmasi password baru

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "message": "Password berhasil diperbarui."
  }
}
POST

Delete Account

/account/delete
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
password string Required Konfirmasi password akun

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "message": "Akun berhasil dihapus secara permanen."
  }
}
5

5. Transaction SMM

Deposit instan via Cryptomus, placement order baru, request refill, dan tracking status pesanan.

POST

Payment Methods

/transaction_smm/payment-methods
2 parameters
Note: Menampilkan daftar cryptocurrency dan network blockchain yang aktif di gateway Cryptomus.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "methods": [
      {
        "currency": "USDT",
        "network": "TRON",
        "is_available": true,
        "min_amount": "1.00000000",
        "max_amount": "100000.00000000",
        "label": "USDT — TRON"
      },
      {
        "currency": "BTC",
        "network": "BTC",
        "is_available": true,
        "min_amount": "0.00010000",
        "max_amount": "10.00000000",
        "label": "Bitcoin — BTC"
      }
    ]
  }
}
POST

Create Deposit (Cryptomus)

/transaction_smm/deposit
5 parameters
Note: Membuat alamat wallet crypto static/dinamis. Response berupa payment address & QR Code base64 tanpa perlu redirect eksternal.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
amount number Required Nominal deposit USD (minimum 5 USD)
to_currency string Required Kode crypto pilihan (contoh: USDT, BTC, TRX)
network string Required Blockchain network pilihan (contoh: TRON, BTC, BSC)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "invoice": "DEP-92817401",
    "amount": "10.00",
    "currency": "USD",
    "status_payment": "Pending",
    "uuid": "8b9e1c2d-...",
    "address": "TYP7qGZqV7QxG89...",
    "network": "TRON",
    "payer_currency": "USDT",
    "payer_amount": "10.00",
    "qr_image": "data:image/png;base64,iVBORw0KGgo...",
    "expired_at": 1756380000
  }
}
POST

Place SMM Order

/transaction_smm/order
6 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
service string|integer Required ID Database atau SID Layanan SMM
link string Required Target link / username media sosial
quantity integer Optional Jumlah pesanan (wajib untuk non-Package)
comments string Optional Komentar kustom per baris (opsional)

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "order": "23501",
    "invoice": "TRX-82910381",
    "charge": "1.5000",
    "balance": "85.0000"
  }
}
POST

Request Order Refill

/transaction_smm/refill
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
order string Required Order ID atau Invoice pesanan

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "refill": "1204",
    "invoice": "TRX-82910381",
    "status": "Pending"
  }
}
POST

Check Order Status

/transaction_smm/status
3 parameters

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key
order string Required Order ID atau Invoice pesanan

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "order": "23501",
    "invoice": "TRX-82910381",
    "status": "Completed",
    "start_count": "520",
    "remains": "0",
    "charge": "1.5000"
  }
}
6

6. SMM Catalog

Katalog platform media sosial dan daftar harga layanan. Tersedia dalam versi publik (hanya website_key) dan versi login (website_key + user API key).

POST

Platforms (Public)

/smm/platforms
1 parameter
Note: Hanya memerlukan website_key. Menyertakan field icon_url untuk logo platform.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "platforms": [
      {
        "id": 1,
        "name": "Instagram",
        "slug": "instagram",
        "icon_url": "https://example.com/assets/icons/instagram.png"
      },
      {
        "id": 2,
        "name": "TikTok",
        "slug": "tiktok",
        "icon_url": "https://example.com/assets/icons/tiktok.png"
      }
    ]
  }
}
POST

Platforms (Authenticated)

/smm/auth/platforms
2 parameters
Note: Wajib menyertakan website_key + user API key.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "platforms": [
      {
        "id": 1,
        "name": "Instagram",
        "slug": "instagram",
        "icon_url": "https://example.com/assets/icons/instagram.png"
      }
    ]
  }
}
POST

Pricelist & Services (Public)

/smm/pricelist
1 parameter
Note: Daftar semua layanan SMM aktif beserta harga dasar dan spesifikasi rate/min/max.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "services": [
      {
        "service": 1,
        "sid": "1001",
        "name": "Instagram Followers [High Quality - Auto Refill 30D]",
        "type": "Default",
        "rate": "1.5000",
        "min": 50,
        "max": 50000,
        "dripfeed": false,
        "refill": true,
        "cancel": false,
        "category": "Instagram Followers",
        "platform": "Instagram",
        "icon_url": "https://example.com/assets/icons/instagram.svg"
      }
    ]
  }
}
POST

Pricelist & Services (Authenticated)

/smm/auth/pricelist
2 parameters
Note: Menampilkan daftar layanan dengan penyesuaian diskon/rate khusus level user login.

Request Parameters

Field Type Status Description
website_key string Required Website secret API key
key string Required User personal API key

JSON Response

200 OK
application/json
{
  "success": true,
  "data": {
    "services": [
      {
        "service": 1,
        "sid": "1001",
        "name": "Instagram Followers [High Quality - Auto Refill 30D]",
        "type": "Default",
        "rate": "1.3500",
        "min": 50,
        "max": 50000,
        "dripfeed": false,
        "refill": true,
        "cancel": false,
        "category": "Instagram Followers",
        "platform": "Instagram",
        "icon_url": "https://example.com/assets/icons/instagram.svg"
      }
    ]
  }
}

Quick cURL Request Example

Contoh perintah cURL cepat untuk memeriksa saldo user dari terminal atau backend server:

Terminal cURL
curl -X POST https://apkey.net.royalcrown.id/api/v1/data/balance \
  -H "Content-Type: application/json" \
  -d '{
    "website_key": "YOUR_WEBSITE_SECRET_KEY",
    "key": "YOUR_USER_API_KEY"
  }'

© 2026 Apkey. All rights reserved. REST API Documentation.