API List
Token and Authentication code
Query cash and derivatives accounts
API Method Path cash/unsettleSoldTransaction
cash/cashInAdvanceHistories
Online Right Subscription
Configuration
Method Content Content Header (Authorization, Content-Type)
Request access
POST AccessToken
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/AccessToken
To get token to access APIs.
Details
Input Output
Field Type Required? Description Your account's authentication type. Supported values: 0 (PIN), 1 (OTP)
If true: you will not have to fill in authentication code for each transaction. The code will be saved within the login sesion.
If false: you will have to fill in authentication code for each transaction.
Sample
Copy Input:
{
consumerID : "38f5fdfa56b44d5ab8b95895eb588e99" ,
consumerSecret : "6d61bffefc6540fc837c71afd2ca4bcf" ,
twoFactorType : 1 ,
code : "123456789" ,
isSave : false
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
"accessToken" : "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ”
}
Copy Input:
{
consumerID : "38f5fdfa56b44d5ab8b95895eb588e99" ,
consumerSecret : "6d61bffefc6540fc837c71afd2ca4bcf" ,
twoFactorType : 0 ,
code : "123456789" ,
isSave : true
}
Output:
{
message : "Key does not exist." ,
status : 400 ,
data : null
}
POST GetOTP
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/GetOTP
To get OTP code if you registered SMS OTP/Email OTP.
If you get OTP code for 5 times without verification, your OTP service will be temporarily blocked and then automatically unlocked after sometimes.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
"consumerID" : "968d7b5940f5437583021aea2b038f35" ,
"consumerSecret" : "11ab3fc6af954c59ba646fac016f30cb"
}
Output:
{
message : "Success" ,
status : 200
}
Copy Input:
{
"consumerID" : "968d7b5940f5437583021aea2b038f351" ,
"consumerSecret" : "11ab3fc6af954c59ba646fac016f30cb"
}
Output:
{
"message" : "ConsumerID is invalid" ,
"status" : 400
}
GET auditOrderBook
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/auditOrderBook
To get the audit of the orders.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
account : "1184418"
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "1184418" ,
"orders" : [
{
"uniqueID" : "73885549" ,
"orderID" : "T202306146w273885549" ,
"buySell" : "B" ,
"price" : 1000 ,
"quantity" : 100 ,
"filledQty" : 0 ,
"orderStatus" : "RJ" ,
"marketID" : "VNFE" ,
"inputTime" : "1686730747945" ,
"modifiedTime" : "1686730747945" ,
"instrumentID" : "VN30F2306" ,
"orderType" : "LO" ,
"cancelQty" : 0 ,
"avgPrice" : 0 ,
"isForcesell" : "F" ,
"isShortsell" : "F" ,
"rejectReason" : "Invalid market status" ,
"lastErrorEvent" : null
}
]
}
}
POST OrderBook
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/OrderBook
To get latest orderbook, for both cash and derivatives accounts.
Details
Input Output
Field Type Required? Description Input the account to query. Accept both cash and derivatives accounts.
Sample
Copy Input:
{
account : "1184418"
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "1184418" ,
"orders" : [
{
"uniqueID" : "73885549" ,
"orderID" : "T202306146w273885549" ,
"buySell" : "B" ,
"price" : 1000 ,
"quantity" : 100 ,
"filledQty" : 0 ,
"orderStatus" : "RJ" ,
"marketID" : "VNFE" ,
"inputTime" : "1686730747945" ,
"modifiedTime" : "1686730747945" ,
"instrumentID" : "VN30F2306" ,
"orderType" : "LO" ,
"cancelQty" : 0 ,
"avgPrice" : 0 ,
"isForcesell" : "F" ,
"isShortsell" : "F" ,
"rejectReason" : "Invalid market status"
}
]
}
}
GET orderHistory
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/orderHistory
To get order history, for both cash and derivatives accounts.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
account : "0901358" ,
startDate : “ 18 / 11 / 2020 ” ,
endDate : “ 18 / 11 / 2020 ”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
orderHistories : [
{
uniqueID : null ,
orderID : "12626539" ,
buySell : "B" ,
price : 800.0 ,
quantity : 10 ,
filledQty : 0 ,
orderStatus : "RJ" ,
marketID : "VNFE" ,
inputTime : "1603157594668" ,
modifiedTime : "1603157594668" ,
instrumentID : "VN30F2012" ,
orderType : "LO" ,
cancelQty : 0 ,
avgPrice : 0.0 ,
isForcesell : null ,
isShortsell : null
}
] ,
account : "0901358"
}
}
GET cashAccountBalance
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/cashAcctBal
To get cash account's balance.
Details
Input Output
Field Type Required Description
Field Type Describe Sell amount to receive on T1
Sell amount to receive on T2
Sample
Copy Input:
{
account : "0901351" ,
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
account : "0901351" ,
cashBal : 7459369481 ,
cashOnHold : 0 ,
secureAmount : 0 ,
withdrawable : 7459367581 ,
receivingCashT1 : 0 ,
receivingCashT2 : 0 ,
matchedBuyVolume : 0 ,
matchedSellVolume : 0 ,
debt : 1900 ,
unMatchedBuyVolume : 0 ,
unMatchedSellVolume : 864619337 ,
paidCashT1 : 0 ,
paidCashT2 : 0 ,
cia : 0 ,
purchasingPower : 7459367581 ,
totalAssets : 9726161481
}
}
GET stockPosition
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/stockPosition
To query stock positions of cash accounts.
Details
Input Output
Field Type Required? Description
Field Type Description = sum(maketprice * onhand)
Total settled quantity in the account, which includes: sellable, hold, block, mortgage, sellT0, sellT1. Not include bonus, buyT0, buyT1
Dividend and bonus quantity
Buy quantity matched on T0
Buy quantity settled on T1
Buy quantity settled on T2
Sell quantity matched on T0
Sel quantity settled on T1
Sell quantity settled on T2
Quantity restricted from trading
Market price of the stock
Sample
Copy Input:
{
account : "0901351" ,
}
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "0001011" ,
"totalMarketValue" : 0 ,
"stockPositions" : [
{
"marketID" : "VN" ,
"instrumentID" : "AMC" ,
"onHand" : 300 ,
"block" : 0 ,
"bonus" : 3819 ,
"buyT0" : 0 ,
"buyT1" : 0 ,
"buyT2" : 0 ,
"sellT0" : 0 ,
"sellT1" : 0 ,
"sellT2" : 0 ,
"avgPrice" : 1529 ,
"mortgage" : 0 ,
"sellableQty" : 300 ,
"holdForTrade" : 0 ,
"marketPrice" : 0
}
]
}
}
GET derivativeAccountBalance
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/derivAcctBal
To get derivatives account's balance.
Sample
Input Output
Field Type Required? Description
Sample
Copy Input:
{
account : "0901358" ,
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
account : "0901358" ,
accountBalance : 11166309263 ,
fee : 0 ,
commission : 0 ,
interest : 1514965 ,
loan : 0 ,
deliveryAmount : 0 ,
floatingPL : 0 ,
totalPL : 0 ,
marginable : 0 ,
depositable : 1148597520 ,
rcCall : 0 ,
withdrawable : 10912447363 ,
nonCashDrawableRCCall : 0 ,
internalAssets : {
cash : 1165730020 ,
validNonCash : 0 ,
totalValue : 11166309263 ,
maxValidNonCash : 0 ,
cashWithdrawable : 1148597520 ,
ee : 8197059272
} ,
exchangeAssets : {
cash : 10000579243 ,
validNonCash : 0 ,
totalValue : 10000579243 ,
maxValidNonCash : 0 ,
cashWithdrawable : 9763849843 ,
ee : 7322887382
} ,
internalMargin : {
initialMargin : 172660800 ,
deliveryMargin : 0 ,
marginReq : 172660800 ,
accountRatio : 1.5462656096416592 ,
usedLimitWarningLevel1 : 75 ,
usedLimitWarningLevel2 : 85 ,
usedLimitWarningLevel3 : 90 ,
marginCall : 0
} ,
exchangeMargin : {
marginReq : 172660800 ,
accountRatio : 1.7265079932330476 ,
usedLimitWarningLevel1 : 75 ,
usedLimitWarningLevel2 : 85 ,
usedLimitWarningLevel3 : 90 ,
marginCall : 0
}
}
}
GET derivativePosition
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/derivPosition
To get dervatives account's position. After getting the snapshot, you can subscribed streaming to get realtime update.
Details
Input Output
Field Type Required? Description
False: don't netoff position
Sample
Copy Input:
{
account : "0901358" ,
querySummary : true
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
account : "0901358" ,
openPosition : [
{
marketID : "VNFE" ,
instrumentID : "VN30F2106" ,
longQty : 8 ,
shortQty : 0 ,
net : 8 ,
bidAvgPrice : 0 ,
askAvgPrice : 0 ,
tradePrice : 1452.7 ,
marketPrice : 1452.7 ,
floatingPL : 0 ,
tradingPL : 0
} ] ,
closePosition : [ ]
}
}
GET maxBuyQty
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/maxBuyQty
To get max buy quantity. Applied for both cash and derivatives accounts.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
account : "0041691" ,
instrumentD : “SSI” ,
price : 17
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
account : "0041691" ,
maxBuyQty : 8241440 ,
marginRatio : "50%" ,
purchasingPower : 99292902171
}
}
GET maxSellQty
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/maxSellQty
To get max sell quantity. Applied for both cash and derivatives accounts.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
account : "0041691" ,
intrumentID : “SSI”
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "0041691" ,
"maxSellQty" : 2000
}
}
POST NewOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/NewOrder
To place orders.
Details
Input Output
Field Type Required? Description VN: cash market
VNFE: derivatives market
buy (B): mua/Sell (S): bán đã đặt theo orderID của lệnh
B: Buy
S: Sell
Giá đặt lệnh:
- Nếu loại lệnh là LO -> Giá đặt > 0
- Nếu loại lệnh khác LO -> Giá đặt = 0
ID đặt lệnh trong ngày. Bắt buộc 8 số random
True: conditional orders. Only applied for derivatives market.
If stopOrder = true -> stopPrice > 0
Required if stopType = true:
Stop loss amount, only applied for BullBear (stopType = B)
Take profit amount, only applied for BullBear (stopType = B)
Authentication code: PIN/OTP (depending on your registered authentication type)
Field Type Description Order type:
Order type = True: it is a conditional order (only applicable to Derivatives)
Order type = False: it is a normal order
Sample
Copy Input:
{
instrumentID : "SSI" ,
market : "VN" ,
buySell : "B" ,
orderType : "LO" ,
channelID : "IW" ,
price : 21000 ,
quantity : 300 ,
account : "0901351" ,
stopOrder : false ,
stopPrice : 0 ,
stopType : "string" ,
stopStep : 0 ,
lossStep : 0 ,
profitStep : 0
requestID: "1678195" ,
code : “ 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
requestID : "1678195" ,
requestData :
{
instrumentID : "SSI" ,
market : "VN" ,
buySell : "B" ,
orderType : "LO" ,
channelID : "IW" ,
price : 21000 ,
quantity : 300 ,
account : "0901351" ,
stopOrder : false ,
stopPrice : 0 ,
stopType : "string" ,
stopStep : 0 ,
lossStep : 0 ,
profitStep : 0
}
}
}
Copy Input:
{
instrumentID : "SSI" ,
market : "VN" ,
buySell : "B" ,
orderType : "ATO" ,
channelID : "IW" ,
price : 21000 ,
quantity : 300 ,
account : "0901351" ,
stopOrder : false ,
stopPrice : 0 ,
stopType : "string" ,
stopStep : 0 ,
lossStep : 0 ,
profitStep : 0
requestID: "1678195" ,
code : “ 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Price is null or equal zero when order is market order" ,
status : 400 ,
data : null
}
POST ModifyOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/ModifyOrder
To amend an order.
Details
Input Output
Field Type Required? Description instrument of the amended order
VN: cash market
VNFE: derivatives market
side of the amended order
Unique id of the request generated by client. Required 8 digits.
Sample
Copy Input:
{
requestID : "93235974" ,
orderID : "12658867" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
requestID : "93235974" ,
requestData : {
orderID : "12658867" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
}
}
}
Copy Input:
{
requestID : "93235971" ,
orderID : "" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
data : null ,
message : "’Order ID’ must not be empty " ,
status : 400
}
POST CancelOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/CancelOrder
To cancel an order.
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
requestID : "93235974" ,
orderID : "12658867" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
requestID : "93235974" ,
requestData : {
orderID : "12658867" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
}
}
}
Copy Input:
{
requestID : "93235971" ,
orderID : "" ,
price : 1410 ,
quantity : 2 ,
account : "0901358" ,
instrumentID : "VN30F2106" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
data : null ,
message : "’Order ID’ must not be empty " ,
status : 400
}
POST derNewOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/derNewOrder
To place derivatives orders.
Details
Input Output
Field Type Required? Description
True: conditional order, applied to derivatives market only.
If stopOrder = true -> stopPrice > 0
Required if stopType = true:
only applied for BullBear (stopType = B)
Only applied for BullBear (stopType = B)
Sample
Copy Input:
{
instrumentID : "VN30F2306" ,
market : "VNFE" ,
buySell : "B" ,
orderType : "LO" ,
channelID : "TA" ,
price : 1200 ,
quantity : 10 ,
account : "1184418" ,
stopOrder : false ,
stopPrice : 0 ,
stopType : "string" ,
stopStep : 0 ,
lossStep : 0 ,
profitStep : 0
requestID: "1678198" ,
code : “ 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading "
}
Output:
{
" message ": " Success ",
" status ": 200,
" data ": {
" requestID ": " 3407154 ",
" requestData ": {
" instrumentID ": " VN 30 F 2306 ",
" market ": " VNFE ",
" buySell ": " B ",
" orderType ": " LO ",
" channelID ": " TA ",
" price ": 1200,
" quantity ": 100,
" account ": " 1184418 ",
" stopOrder ": false,
" stopPrice ": 0,
" stopType ": "",
" stopStep ": 0,
" lossStep ": 0,
" profitStep ": 0
}
}
}
Copy Input:
{
instrumentID : "SSI" ,
market : "VN" ,
buySell : "B" ,
orderType : "ATO" ,
channelID : "IW" ,
price : 21000 ,
quantity : 300 ,
account : "0901351" ,
stopOrder : false ,
stopPrice : 0 ,
stopType : "string" ,
stopStep : 0 ,
lossStep : 0 ,
profitStep : 0
requestID: "1678195" ,
code : “ 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Price is null or equal zero when order is market order" ,
status : 400 ,
data : null
}
POST derModifyOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/derModifyOrder
To amend a derivatives order.
Details
Input Output
Field Type Required? Description Authentication code: PIN, OTP (depending your registered authentication type)
Sample
Copy Input:
{
requestID : "93235974" ,
orderID : "12658867" ,
price : 1410 ,
quantity : 3 ,
account : "1184418" ,
instrumentID : "VN30F2306" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
requestID : "93235974" ,
requestData : {
orderID : "12658867" ,
price : 1410 ,
quantity : 3 ,
account : "1184418" ,
instrumentID : "VN30F2306" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
}
}
}
Copy Input:
{
requestID : "93235974" ,
orderID : "" ,
price : 1410 ,
quantity : 3 ,
account : "1184418" ,
instrumentID : "VN30F2306" ,
marketID : "VNFE" ,
buySell : "B" ,
orderType : "LO"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
data : null ,
message : "’Order ID’ must not be empty " ,
status : 400
}
POST derCancelOrder
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/derCancelOrder
To cancel a derivatives order.
Details
Input Output
Field Type Required? Description Authentication code: PIN/OTP depending on your registered authentication type
Field Type Description uniqueid of the cancel instruction
ID of the going-to-cancel order
Sample
Copy Input:
{
orderID : "12658867" ,
account : "1184418" ,
marketID : "VNFE" ,
instrumentID : "VN30F2306" ,
buySell : "B" ,
requestID : "52513603"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "Success" ,
status : 200 ,
data : {
requestID : "52513603" ,
requestData : {
orderID : "12658867" ,
account : "1184418" ,
marketID : "VNFE" ,
instrumentID : "VN30F2106" ,
buySell : "B" ,
requestID : "52513603"
}
}
}
Copy Input:
{
orderID : " " ,
account : "0901358" ,
marketID : "VNFE" ,
instrumentID : "VN30F2106" ,
buySell : "B" ,
requestID : "52513603"
code:” 123456789 ” ,
deviceID : "MAC Address" ,
userAgent : “FCTrading”
}
Output:
{
message : "’Order ID' must not be empty." ,
status : 400 ,
data : null
}
GET rateLimit
Copy https://fc-tradeapi.ssi.com.vn/api/v2/Trading/rateLimit
Get rate Limit
Details
Output
Field Type Description The set rateLimit information includes one of the following cases:
* -> All APIs
post:* -> API method POST
get:* -> API method GET
*:*/api_name -> rateLimit API name
Sample:
Copy Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : [
{
"endpoint" : "*" ,
"period" : "1s" ,
"limit" : 5
} ,
{
"endpoint" : "*" ,
"period" : "5s" ,
"limit" : 30
}
]
}
Cash
GET cashInAdvanceAmount
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/cashInAdvanceAmount
Query cash in advance available amount
Details
Input Output
Field Type Required? Description
Sample :
Copy Input:
{
account : "8888881"
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "8888881" ,
"ciaAmounts" : [
{
"dueDate" : "08/03/2023" ,
"sellValue" : 3000000.0 ,
"netSellValue" : 0.0 ,
"advance" : 0.0 ,
"cashAdvance" : 0.0
}
]
}
}
GET unsettleSoldTransaction
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/unsettleSoldTransaction
Query unsettle sold transactions
Details
Input Output
Field Type Required? Description
Field Type Description unsettledSoldTransactions
Sample:
Copy Input:
{
account : "8888881" ,
settleDate : "10/03/2023"
}
Output:
{
"message" : "Success" ,
"status" : 200 ,
"data" : {
"account" : "8888881" ,
"unsettledSoldTransactions" : [
{
"tradeDate" : "08/03/2023" ,
"instrumentID" : "SSI" ,
"quantity" : 100 ,
"price" : 0.0 ,
"netSellValue" : 1990000.0
} ,
{
"tradeDate" : "08/03/2023" ,
"instrumentID" : "SSI" ,
"quantity" : 100 ,
"price" : 0.0 ,
"netSellValue" : 1990000.0
} ,
{
"tradeDate" : "08/03/2023" ,
"instrumentID" : "SSI" ,
"quantity" : 100 ,
"price" : 0.0 ,
"netSellValue" : 117410.0
}
]
}
}
GET transferHistories
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/transferHistories
Query cash transfer histories
Details
Input Output
Field Type Required? Description
Dữ liệu Kiểu Mô tả Danh sách lịch sử chuyển tiền và Nộp/Rút ký quỹ
Loại giao dịch (Nộp/ Rút)
Sample:
Copy Input:
account:8888881
fromDate: 10/01/2023
toDate: 10/08/2023
Output:
{
"message": "Success",
"status": 200,
"data": {
"transferHistories": [
{
"transactionID": "101660519",
"date": "07/03/2023 11:54:22",
"account": "8888881",
"beneficiaryAccount": "8888886",
"amount": 1000000,
"bankName": "TECHCOMBANK_NH KỸ THƯƠNG",
"bankBranchName": "CN THANG LONG",
"beneficiary": "TK tự doanh CK niêm yết (TK 8)",
"remark": "Huyen test chuyen tien sang 6",
"type": "W",
"status": "A"
}
]
}
}
GET cashInAdvanceHistories
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/cashInAdvanceHistories
Query cash in advance histories
Details
Input Output
Field Type Required? Description
Dữ liệu Kiểu Mô tả I: Fee and D & W: ciaAmount
Note:
fromDate - toDate not more than 1 month
The time for searching the past should not exceed 6 months
Sample:
Copy Input:
account:0001011
fromDate: 10/01/2023
toDate: 10/08/2023
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0001011",
"ciaHistories": [
{
"transactionID": "20230731-45895",
"dateTime": "31/07/2023 09:01:56",
"totalAmount": 200000,
"details": [
{
"type": "D",
"value": 200000,
"settleDate": null
},
{
"type": "I",
"value": 50000,
"settleDate": null
},
{
"type": "W",
"value": 200000,
"settleDate": "01/08/2023"
}
],
"status": "A"
}
],
"status": "A"
}
]
}
}
GET estCashInAdvanceFee
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/estCashInAdvanceFee
Query estimate cash in advance fee
Details
Input Output
Field Type Required? Description
Sample:
Copy Input:
account:0001011
ciaAmount: 50000
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0001011",
"ciaAmount": 0,
"receiveAmount": 0,
"fee": 0
}
}
POST vsdCashDW
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/vsdCashDW
Tranfer cash with VSD (only support for derivatives account)
Details
Input Output
Field Type Required? Description Include:
W = withdraw
D = deposit
isSave = false -> Required PIN/ OTP
isSave = true -> no required
Sample:
Copy Input:
{
"account": "0901358",
"amount": 50000,
"type": "D",
"remark": "string",
"code": "string"
}
Output:
{
"message": "Success",
"status": 200,
"data": {
"transactionID": "579108"
}
}
Copy Input:
{
"account": "0901351",
"amount": 50000,
"type": "D",
"remark": "string",
"code":"string"
}
Output:
{
"message": "Not support cash transfer with vsd for stock account",
"status": 400,
"data": null
}
POST transferInternal
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/transferInternal
Transfer cash inside
Note:
The source account number and the receiving account number must have the same name and money can only be transferred between sub-accounts
Thông tin chi tiết
Input Output
Field Type Required? Description Include:
W = withdraw
D = deposit
isSave = false -> Required PIN/ OTP
isSave = true -> no required
Ví dụ
Copy Input:
{
"account": "0901351",
"beneficiaryAccount": "0901356",
"amount": 50000,
"remark": "string",
"code":"string"
}
Output:
{
"message": "Success",
"status": 200,
"data": {
"transactionID": "101844165"
}
}
Copy Input:
{
"account": "0901351",
"beneficiaryAccount": "0901356",
"amount": 50000,
"remark": "string",
"code":"string"
}
Output:
{
"message": "Account 0901352 is not exist",
"status": 400,
"data": null
}
POST createCashInAdvance
Copy https://fc-tradeapi.ssi.com.vn/api/v2/cash/createCashInAdvance
Create cash in advance transaction
Details
Input Output
Field Type Required? Description
Sample
Copy Input:
{
"account": "8888881",
"ciaAmount": 50000,
"code": 1234567
}
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "1158851",
"transactionID": "20230824-46286"
}
}
Copy Input:
{
"account": "8888881",
"ciaAmount": 50000,
"code":1234567
}
Output:
{
"message": "Not support derivatives account",
"status": 400,
"data": null
}
Online Right Subscription
GET dividend
Copy https://fc-tradeapi.ssi.com.vn/api/v2/ors/dividend
Get history dividend
Details
Input Output
Field Type Required? Description
Field Type Description Include:
- STOCK DIVIDEND
- CASH DIVIDEND
- BONUS ISSUE
- EXERCISE CW
- EXERCISE RIGHTS
Sample
Copy Input:
account: 0901351
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"dividends": [
{
"stockDividend": "STOCK DIVIDEND",
"instrumentID": "SSI",
"quantity": 49500,
"executedRate": "100:15",
"closeDate": "05/10/2020",
"paidDate": "07/10/2020",
"amount": 0,
"status": "A",
"receivedQuantity": 7425,
"issueInstrument": "SSI",
"distributedFlag": "N",
"payableDate": null,
"subscriptionPrice": 0,
"subscriptionAmount": 0,
"subscriptionQuantity": 0,
"subscriptionPeriodFrom": null,
"subscriptionPeriodTo": null,
"entitlementID": null
}
]
}
}
GET exercisableQuantity
Copy https://fc-tradeapi.ssi.com.vn/api/v2/ors/exercisableQuantity
Query stock quantity can register subscription
Details
Input Output
Field Type Required? Description
Field Type Description exerciseableReceiveQuantity
Sample:
Copy Input:
account: 0901351
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"exercisableQuantities": [
{
"entitlementID": "913279",
"instrumentID": "HCB",
"subscriptionPrice": 10000,
"executedRateFrom": 1,
"subscriptionPeriodFrom": "03/10/2022",
"subscriptionPeriodTo": "03/10/2023",
"exerciseableQuantity": 0,
"exerciseableReceiveQuantity": 0,
"exercisedReceiveQuantity": 0,
"executedRateTo": 1,
"exercisedQuantity": 0,
"payableDate": null
}
]
}
}
GET histories
Copy https://fc-tradeapi.ssi.com.vn/api/v2/ors/histories
Get histories
Details
Input Output
Field Type Required? Description Số tài khoản nguồn truy vấn
Ngày bắt đầu tìm kiếm
Định dạng: dd/mm/yyyy
Ngày kết thúc tìm kiếm
Định dạng: dd/mm/yyyy
Field Type Description onlineRightSubscriptionHistories
Note:
fromDate - toDate not more than 1 month
The time for searching the past should not exceed 1 year
Sample
Copy Input:
account: 1158851
startDate: 10/07/2023
endDate: 10/07/2023
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "1158851",
"onlineRightSubscriptionHistories": []
}
}
POST create
Copy https://fc-tradeapi.ssi.com.vn/api/v2/ors/create
Create online right subscription
Thông tin chi tiết
Input Output
Field Type Required? Description
Sample
Copy Input:
{
"account": "0901351",
"instrumentID": "SSI",
"entitlementID": "913312",
"quantity": 100,
"amount": 1000,
"code":"string"
}
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"transactionID": "17509268"
}
}
Copy Input:
{
"account": "0901351",
"instrumentID": "VND",
"entitlementID": "913312",
"quantity": 100,
"amount": 1000,
"code":"string"
}
Output:
{
"message": "Invalid ammount (max amount 1,459,882)",
"status": 40006,
"data": null
}
Stock
GET transferable
Copy https://fc-tradeapi.ssi.com.vn/api/v2/stock/transferable
Get stock transferable
Details
Input Output
Field Type Required? Description
Sample:
Copy Input:
account: 0901351
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"transferableStocks": [
{
"instrumentID": "ACB",
"quantity": 100,
"instrumentType": "EQ"
},
{
"instrumentID": "BTS",
"quantity": 300,
"instrumentType": "EQ"
}
]
}
}
GET transferHistories
Copy https://fc-tradeapi.ssi.com.vn/api/v2/stock/transferHistories
Get stock transfer history
Details
Input Output
Field Type Required? Description
Note:
fromDate - toDate not more than 1 month
The time for searching the past should not exceed 6 months
Sample:
Copy Input:
account: 0901351
startDate: 10/07/2023
enđate: 10/08/2023
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"stockTransferHistories": []
}
}
POST transfer
Copy https://fc-tradeapi.ssi.com.vn/api/v2/stock/transfer
Transfer stock inside
Detail
Input Output
Field Type Required? Description isSave = false -> required PIN/ OTP
isSave = true -> no required
Sample:
Copy Input:
{
"account": "0901351",
"beneficiaryAccount": "0901356",
"exchangeID": "HOSE",
"instrumentID": "SSI",
"quantity": 100,
"code": "string"
}
Output:
{
"message": "Success",
"status": 200,
"data": {
"account": "0901351",
"transactionID": "462764"
}
}
Copy Input:
{
"account": "0901351",
"beneficiaryAccount": "0901356",
"exchangeID": "HOSE",
"instrumentID": "SSI",
"quantity": 100,
"code": "string"
}
Output:
{
"message": "Account 0901352 is not exist",
"status": 400,
"data": null
}