Python

Models

Các model dữ liệu và hằng số trong Python SDK 3.3.2

Trang này liệt kê các model dữ liệu của SDK (tên trang utilities là tên cũ; nội dung là Models). Tất cả model import từ ssi_sdk.models:

from ssi_sdk.models import Account, OHLCData, PlaceOrderResponse, TradeMessage

Mọi model đều là dataclass; trường kiểu X | str | None nghĩa là SDK trả member enum khi nhận ra giá trị, trả chuỗi gốc khi giá trị lạ và None khi server không gửi. Các enum xem Enums.

Authentication

Token

TrườngKiểuMô tả
access_tokenstrToken truy cập (bị ẩn khi repr, không in/log)
token_typestrLoại token (mặc định "Bearer")
expires_atintThời điểm hết hạn, epoch giây (0 = không rõ / coi như đã hết hạn)
refresh_tokenstrToken làm mới (bị ẩn khi repr)
refresh_token_expires_atintThời điểm refresh token hết hạn

Thuộc tính: effective_expires_at (thời điểm hết hạn hiệu lực) và can_refresh (có thể refresh hay không).

OTPResponse

Kết quả của auth.request_otp_typed().

TrườngKiểuMô tả
messagestrThông báo từ server
transaction_idstr | NoneChỉ có với Smart OTP; truyền vào ensure_authenticated(transaction_id=...). Xem Smart OTP

Account

Account

TrườngKiểuMô tả
account_nostrSố tài khoản
account_typeAccountType | str | NoneLoại tài khoản; chuỗi gốc nếu loại lạ, None nếu server không gửi (không còn mặc định là Cash)

Market Data

OHLCData

TrườngKiểuMô tả
symbolstrMã chứng khoán
trading_datestrNgày giao dịch
open_pricefloat | intGiá mở cửa
high_pricefloat | intGiá cao nhất
low_pricefloat | intGiá thấp nhất
close_pricefloat | intGiá đóng cửa
volumeintKhối lượng
valuefloat | intGiá trị giao dịch

MarketIndexes

TrườngKiểuMô tả
indexstrMã chỉ số
index_namestrTên chỉ số
boardBoard | str | NoneSàn
board_rawstr | NoneMã sàn gốc server gửi

MarketIndexSummary

MarketIndexSummary không có trường index và board; mã chỉ số là tham số bạn truyền vào khi gọi.

TrườngKiểuMô tả
trading_datestrNgày giao dịch
index_valuefloatGiá trị chỉ số
index_changefloatThay đổi
index_change_percentfloatThay đổi (%)
total_tradeintTổng KL giao dịch
total_trade_valuefloatTổng giá trị giao dịch
total_advance_stockintSố mã tăng
total_decline_stockintSố mã giảm
total_steady_stockintSố mã đứng
total_matchintTổng khối lượng khớp
total_match_valuefloatTổng giá trị khớp
total_dealintTổng khối lượng thoả thuận
total_deal_valuefloatTổng giá trị thoả thuận
total_ceiling_stockintSố CP trần
total_floor_stockintSố CP sàn
total_prop_buyintTổng KL mua tự doanh
total_prop_buy_valuefloatTổng GT mua tự doanh
total_prop_sellintTổng KL bán tự doanh
total_prop_sell_valuefloatTổng GT bán tự doanh
total_buy_foreign / total_buy_foreign_valuetuỳ chọnKL / GT mua của khối ngoại
total_sell_foreign / total_sell_foreign_valuetuỳ chọnKL / GT bán của khối ngoại
net_purchases_foreign_volume / net_purchases_foreign_valuetuỳ chọnKL / GT mua ròng của khối ngoại

Các trường khối ngoại là tuỳ chọn (None nếu server không gửi).

SecuritiesInfo

Trường số mà server bỏ qua là None (không phải 0); ngày rỗng là None.

TrườngKiểuMô tả
symbolstrMã chứng khoán
boardBoard | str | NoneSàn
indexstr | NoneChỉ số
symbol_name_vistr | NoneTên tiếng Việt
symbol_name_enstr | NoneTên tiếng Anh
lot_sizeint | NoneLô giao dịch
listed_sharesint | NoneSố CP niêm yết
icb_codestr | NoneMã ngành ICB
icb_namestr | NoneTên ngành ICB
maturity_datestr | NoneNgày đáo hạn
first_trading_datestr | NoneNgày GD đầu tiên
last_trading_datestr | NoneNgày GD cuối cùng
cw_underlying_symbolstr | NoneMã CK cơ sở CW
cw_exercise_pricefloat | NoneGiá thực hiện CW
cw_execution_ratiofloat | NoneTỷ lệ thực hiện CW
i_indexfloat | NoneChỉ số I
i_navfloat | NoneGiá trị iNAV
open_interestint | NoneVị thế mở (phái sinh)
settlement_pricefloat | NoneGiá thanh toán (phái sinh)
stock_typestr | NoneLoại chứng khoán

