THÔNG BÁO: SHOPMMOSTUDIO - Hệ thống bán tài khoản Capcut,Youtube,ChatGPT....
Trang chủ Đơn hàng Thông tin
Cloud VPS Quốc Tế API

Tài liệu API Cloud VPS Quốc Tế

Tích hợp hệ thống đặt mua máy chủ Cloud VPS Quốc Tế, quản lý IP, mật khẩu và gửi lệnh điều khiển (Reboot, Tắt nguồn, Bật máy) tự động 100% vào ứng dụng của bạn.

RESTful API v1.0 • Akamai Cloud Infrastructure
Base URL https://shopmmostudio.com/api/v1/vps
Data Format JSON (application/json)
Tài liệu kỹ thuật vpstrial.md
Chu kỳ thanh toán 30 ngày (1 tháng)
Chưa có API Key? Vui lòng truy cập Quản lý API Keys để tạo API Key và API Secret hoàn toàn miễn phí.

Tất cả request gọi API đều yêu cầu cung cấp các Header sau:

Header Ví dụ giá trị Mô tả
X-API-Key sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6 API Key của bạn (bắt đầu bằng sk_live_)
X-API-Secret sk_secret_a1b2c3d4e5f6g7h... API Secret bí mật (bắt đầu bằng sk_secret_)
Content-Type application/json Bắt buộc khi gửi POST request
Ví dụ Headers
HTTP Headers
X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6
X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2
Content-Type: application/json
GET https://shopmmostudio.com/api/v1/vps/plans

Endpoint này công khai hoặc có thể gửi kèm API Key để nhận kèm thông tin số dư ví.

Code mẫu
PHP (cURL)
<?php
$ch = curl_init('https://shopmmostudio.com/api/v1/vps/plans');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6',
        'X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2'
    ]
]);
$response = curl_exec($ch);
curl_close($ch);

$result = json_decode($response, true);
print_r($result);
Python (requests)
import requests

url = "https://shopmmostudio.com/api/v1/vps/plans"
headers = {
    "X-API-Key": "sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6",
    "X-API-Secret": "sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2"
}
res = requests.get(url, headers=headers)
print(res.json())
cURL CLI
curl -X GET "https://shopmmostudio.com/api/v1/vps/plans" \
  -H "X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6" \
  -H "X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2"
Ví dụ Response thành công (HTTP 200)
JSON
{
  "success": true,
  "timestamp": 1792813050,
  "data": {
    "plans": [
      {
        "id": 4,
        "plan_id": "g6-standard-1",
        "name": "Cloud VPS Standard 2GB",
        "cpu_cores": 1,
        "ram_mb": 2048,
        "ram_formatted": "2GB",
        "disk_gb": 50,
        "transfer_gb": 2000,
        "price_monthly": 15000,
        "price_formatted": "15.000đ",
        "billing_cycle": "30_days"
      },
      {
        "id": 5,
        "plan_id": "g6-standard-2",
        "name": "Cloud VPS Standard 4GB",
        "cpu_cores": 2,
        "ram_mb": 4096,
        "ram_formatted": "4GB",
        "disk_gb": 80,
        "transfer_gb": 4000,
        "price_monthly": 40000,
        "price_formatted": "40.000đ",
        "billing_cycle": "30_days"
      }
    ],
    "operating_systems": {
      "windows": [
        { "id": "windows-2022", "name": "Windows Server 2022 Datacenter", "default_port": 3389, "connection_type": "RDP" },
        { "id": "windows-2019", "name": "Windows Server 2019 Datacenter", "default_port": 3389, "connection_type": "RDP" }
      ],
      "linux": [
        { "id": "ubuntu24.04", "name": "Ubuntu 24.04 LTS", "default_port": 22, "connection_type": "SSH" },
        { "id": "debian12", "name": "Debian 12 Bookworm", "default_port": 22, "connection_type": "SSH" }
      ]
    },
    "regions": [
      { "id": "ap-south", "name": "Singapore (ap-south)", "country": "Singapore", "is_recommended": true },
      { "id": "jp-tyo", "name": "Tokyo, Japan (jp-tyo)", "country": "Japan" },
      { "id": "us-lax", "name": "Los Angeles, US (us-lax)", "country": "United States" }
    ]
  }
}
POST https://shopmmostudio.com/api/v1/vps/order
Lưu ý quan trọng về thời gian nạp OS: Sau khi khởi tạo thành công, hạ tầng Cloud Linode cần khoảng 2 - 4 phút để nạp image đĩa và boot hệ điều hành (trạng thái provisioning). Khi máy chuyển sang running, bạn có thể kết nối ngay qua RDP (cổng 3389) hoặc SSH (cổng 22).
Request Body (JSON)
Tham số Kiểu Bắt buộc Mô tả & Giá trị mẫu
plan_id int | string Bắt buộc ID của gói cấu hình (VD: 4 hoặc mã chuỗi "g6-standard-1")
image string Tùy chọn Mã hệ điều hành. Mặc định: "windows-2022". Hỗ trợ: windows-2022, windows-2019, ubuntu24.04, ubuntu22.04, debian12, almalinux9, rocky9, kali...
region string Tùy chọn Vùng Datacenter. Mặc định: "ap-south" (Singapore). Hỗ trợ: jp-tyo, us-lax, us-east, eu-central...
password string Tùy chọn Mật khẩu root/Administrator (ít nhất 8 ký tự). Nếu để trống, hệ thống sẽ tự sinh mật khẩu mạnh bảo mật ngẫu nhiên.
label string Tùy chọn Tên gợi nhớ của máy chủ (VD: "my-node-1")
Code mẫu
PHP (cURL)
<?php
$apiKey = 'sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6';
$apiSecret = 'sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2';

