curl --request GET \
--url https://api.ssi.com.vn/api/v3/trading/orderBook \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.ssi.com.vn/api/v3/trading/orderBook"
headers = {
"Content-Type": "<content-type>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: 'Bearer <token>'}
};
fetch('https://api.ssi.com.vn/api/v3/trading/orderBook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ssi.com.vn/api/v3/trading/orderBook",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.ssi.com.vn/api/v3/trading/orderBook"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.ssi.com.vn/api/v3/trading/orderBook")
.header("Content-Type", "<content-type>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ssi.com.vn/api/v3/trading/orderBook")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"accountNo": "Q123451",
"totalRecord": 5,
"orderList": [
{
"clientRequestId": "T260820 xkp48463635",
"orderId": "26082100131482",
"symbol": "AAA",
"side": "S",
"orderType": "LO",
"quantity": "1",
"price": "7090",
"filledQty": "1",
"cancelQty": "0",
"avgPrice": "7090",
"inputTime": "2026/08/21 14:09:02",
"modifiedTime": "2026/08/21 14:15:28",
"orderStatus": "FF",
"message": null
}
]
}{
"code": "<string>",
"msg": "<string>"
}{
"code": "<string>",
"msg": "<string>"
}{
"code": "<string>",
"msg": "<string>"
}Sổ lệnh
Lấy lịch sử sổ lệnh theo tài khoản và bộ lọc.
curl --request GET \
--url https://api.ssi.com.vn/api/v3/trading/orderBook \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.ssi.com.vn/api/v3/trading/orderBook"
headers = {
"Content-Type": "<content-type>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: 'Bearer <token>'}
};
fetch('https://api.ssi.com.vn/api/v3/trading/orderBook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ssi.com.vn/api/v3/trading/orderBook",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.ssi.com.vn/api/v3/trading/orderBook"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.ssi.com.vn/api/v3/trading/orderBook")
.header("Content-Type", "<content-type>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ssi.com.vn/api/v3/trading/orderBook")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"accountNo": "Q123451",
"totalRecord": 5,
"orderList": [
{
"clientRequestId": "T260820 xkp48463635",
"orderId": "26082100131482",
"symbol": "AAA",
"side": "S",
"orderType": "LO",
"quantity": "1",
"price": "7090",
"filledQty": "1",
"cancelQty": "0",
"avgPrice": "7090",
"inputTime": "2026/08/21 14:09:02",
"modifiedTime": "2026/08/21 14:15:28",
"orderStatus": "FF",
"message": null
}
]
}{
"code": "<string>",
"msg": "<string>"
}{
"code": "<string>",
"msg": "<string>"
}{
"code": "<string>",
"msg": "<string>"
}Ủy quyền
Access token lấy từ endpoint /api/v3/auth/token hoặc /api/v3/auth/refresh.
Tiêu đề
Định dạng nội dung request body. Chủ yếu là application/json.
Thông tin client gửi request.
Ngôn ngữ phản hồi mong muốn. Nếu không có header này, hệ thống sẽ mặc định là en
Tham số truy vấn
Tài khoản giao dịch cần lấy lịch sử sổ lệnh.
Thời gian bắt đầu để lọc lịch sử sổ lệnh, định dạng ISO 8601 (ví dụ 2024-01-01T00:00:00Z).
Thời gian kết thúc để lọc lịch sử sổ lệnh, định dạng ISO 8601 (ví dụ 2024-01-01T00:00:00Z).
Mã chứng khoán cần lọc lịch sử sổ lệnh.
Trạng thái lệnh cần lọc. Tham khảo danh sách trạng thái tại phụ lục Trạng thái lệnh & luồng trạng thái.
Số lượng bản ghi trên mỗi trang. Nếu không cung cấp thì hệ thống sẽ sử dụng giá trị mặc định là 10.
Chỉ số trang khi phân trang kết quả, bắt đầu từ 1. Nếu không cung cấp thì hệ thống sẽ sử dụng giá trị mặc định là 1.