MasterData

Giá trần / sàn / tham chiếu của một mã (từ get_master_data()).

TrườngKiểuMô tả
boardBoard | str | NoneSàn
symbolstrMã chứng khoán
trading_datestrNgày giao dịch
ceilingfloat | NoneGiá trần
floorfloat | NoneGiá sàn
ref_pricefloat | NoneGiá tham chiếu

CorporateAction

Một sự kiện quyền (cổ tức, thưởng, phát hành thêm, ...) của một mã (từ get_corporate_actions() và get_corporate_actions_historical()). Mọi trường đều là str đúng như server trả: ngày giữ nguyên dạng text YYYY/MM/DD, ratio không ép kiểu vì ý nghĩa phụ thuộc loại sự kiện. Trường nào server để trống (sự kiện mới công bố chưa có ngày giao dịch không hưởng quyền hoặc tỷ lệ) sẽ là "".

TrườngKiểuMô tả
symbolstrMã chứng khoán
event_titlestrTên sự kiện
exright_datestrNgày giao dịch không hưởng quyền
record_datestrNgày đăng ký cuối cùng
issue_datestrNgày phát hành
exchangestrMã sàn, ví dụ "HOSE"
ratiostrTỷ lệ sự kiện dạng text, ví dụ "0.9388"

SecuritiesSummary

TrườngKiểuMô tả
symbolstrMã chứng khoán
trading_datestrNgày giao dịch
price_changefloatThay đổi giá
price_change_percentfloatThay đổi giá (%)
open_pricefloatGiá mở cửa
high_pricefloatGiá cao nhất
low_pricefloatGiá thấp nhất
close_pricefloatGiá đóng cửa
average_pricefloatGiá trung bình
total_matchintTổng KL khớp
total_match_valuefloatTổng giá trị khớp
total_buyintTổng KL mua
total_trade_buyfloatTổng GT mua
total_sellintTổng KL bán
total_trade_sellfloatTổng GT bán
total_foreign_buy / total_foreign_buy_valuetuỳ chọnKL / GT mua của khối ngoại
total_foreign_sell / total_foreign_sell_valuetuỳ chọnKL / GT bán của khối ngoại
remain_foreign_room / total_foreign_roomtuỳ chọnRoom ngoại còn lại / tổng room ngoại
total_deal / total_deal_valuetuỳ chọnKL / GT thoả thuận
open_interest / settlement_pricetuỳ chọnVị thế mở / giá thanh toán (phái sinh)
ceiling / floor / ref_priceNoneEndpoint này không gửi; dùng get_master_data()

DownloadData và DownloadDataRequest đã deprecated, không dùng.

Portfolio

Các số dư (EquityAccountBalance, DerivativeAccountBalance) và vị thế (Position) có thể là None khi tài khoản chưa có dữ liệu, hãy kiểm tra None trước khi dùng.

EquityAccountBalance

TrườngKiểuMô tả
account_nostrSố tài khoản
account_balancefloatSố dư tài khoản
total_debtfloatTổng nợ
interest_loanfloatLãi vay
overdue_fee_loanfloatPhí vay quá hạn
withdrawablefloatTiền rút được
on_hold_cashfloatTiền tạm giữ
sell_unmatchedfloatTiền bán chờ khớp
sell_t0floatTiền bán T0
sell_t1floatTiền bán T1
sell_t2floatTiền bán T2
buy_unmatchedfloatTiền mua chờ khớp
buy_t0floatTiền mua T0
buy_t1floatTiền mua T1
buy_t2floatTiền mua T2
advance_cash_t0floatỨng tiền T0
advance_cash_t1floatỨng tiền T1
hold_subscriptionfloatTiền giữ đăng ký
dividendfloatCổ tức

DerivativeAccountBalance

