curl --request GET \
--url https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId} \
--header 'X-Api-Key: <x-api-key>' \
--header 'X-Aux-Date: <x-aux-date>' \
--header 'X-Signature: <x-signature>'import requests
url = "https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}"
headers = {
"X-Api-Key": "<x-api-key>",
"X-Aux-Date": "<x-aux-date>",
"X-Signature": "<x-signature>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Api-Key': '<x-api-key>',
'X-Aux-Date': '<x-aux-date>',
'X-Signature': '<x-signature>'
}
};
fetch('https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}', 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://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <x-api-key>",
"X-Aux-Date: <x-aux-date>",
"X-Signature: <x-signature>"
],
]);
$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://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<x-api-key>")
req.Header.Add("X-Aux-Date", "<x-aux-date>")
req.Header.Add("X-Signature", "<x-signature>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}")
.header("X-Api-Key", "<x-api-key>")
.header("X-Aux-Date", "<x-aux-date>")
.header("X-Signature", "<x-signature>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<x-api-key>'
request["X-Aux-Date"] = '<x-aux-date>'
request["X-Signature"] = '<x-signature>'
response = http.request(request)
puts response.read_body{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"loanPackageId": 5757,
"orderCategory": "NORMAL",
"orderStatus": "PartiallyFilled",
"fillQuantity": 200,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"taxRate": 0,
"exchangeFeeRate": 0.00027,
"feeRate": 0.00027,
"leaveQuantity": 300,
"canceledQuantity": 0,
"error": "",
"marketType": "STOCK",
"priceSecure": 24250,
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:59.052768Z",
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":4.0}",
"reports": [
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 100,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:51.613222Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 400,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":3}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 100,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:51.613222Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 400,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":3}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PendingNew",
"fillQuantity": 0,
"lastQuantity": 0,
"lastPrice": 0,
"averagePrice": 0,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:36.532743Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 500,
"canceledQuantity": 0,
"error": "<no value>",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":1}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "New",
"fillQuantity": 0,
"lastQuantity": 0,
"lastPrice": 0,
"averagePrice": 0,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:36.545128Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 500,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":2}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 200,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:59.052768Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 300,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":4}",
"loanPackageId": 5757
}
]
}Chi tiết trạng thái lệnh
curl --request GET \
--url https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId} \
--header 'X-Api-Key: <x-api-key>' \
--header 'X-Aux-Date: <x-aux-date>' \
--header 'X-Signature: <x-signature>'import requests
url = "https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}"
headers = {
"X-Api-Key": "<x-api-key>",
"X-Aux-Date": "<x-aux-date>",
"X-Signature": "<x-signature>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Api-Key': '<x-api-key>',
'X-Aux-Date': '<x-aux-date>',
'X-Signature': '<x-signature>'
}
};
fetch('https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}', 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://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <x-api-key>",
"X-Aux-Date: <x-aux-date>",
"X-Signature: <x-signature>"
],
]);
$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://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<x-api-key>")
req.Header.Add("X-Aux-Date", "<x-aux-date>")
req.Header.Add("X-Signature", "<x-signature>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}")
.header("X-Api-Key", "<x-api-key>")
.header("X-Aux-Date", "<x-aux-date>")
.header("X-Signature", "<x-signature>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.dnse.com.vn/accounts/{accountNo}/executions/{orderId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<x-api-key>'
request["X-Aux-Date"] = '<x-aux-date>'
request["X-Signature"] = '<x-signature>'
response = http.request(request)
puts response.read_body{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"loanPackageId": 5757,
"orderCategory": "NORMAL",
"orderStatus": "PartiallyFilled",
"fillQuantity": 200,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"taxRate": 0,
"exchangeFeeRate": 0.00027,
"feeRate": 0.00027,
"leaveQuantity": 300,
"canceledQuantity": 0,
"error": "",
"marketType": "STOCK",
"priceSecure": 24250,
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:59.052768Z",
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":4.0}",
"reports": [
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 100,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:51.613222Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 400,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":3}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 100,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:51.613222Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 400,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":3}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PendingNew",
"fillQuantity": 0,
"lastQuantity": 0,
"lastPrice": 0,
"averagePrice": 0,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:36.532743Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 500,
"canceledQuantity": 0,
"error": "<no value>",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":1}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "New",
"fillQuantity": 0,
"lastQuantity": 0,
"lastPrice": 0,
"averagePrice": 0,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:36.545128Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 500,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":2}",
"loanPackageId": 5757
},
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 200,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:59.052768Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 300,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":4}",
"loanPackageId": 5757
}
]
}Tiêu đề
API key được cấp khi đăng ký dịch vụ DNSE OpenAPI.
Ví dụ: b3JnOmRuc2UgaWQ6MjdlZTc1MzcxZGFkNTY0NmYzYTM2NDk1ZGE3OGNiOGQgaDptdXJtdXIxMjg=
Thời gian thực hiện request, dùng trong cơ chế ký request của DNSE.
Ví dụ: Sat, 01 May 2026 14:24:23 +0000
Chữ ký xác thực request được tạo từ API key secret và X-Aux-Date.
Ví dụ: Signature keyId="b3JnOmRuc2UgaWQ6MjdlZTc1MzcxZGFkNTY0NmYzYTM2NDk1ZGE3OGNiOGQgaDptdXJtdXIxMjg=",algorithm="hmac-sha256",headers="(request-target) x-aux-date",signature="rfbVXHDUi%2B%2FsOkLXle7O17Qm%2F05cbISSR%2BDcFrBHfqQ%3D",nonce="4add8c3264e4492b9f8ecde0cf26b523"
Tham số truy vấn
Loại thị trường
-
STOCK: Lệnh cơ sở
-
DERIVATIVE: Lệnh phái sinh
-
BOND: Lệnh trái phiếu Loại thị trường.
-
STOCK: Giao dịch cơ sở -
DERIVATIVE: Giao dịch phái sinh -
BOND: Giao dịch trái phiếu
STOCK, DERIVATIVE "STOCK"
Phân loại lệnh thường (mặc định NORMAL) Phân loại lệnh.
NORMAL: Lệnh thườngSTOP: Lệnh dừng có điều kiệnOCO: Lệnh OCO phái sinhCONDITIONAL: Lệnh điều kiện
NORMAL, CONDITIONAL "NORMAL"
Phản hồi
OK
ID lệnh
1651
Chiều giao dịch
- NB: Mua
- NS: Bán
NB, NS "NB"
Số tiểu khoản
"0001179019"
Mã chứng khoán
"HPG"
Giá đặt lệnh
24250
Khối lượng đặt lệnh
500
Loại lệnh
- LO: Lệnh giới hạn
- MOK/MAK/MTL: Lệnh thị trường
- ATO/ATC: Lệnh phiên định kỳ mở cửa/đóng cửa
- PLO: Lệnh khớp lệnh sau giờ
LO, MOK, MAK, MTL, ATO, ATC, PLO "LO"
Mã gói vay
5757
Phân loại lệnh (mặc định NORMAL)
NORMAL, STOP, OCO, CONDITIONAL "NORMAL"
Trạng thái lệnh
- Pending/PendingNew: Chờ gửi
- New: Chờ khớp
- PartiallyFilled: Khớp một phần
- Filled: Khớp toàn bộ
- Rejected: Bị từ chối
- Expired: Hết hạn trong phiên
- DoneForDay: Lệnh được giải tỏa do không khớp trong phiên
Pending, PendingNew, New, PendingReplace, PendingCancel, PartiallyFilled, Filled, Canceled, Rejected, Expired, DoneForDay "PartiallyFilled"
Khối lượng đã khớp
200
Khối lượng khớp gần nhất
100
Giá khớp gần nhất
24250
Giá khớp trung bình
24250
Ngày giao dịch
"2026-07-13"
Tỷ lệ thuế
0
Tỷ lệ phí trả Sở giao dịch
0.00027
Tổng tỷ lệ phí của lệnh
0.00027
Khối lượng còn lại chưa khớp
300
Khối lượng đã hủy
0
Mã lỗi nếu lệnh bị từ chối
""
Loại thị trường
- STOCK: Lệnh cơ sở
- DERIVATIVE: Lệnh phái sinh
STOCK, DERIVATIVE, BOND "STOCK"
Giá dùng để kiểm tra sức mua/đặt lệnh
24250
Thời điểm tạo lệnh
"2026-07-13T06:50:36.532741Z"
Thời điểm cập nhật lệnh
"2026-07-13T06:50:59.052768Z"
Thông tin bổ sung của lệnh
"{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":4.0}"
Danh sách trạng thái lệnh theo từng lần cập nhật
Show child attributes
Show child attributes
[
{
"id": 1651,
"side": "NB",
"accountNo": "0001179019",
"symbol": "HPG",
"price": 24250,
"quantity": 500,
"orderType": "LO",
"orderStatus": "PartiallyFilled",
"fillQuantity": 100,
"lastQuantity": 100,
"lastPrice": 24250,
"averagePrice": 24250,
"transDate": "2026-07-13",
"createdDate": "2026-07-13T06:50:36.532741Z",
"modifiedDate": "2026-07-13T06:50:51.613222Z",
"taxRate": 0,
"exchangeFeeRate": 0,
"feeRate": 0.00027,
"leaveQuantity": 400,
"canceledQuantity": 0,
"error": "",
"priceSecure": 24250,
"metadata": "{\"orderSession\":\"OPEN\",\"ip\":\"202.60.110.58\",\"maker\":\"1000005917\",\"isForeigner\":false,\"reqId\":\"24534\",\"probType\":\"CUSTOMER_8000\",\"eventNo\":3}",
"loanPackageId": 5757
}
]