$data = [
    'plan_id'  => 4,                    // ID gói VPS
    'image'    => 'windows-2022',       // Windows Server 2022 Datacenter
    'region'   => 'ap-south',           // Datacenter Singapore
    'password' => 'VpsAdmin@2026!#x',   // (Tùy chọn) Mật khẩu
    'label'    => 'vps-marketing-01'    // (Tùy chọn) Tên máy chủ
];

$ch = curl_init('https://shopmmostudio.com/api/v1/vps/order');
curl_setopt_array($ch, [
    CURLOPT_POST => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_POSTFIELDS => json_encode($data),
    CURLOPT_HTTPHEADER => [
        'X-API-Key: ' . $apiKey,
        'X-API-Secret: ' . $apiSecret,
        'Content-Type: application/json'
    ]
]);
$res = curl_exec($ch);
curl_close($ch);

print_r(json_decode($res, true));
Python
import requests

url = "https://shopmmostudio.com/api/v1/vps/order"
headers = {
    "X-API-Key": "sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6",
    "X-API-Secret": "sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2",
    "Content-Type": "application/json"
}
payload = {
    "plan_id": 4,
    "image": "windows-2022",
    "region": "ap-south",
    "password": "VpsAdmin@2026!#x",
    "label": "vps-marketing-01"
}

res = requests.post(url, json=payload, headers=headers)
print(res.json())
cURL CLI
curl -X POST "https://shopmmostudio.com/api/v1/vps/order" \
  -H "X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6" \
  -H "X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2" \
  -H "Content-Type: application/json" \
  -d '{
    "plan_id": 4,
    "image": "windows-2022",
    "region": "ap-south",
    "password": "VpsAdmin@2026!#x",
    "label": "vps-marketing-01"
  }'
Ví dụ Response thành công (HTTP 201 Created)
JSON
{
  "success": true,
  "message": "Khởi tạo Cloud VPS thành công!",
  "data": {
    "order_id": 18,
    "trans_id": "VPS_9D28B1CA4E",
    "linode_id": 61284920,
    "plan": {
      "id": 4,
      "name": "Cloud VPS Standard 2GB",
      "plan_id": "g6-standard-1",
      "cpu": 1,
      "ram_mb": 2048,
      "disk_gb": 50
    },
    "operating_system": {
      "id": "windows-2022",
      "name": "Windows Server 2022 Datacenter",
      "is_windows": true
    },
    "connection": {
      "ip": "172.104.45.182",
      "ipv6": "2400:8902::f03c:93ff:fe2b:110a",
      "username": "Administrator",
      "password": "VpsAdmin@2026!#x",
      "port": 3389,
      "protocol": "RDP"
    },
    "region": "ap-south",
    "amount": 15000,
    "balance_before": 100000,
    "balance_after": 85000,
    "status": "provisioning",
    "notice": "Máy chủ đang nạp Hệ điều hành trên Cloud (khoảng 2-4 phút). Kết nối RDP/SSH sẽ sẵn sàng ngay khi máy chuyển sang trạng thái running.",
    "created_at": "2026-10-24 10:45:00",
    "expires_at": "2026-11-23 10:45:00"
  }
}
GET https://shopmmostudio.com/api/v1/vps/orders
Query Parameters
Tham số Kiểu Mặc định Mô tả
page int 1 Trang cần xem
limit int 10 Số lượng bản ghi mỗi trang (tối đa 100)
status string all Lọc theo trạng thái: running, provisioning, offline, hoặc all
search string null Tìm theo IP, mã đơn (trans_id), hoặc nhãn máy chủ (label)
Code mẫu
PHP
<?php
$ch = curl_init('https://shopmmostudio.com/api/v1/vps/orders?page=1&limit=10&status=running');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6',
        'X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2'
    ]
]);
$res = curl_exec($ch);
curl_close($ch);
print_r(json_decode($res, true));
cURL CLI
curl -X GET "https://shopmmostudio.com/api/v1/vps/orders?page=1&limit=10" \
  -H "X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6" \
  -H "X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2"
GET https://shopmmostudio.com/api/v1/vps/detail

Tính năng Realtime Sync: Khi máy chủ đang ở trạng thái provisioning hoặc booting, hệ thống tự động đồng bộ realtime từ Cloud Linode. Ngay khi máy cài xong OS, kết quả sẽ cập nhật thành running!