TrườngKiểuMô tả
account_nostrSố tài khoản
account_balancefloatSố dư tài khoản
feefloatPhí
commissionfloatHoa hồng
interestfloatLãi
ext_interestfloatLãi ngoài
loanfloatVay
delivery_amountfloatGiá trị giao nhận
floating_plfloatLãi/lỗ chưa thực hiện
trading_plfloatLãi/lỗ giao dịch
total_plfloatTổng lãi/lỗ
withdrawablefloatTiền rút được
cash_ssifloatTiền mặt SSI
valid_non_cash_ssifloatTài sản phi tiền mặt hợp lệ SSI
withdrawable_ssifloatTiền rút được SSI
cash_vsdcfloatTiền mặt VSDC
valid_non_cash_vsdcfloatTài sản phi tiền mặt hợp lệ VSDC
withdrawable_vsdcfloatTiền rút được VSDC

cash_withdrawable_ssi và cash_withdrawable_vsdc là alias cũ của withdrawable_ssi / withdrawable_vsdc; vẫn đọc được nhưng phát DeprecationWarning.

EquityPosition

TrườngKiểuMô tả
account_nostrSố tài khoản
symbolstrMã chứng khoán
quantityintTổng số lượng
sellable_quantityintSố lượng bán được
cost_pricefloatGiá vốn
buying_quantityintSL đang mua
selling_quantityintSL đang bán
mortgage_quantityintSL cầm cố
block_quantityintKhối lượng phong toả
dividend_quantityintKhối lượng cổ tức
bought_quantityintKhối lượng đã mua
sold_quantityintKhối lượng đã bán
t1_buy_quantityintKL mua T1
t2_buy_quantityintKL mua T2
t1_sell_quantityintKL bán T1
t2_sell_quantityintKL bán T2
restricted_quantityintKhối lượng hạn chế

DerivativePosition

TrườngKiểuMô tả
account_nostrSố tài khoản
symbolstrMã hợp đồng
long / short / netintVị thế mua / bán / ròng
bid_avg_price / ask_avg_pricefloatGiá TB mua / bán
floating_pl / trading_plfloatLãi/lỗ
trade_pricefloatGiá giao dịch

AllDerivativePosition

TrườngKiểuMô tả
open_positionslist[DerivativePosition]Vị thế đang mở
closed_positionslist[DerivativePosition]Vị thế đã đóng
account_nostrSố tài khoản

Order

TrườngKiểuMô tả
account_nostrSố tài khoản
client_request_idstrID yêu cầu client
order_idstrID lệnh
symbolstrMã chứng khoán
sideOrderSide | str | NoneMua/Bán
order_typeOrderType | str | NoneLoại lệnh
priceint | float | OrderType | strGiá đặt (có thể là loại lệnh như ATO, ATC)
avg_pricefloatGiá TB khớp
quantityintSL đặt
os_quantityint | NoneSL chờ
filled_quantityintSL đã khớp
cancel_quantityintSL đã huỷ
statusOrderStatus | str | NoneTrạng thái lệnh
input_time / modify_timestrThời gian đặt / sửa
messagestrThông báo

Trading Responses

PlaceOrderResponse

order_id, client_request_id, status (OrderStatus | str)

ModifyOrderResponse

client_modify_id, order_id, client_request_id, status (OrderStatus | str)

CancelOrderResponse

client_cancel_id, order_id, client_request_id, status (OrderStatus | str)

MaxBuySellResponse

account_no, symbol, max_buy_quantity, max_sell_quantity, margin_ratio (str | None), purchasing_power (int | None)

Conditional Orders (FCO)

FCOPlaceResponse

Kết quả đặt lệnh điều kiện — fco_id

FCOCancelResponse

Kết quả huỷ lệnh điều kiện — fco_id

FCOListResponse

Danh sách lệnh điều kiện (phân trang).

TrườngKiểuMô tả
page_indexintTrang hiện tại
page_sizeintKích thước trang
items_countintTổng số bản ghi
pages_countintTổng số trang
fco_listlist[FCOInfo]Danh sách lệnh FCO

FCOInfo

Thông tin chi tiết một lệnh điều kiện.

TrườngKiểuMô tả
fco_idstrMã lệnh FCO
client_idstrUsername / Client ID
account_nostrSố tài khoản
quantityintKhối lượng đặt
pricestrGiá đặt
price_slipfloat | NoneĐộ trượt giá
order_typeOrderType | str | NoneLoại lệnh được đặt khi kích hoạt
symbolstrMã chứng khoán
typeFCOType | str | NoneLoại lệnh điều kiện
from_datestrNgày bắt đầu hiệu lực
to_datestrNgày kết thúc hiệu lực
matched_quantityintKhối lượng đã khớp
is_place_orderboolĐã đẩy lệnh vào sổ hay chưa
statusFCOStatus | str | NoneTrạng thái lệnh FCO
detailstrChi tiết trạng thái
paramsFCOParams | NoneTham số kích hoạt lệnh FCO

