Cung cầu trong phiên (15 phút)
curl --request GET \
--url https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext \
--header 'Authorization: Bearer <token>'import requests
url = "https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext', 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.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext",
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>"
],
]);
$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.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext"
req, _ := http.NewRequest("GET", url, nil)
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://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"ticker": "TCB",
"data": [
{
"bu": 1000000,
"bms": 5000000,
"bup": 0.65,
"sd": 800000,
"sms": 3000000,
"sdp": 0.35,
"bsr": 1.25,
"t": "09:15:00",
"s": 1640995200000
}
]
}Dữ liệu thị trường
Cung cầu trong phiên (15 phút)
Lấy dữ liệu cung cầu trong phiên theo khoảng thời gian 15 phút.
GET
/
nyx
/
v1
/
intraday
/
{ticker}
/
bsa-ext
Cung cầu trong phiên (15 phút)
curl --request GET \
--url https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext \
--header 'Authorization: Bearer <token>'import requests
url = "https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext', 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.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext",
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>"
],
]);
$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.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext"
req, _ := http.NewRequest("GET", url, nil)
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://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.tcbs.com.vn/nyx/v1/intraday/{ticker}/bsa-ext")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"ticker": "TCB",
"data": [
{
"bu": 1000000,
"bms": 5000000,
"bup": 0.65,
"sd": 800000,
"sms": 3000000,
"sdp": 0.35,
"bsr": 1.25,
"t": "09:15:00",
"s": 1640995200000
}
]
}Ủy quyền
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Tham số đường dẫn
Mã cổ phiếu, ví dụ TCB.
Tham số truy vấn
Khung thời gian tính bằng phút: 15 hoặc 60. Khung thời gian cung cầu trong phiên, tính bằng phút: 15 hoặc 60.
Tùy chọn có sẵn:
15, 60 Khung thời gian: 15 phút. Khung thời gian cung cầu trong phiên: 15 phút.
Tùy chọn có sẵn:
15 Loại nhà đầu tư: sheep (small retail), wolf (medium institutional), shark (large institutional), all (mặc định). Loại nhà đầu tư: sheep = cá nhân nhỏ lẻ, wolf = tổ chức vừa, shark = tổ chức lớn, all = tất cả.
Tùy chọn có sẵn:
sheep, wolf, shark, all