Query Parameters
Tham số Kiểu Bắt buộc Mô tả
trans_id string 1 trong 2 Mã đơn hàng Cloud VPS (VD: "VPS_9D28B1CA4E")
order_id int 1 trong 2 ID đơn hàng máy chủ trong hệ thống (VD: 18)
Code mẫu
PHP
<?php
$transId = 'VPS_9D28B1CA4E';

$ch = curl_init('https://shopmmostudio.com/api/v1/vps/detail?trans_id=' . $transId);
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6',
        'X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2'
    ]
]);
$res = curl_exec($ch);
curl_close($ch);
print_r(json_decode($res, true));
cURL CLI
curl -X GET "https://shopmmostudio.com/api/v1/vps/detail?trans_id=VPS_9D28B1CA4E" \
  -H "X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6" \
  -H "X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2"
POST https://shopmmostudio.com/api/v1/vps/action
Quy định Cooldown 60 phút: Để đảm bảo tính ổn định của hạ tầng Cloud, mỗi máy chủ được giới hạn thao tác điều khiển 60 phút 1 lần. Nếu gọi API trong thời gian chờ, API sẽ trả về HTTP 429 kèm số phút còn lại.
Request Body (JSON)
Tham số Kiểu Bắt buộc Mô tả
order_id int 1 trong 2 ID đơn hàng máy chủ
trans_id string 1 trong 2 Mã giao dịch (VD: "VPS_9D28B1CA4E")
action string Bắt buộc Hành động thực hiện:
• reboot: Khởi động lại máy chủ
• shutdown: Tắt nguồn máy chủ
• boot: Bật nguồn máy chủ
Code mẫu
PHP
<?php
$data = [
    'trans_id' => 'VPS_9D28B1CA4E',
    'action'   => 'reboot' // 'reboot', 'shutdown', hoặc 'boot'
];

$ch = curl_init('https://shopmmostudio.com/api/v1/vps/action');
curl_setopt_array($ch, [
    CURLOPT_POST => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_POSTFIELDS => json_encode($data),
    CURLOPT_HTTPHEADER => [
        'X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6',
        'X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2',
        'Content-Type: application/json'
    ]
]);
$res = curl_exec($ch);
curl_close($ch);
print_r(json_decode($res, true));
cURL CLI
curl -X POST "https://shopmmostudio.com/api/v1/vps/action" \
  -H "X-API-Key: sk_live_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6" \
  -H "X-API-Secret: sk_secret_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0u1v2w3x4y5z6a7b8c9d0e1f2" \
  -H "Content-Type: application/json" \
  -d '{
    "trans_id": "VPS_9D28B1CA4E",
    "action": "reboot"
  }'
Windows Server & Desktop (RDP Cổng 3389)
Mã imageTên phiên bảnTài khoản RDP
windows-2022Windows Server 2022 Datacenter 64-bitAdministrator
windows-2019Windows Server 2019 Datacenter 64-bitAdministrator
windows-2016Windows Server 2016 Datacenter 64-bitAdministrator
windows-11Windows 11 Pro 64-bitAdministrator
windows-10Windows 10 Pro 64-bitAdministrator
Linux Distributions (SSH Cổng 22)
Mã imageTên phiên bảnTài khoản SSH
ubuntu24.04Ubuntu 24.04 LTS (Noble Numbat)root
ubuntu22.04Ubuntu 22.04 LTS (Jammy Jellyfish)root
debian12Debian 12 Bookwormroot
almalinux9AlmaLinux 9root
rocky9Rocky Linux 9root
centos-stream9CentOS Stream 9root
kaliKali Linux Rolling Releaseroot
Datacenter Regions
Mã regionĐịa điểm DatacenterĐộ trễ về VN
ap-southSingapore (Khuyên dùng)~30 - 45ms (Cực thấp)
jp-tyoTokyo, Japan~65 - 80ms
us-laxLos Angeles, California, US~160 - 180ms
us-eastNewark / New York, US~200 - 230ms
eu-centralFrankfurt, Germany~170 - 190ms
Error Code HTTP Code Ý nghĩa & Cách xử lý
INVALID_API_KEY 401 API Key không hợp lệ hoặc không tồn tại. Vui lòng kiểm tra lại header X-API-Key.
INVALID_API_SECRET 401 API Secret không chính xác với API Key đã cung cấp.
INSUFFICIENT_BALANCE 400 Số dư ví tài khoản không đủ để thanh toán gói VPS. Vui lòng nạp thêm tiền.
PLAN_NOT_FOUND 400 Gói cấu hình không hợp lệ hoặc đã ngừng kinh doanh.
SERVER_PROVISIONING 400 Máy chủ đang nạp Hệ điều hành trên Cloud. Không thể điều khiển lúc này, vui lòng chờ 2 - 4 phút.
ACTION_COOLDOWN 429 Mỗi thao tác điều khiển chỉ được thực hiện 60 phút 1 lần. API trả về số phút còn lại.
NOT_FOUND 404 Không tìm thấy máy chủ với ID / trans_id đã chỉ định hoặc bạn không có quyền.
PROVISION_FAILED 500 Khởi tạo máy chủ thất bại do cụm cloud bận. Hệ thống đã tự động hoàn lại 100% tiền vào số dư ví.