FCOParams

Tham số kích hoạt của lệnh điều kiện.

TrườngKiểuMô tả
stop_pricefloat | NoneGiá dừng / giá kích hoạt
sideOrderSide | NoneChiều lệnh (Mua/Bán)
active_pricefloat | NoneGiá kích hoạt (Trailing Stop)
trailing_amountfloat | NoneKhoảng bám sát (Trailing Amount)
tp_active_pricefloat | NoneGiá kích hoạt chốt lời (Take Profit)
sl_active_pricefloat | NoneGiá kích hoạt cắt lỗ (Stop Loss)
tp_pricestr | NoneGiá chốt lời
sl_pricestr | NoneGiá cắt lỗ
tp_slipfloat | NoneTrượt giá chốt lời
sl_slipfloat | NoneTrượt giá cắt lỗ
operatorFCOOperator | str | NoneToán tử so sánh kích hoạt

Các lớp tham số khi đặt lệnh (GTDParams, StopParams, TrailingStopParams, OCOParams, BullBearParams) có thêm trường tuỳ chọn code (mã OTP, mặc định None).

FCOStatusHistoryItem

Một dòng trong lịch sử đổi trạng thái của lệnh điều kiện (từ get_fco_status_history).

TrườngKiểuMô tả
statestrTrạng thái (xem FCOStatus ở Enums)
timestrThời điểm đổi trạng thái
codestr | NoneMã đi kèm trạng thái (nếu có)
detailstrChi tiết

FCOOrderBookResponse

Nhật ký khớp lệnh FCO (phân trang).

TrườngKiểuMô tả
page_indexintTrang hiện tại
page_sizeintKích thước trang
items_countintTổng số bản ghi
pages_countintTổng số trang
order_booklist[FCOOrder]Danh sách nhật ký lệnh FCO

FCOOrder

Nhật ký giao dịch / thực thi của lệnh FCO.

TrườngKiểuMô tả
fco_idstrMã lệnh FCO gốc
account_nostrSố tài khoản
quantityintKhối lượng
pricestrGiá đặt
symbolstrMã chứng khoán
typeFCOType | str | NoneLoại lệnh điều kiện
sideOrderSide | str | NoneChiều lệnh
order_typeOrderType | str | NoneLoại lệnh con
is_main_orderboolLà lệnh chính
is_attached_orderboolLà lệnh kèm theo
created_time / updated_timestrThời gian tạo / cập nhật
unique_idstrID duy nhất
order_idstrMã lệnh trên sàn
matched_quantityintKhối lượng đã khớp
os_quantityintKhối lượng chờ khớp
avg_pricefloatGiá khớp trung bình
statusOrderStatus | str | NoneTrạng thái lệnh con
detailstrChi tiết

Batch Order

Các model của batch order (đặt / huỷ nhiều lệnh trong một request). Cách dùng, ví dụ và giới hạn: Services, mục 5.4.

Hai TypedDict dưới đây mô tả từng phần tử bạn truyền vào place_batch_orders / cancel_batch_orders:

KiểuTrường bắt buộcTrường tuỳ chọn
BatchPlaceOrderItemaccount_no, symbol, side, quantity, price, order_typeclient_request_id
BatchCancelOrderItemaccount_noorder_id, client_request_id

BatchOrderRequest

TrườngKiểuMô tả
batch_request_idstrID của cả batch (dùng lại id đã dùng là HTTP 409)
batch_request_timeintThời điểm gửi batch, epoch mili giây
orderslist[dict]Danh sách lệnh

Có to_dict() (payload camelCase) và to_str() (chuỗi JSON được ký và gửi đi).

BatchOrderResult

Kết quả của từng lệnh trong batch.

TrườngKiểuMô tả
client_request_idstrID yêu cầu client của lệnh
order_idstrID lệnh
statusOrderStatus | strTrạng thái
successboolLệnh này có thành công hay không (mặc định False)
error_codestrMã lỗi server khi lệnh bị từ chối
error_messagestrNội dung lỗi server khi lệnh bị từ chối
client_cancel_idstrID của yêu cầu huỷ (do SDK sinh, chỉ khi huỷ batch)

BatchOrderResponse

TrườngKiểuMô tả
batch_request_idstrID của cả batch
resultslist[BatchOrderResult]Kết quả từng lệnh

