FCO và tham số theo loại lệnh
Một số ví dụ về các tham số cần tương ứng với từng loại lệnh điều kiện
stop_limit
"price": "string",
"side": "B/S", "stopPrice": “postive float”, "operator": "greater_or_equal/ lesser_or_equal/ greater/ lesser/ equal"
{
"instrumentID": "SSI",
"side": "S",
"type": "stop_limit",
"price": "30500",
"priceSlip": 0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"stopPrice": 30500,
"operator": "greater_or_equal",
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Tương tự lệnh Stop, tuy nhiên lệnh được đẩy lên sở với mức giá limit KH đã đặt.
Stop
Các tham số cần điền: "side": "B/S", "stopPrice": “postive float”,
"operator": "greater_or_equal/ lesser_or_equal/ greater/ lesser/ equal"
{
"instrumentID": "SSI",
"side": "S",
"type": "Stop",
"price": "30500",
"priceSlip": 0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"stopPrice": 30500,
"operator": "greater_or_equal",
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh dừng. Lệnh sẽ được kích hoạt khi thỏa mãn điều kiện về giá. Lệnh được đẩy lên sở với giá thị trường.
gtd
"side": "B/S"
{
"instrumentID": "SSI",
"side": "S",
"type": "gtd",
"price": "30500",
"priceSlip": 0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh có hiệu lực nhiều ngày. Lệnh được trigger mỗi ngày cho đến khi gặp một trong các điều kiện sau thì dừng:
Khớp hết KL lệnh gốc
Người dùng hủy lệnh
Sau ngày hết hiệu lực.
bullbear
"side": "B/S", "tpActivePrice": "postive float", "tpPrice": "5000/MP/MOK/MTL", "tpSlip": "postive float", "slActivePrice": "postive float", "slPrice": "5000/MP/MOK/MTL", "slSlip": "postive float"
{
"instrumentID": "41I1F7000",
"side": "B",
"type": "bullbear",
"price": "MTL",
"priceSlip": 0.50,
"quantity": 1,
"account": "{{DerivativeAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"stopPrice": 0,
"activePrice": 0.0,
"trailingAmount": 0,
"tpActivePrice": 1555,
"slActivePrice": 1540,
"tpPrice": "1556",
"slPrice": "1541",
"tpSlip": 1,
"slSlip": 1,
"operator": "",
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh chốt lãi, cắt lỗ (chưa có vị thế): Cho phép KH đính kèm lệnh chốt lãi, cắt lỗ với một lệnh chính.
Khi lệnh chính khớp, hệ thống sẽ sinh ra 1 lệnh OCO có chiều ngược với chiều của lệnh chính
oco
"side": "B/S", "tpActivePrice": "postive float", "tpPrice": "50000/MP/MTL/MOK/MAK", "tpSlip": "postive float", "slActivePrice": "postive float", "slPrice": "50000/MP/MTL/MOK/MAK", "slSlip": "postive float"
{
"instrumentID": "SSI",
"side": "S",
"type": "oco",
"price": "MP",
"priceSlip": 0.0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"stopPrice": 0,
"activePrice": 0.0,
"trailingAmount": 0,
"tpActivePrice": 30500,
"slActivePrice": 20000,
"tpPrice": "30500",
"slPrice": "30500",
"tpSlip": 100,
"slSlip": 100,
"operator": "",
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh cặp dùng cho việc đặt lệnh chốt lãi, cắt lỗ cho vị thế đã có sẵn trong danh mục.
Khi điều kiện kích hoạt của một lệnh (a) thỏa mãn thì hệ thống sẽ kiểm tra:
Nếu lệnh còn lại (b) đã được kích hoạt thì hủy lệnh con của lệnh đó
Đẩy lệnh thỏa mãn điều kiện kích hoạt đi sau khi hủy lệnh thành công. KL của lệnh = KL khớp còn lại của lệnh con lệnh (b)
trailing_stop
"side": "B/S", "activePrice": "postive float", "trailingAmount": "postive float"
{
"instrumentID": "SSI",
"side": "S",
"type": "trailing_stop",
"price": "MP",
"priceSlip": 0.0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"activePrice": 28000,
"trailingAmount": 1000,
"code": "",
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh Stop với mức giá Stop dịch chuyển theo xu hướng của thị trường. Mức giá đẩy lệnh là giá thị trường.
trailing_stop_limit
"side": "B/S",
"price": "string",
"activePrice": "postive float", "trailingAmount": "postive float"
{
"instrumentID": "SSI",
"side": "S",
"type": "trailing_stop_limit",
"price": "MP",
"priceSlip": 0.0,
"quantity": 1000,
"account": "{{MarginAccount}}",
"fromDate": "10/07/2025 08:00:00",
"toDate": "15/07/2025 23:59:59",
"activePrice": 28000,
"trailingAmount": 1000,
"userAgent": "agent fctrading app",
"deviceID":"0A:B1:92:D3:5S:8G"
}
Lệnh Stop với mức giá stop dịch chuyển theo xu hướng của thị trường. Mức giá đẩy lệnh đi là mức giá được tính toán từ giá stop.
Last updated