Lưu ý: số lệnh tối đa mỗi batch trong SDK là MAX_BATCH_ORDERS = 20 (ghi đè được bằng Config.max_batch_orders), trong khi tài liệu API reference ghi 50; chưa xác nhận được giá trị server áp dụng. Xem Configuration và Services, mục 5.4.

Streaming Messages

Các message này nhận qua callback của stream.streaming, xem Services, mục 6.

TradeMessage

type, trading_time, symbol, price, quantity, side, total_volume, cùng các trường tuỳ chọn open, high, low, avg (None nếu server không gửi).

IntervalMessage

TrườngKiểuMô tả
typeDataTypeLoại dữ liệu
interval_timestrThời gian interval
trading_timestrThời gian giao dịch
symbolstrMã chứng khoán
openfloat | intGiá mở
highfloat | intGiá cao
lowfloat | intGiá thấp
closefloat | intGiá đóng
volumeintKhối lượng

IndexTickMessage

Tick thời gian thực của chỉ số (xem Services, mục 6.7).

TrườngKey serverMô tả
typeLoại dữ liệu
symbolsMã chỉ số
boardbSàn
statusssTrạng thái
trading_timetThời gian
valuevGiá trị chỉ số
changecThay đổi
change_percentcrThay đổi (%)
advancesadvSố mã tăng
declinesdecSố mã giảm
no_changencSố mã đứng
ceilingsceSố mã trần
floorsflSố mã sàn
total_match_valuetmvTổng giá trị khớp
total_match_quantitytmqTổng khối lượng khớp
total_put_valuetvpTổng giá trị thoả thuận
total_put_quantitytqpTổng khối lượng thoả thuận
total_quantitytqTổng khối lượng
total_valuetvTổng giá trị
rawToàn bộ data server gửi

Chưa xác nhận: tên thuộc tính được suy ra từ ký hiệu viết tắt của server, chưa đối chiếu với frame thật. Khi cần chắc chắn, đọc msg.raw.

IndexSummaryMessage

TrườngKiểuMô tả
indexstrMã chỉ số lấy từ topic, viết hoa (ví dụ "VN30")
datadictPayload gốc server gửi

Các trường trong data chưa được tài liệu công khai nên SDK không đoán; đọc bằng msg.get("key1", "key2", default=None) (trả giá trị của key đầu tiên có mặt).

MarketFlagMessage

TrườngKiểuMô tả
boardstrMã sàn như server gửi: HOSE, HNX, UPCOM hoặc DER (phái sinh, khác DERIVATIVES của enum Board)
trading_timestrThời gian
flagstrCờ phiên (ví dụ "ATO", "LO", "ATC"), giữ nguyên chuỗi

MarketDataMessage

symbol, board, trading_time, ceiling, floor, ref_price

QuoteMessage

type, trading_time, symbol, bid_prices, bid_volumes, ask_prices, ask_volumes

ForeignRoomMessage

type, trading_time, symbol, total_room, current_room, buy_quantity, buy_value, sell_quantity, sell_value

PutMessage

type, trading_time, symbol, price, quantity, total_quantity, total_value

OddLotMessage

type, trading_time, symbol, price, quantity, bid_prices, bid_volumes, ask_prices, ask_volumes

MarketStatusMessage

market, status, trading_date

OrderStatusMessage

type, account_no, client_request_id, order_id, symbol, side, order_type, price, quantity, os_quantity, filled_quantity, cancel_quantity, status, input_time, modified_time, message, cùng avg_price, reject_reason, system_request_id, error_code, error_message, notify_id, connection_id.

modify_time là alias deprecated của modified_time. os_quantity là None khi lệnh lấy từ REST order book. Lệnh bị server từ chối báo status RJ kèm error_code.

OrderMatchMessage

type, notify_id, connection_id, client_request_id, order_id, symbol, side, account_no, match_price, match_qty, match_time

PortfolioMessage

type, account_no, symbol, long_qty, short_qty, net, bid_avg_price, ask_avg_price, trade_price, market_price, floating_pl, trading_pl, position_type

total_asset, cash_balance và stock_value đã deprecated và luôn là None.

FCOOrderUpdateMessage

Cập nhật trạng thái lệnh điều kiện FCO (streaming, nhận qua on_trading khi event_type == "fcoEvent").

TrườngKiểuMô tả
fco_idstrMã lệnh FCO
process_statusFCOStatus | NoneTrạng thái xử lý lệnh FCO (INIT, WAIT, WC, TER, ...)
matched_quantityintKhối lượng đã khớp
is_place_orderboolĐã đẩy lệnh vào sổ hay chưa
symbolstrMã chứng khoán
quantityintKhối lượng đặt
pricestrGiá đặt
account_nostrSố tài khoản
updated_timestrThời gian cập nhật (YYYY/MM/DD HH:MM:SS)
statusstrMã trạng thái
messagestrThông báo chi tiết / lý do kích hoạt, ngắt kết nối
usernamestrUsername đặt lệnh
event_typestrLoại sự kiện ("fcoEvent")
typeFCOType | NoneLoại lệnh điều kiện (GTD, STOP, ...)

HeartbeatMessage

method, channel, status, message

ConnectionEvent

Sự kiện trạng thái kết nối của stream, nhận qua on_connection. Là frozen dataclass, không export ở top level: from ssi_sdk.transport.reconnect import ConnectionEvent.

TrườngKiểuMô tả
statestrconnected, reconnected, disconnected hoặc failed
reconnect_countintSố lần đã reconnect (mặc định 0)
errorException | NoneLỗi gây ra sự kiện (mặc định None)

Chi tiết: Services, mục 6.9.

Trading WebSocket

Import từ ssi_sdk (ở 3.3.1 trở về trước nằm trong ssi_sdk.experimental; module đó đã bị xoá ở 3.3.2). Cách dùng đầy đủ: Services, mục 7; cách tạo service: Client Classes.

TradingWSResponse

Kết quả của một lệnh gửi qua Trading WebSocket.

TrườngKiểuMô tả
idstrID request
methodstrMethod đã gọi
statusintMã trạng thái (mặc định 200)
resultAnyDữ liệu trả về
rate_limitdictThông tin rate limit server trả kèm
received_timeint | NoneThời điểm nhận phản hồi

TradingWSError

Kế thừa WebSocketError, raise khi server từ chối lệnh hoặc từ chối kết nối. Constructor TradingWSError(status, code, message); thuộc tính .status, .error_code và .server_message. Xem Exceptions.

Wrapper Types

AccountBalance

TrườngKiểuMô tả
equityEquityAccountBalance | NoneSố dư cơ sở
derivativeDerivativeAccountBalance | NoneSố dư phái sinh

Position

TrườngKiểuMô tả
equitylist[EquityPosition] | NoneVị thế cơ sở
derivativeAllDerivativePosition | NoneVị thế phái sinh

PPMMR

TrườngKiểuMô tả
equityEquityPPMMR | NonePPMMR cơ sở
derivativeDerivativePPMMR | NonePPMMR phái sinh

OrderBook

TrườngKiểuMô tả
orderslist[Order]Danh sách lệnh
total_ordersintTổng số lệnh

Hằng số

Các hằng số giới hạn của SDK (module ssi_sdk.constant). Giá trị chỉ là mặc định của SDK; những giá trị liên quan đến server có thể khác thực tế.

Hằng sốGiá trịÝ nghĩa
MAX_CLIENT_REQUEST_ID_LENGTH20Độ dài tối đa của client_request_id
MAX_BATCH_ORDERS20Số lệnh tối đa mỗi batch (mặc định SDK; ghi đè bằng Config.max_batch_orders)
DEFAULT_SIZE / DEFAULT_PAGE1000 / 1Kích thước / số trang mặc định khi phân trang
CORPORATE_ACTIONS_MAX_DAYS5Khoảng ngày tối đa của một request corporate actions (ngày)
CORPORATE_ACTIONS_LANGUAGES("vn", "en")Giá trị language được phép cho corporate actions
TOPIC_MARKET_FLAG"market.flag"Topic cờ phiên
TOKEN_EXPIRY_SKEW_MS30000Token coi như hết hạn sớm 30 giây
WS_RECONNECT_MAX_DELAY_MS60000Độ trễ reconnect tối đa của stream
WS_RATE_LIMIT_BACKOFF_MS30000Thời gian chờ khi bị rate limit trên WebSocket
WS_TOKEN_REFRESH_LEAD_MS60000Refresh token trước khi hết hạn khoảng này
WS_SERVER_MAX_CONNECTIONS10Số kết nối WebSocket tối đa phía server
WS_MAX_FRAME_BYTES4000Kích thước frame tối đa SDK gửi (giới hạn server là 4096)

Các hằng số thời gian có hậu tố _ms (mili giây). Các tuỳ chọn cấu hình tương ứng xem Configuration.

Trên trang này