HKEx Gateway Documentation
- HKEx Gateway And The Exchange
- Installing And Upgrading
- Configuring Global Settings
- Configuring Market Data
- Configuring The Order Server
- Disaster Recovery
The TT Gateway installation package distributed by TT includes an Exchange-provided login test tool utility: APITSTLogin.exe. This utility installs in <root drive>:ttExchange-Flavor. You must run this executable from a command prompt.
Prior to running the login test tool utility, ensure that no one is logged in using the userID you wish to test with. If the test is completed with a user ID that is in use, you will successfully log into the Exchange, but the trader will be logged off.
To test API login:
- On the Start menu, point to Programs, and then click Command Prompt.
- Type: apitstlogin.exe UserName
Password Gateway Port
- UserName is the trader’s userID.
- Password is the trader’s password to connect to HKEx.
- Gateway is the IP address of the HKEx Gateway.
- Port is the port number of the HKEx Gateway.
Example API Login Test
apitstlogin.exe TTO31P23 4cdt3 22.214.171.124 5001
Failed Connectivity Test
If the connectivity test fails, you will receive the following message: Error (-2012) Reason : system error occured on ‘connect’
If you receive this message, check the command line for incorrect typing. Alternatively, the Exchange host may be down or off-line.
Contact the Exchange if you are unable to perform a successful connectivity test.
Successful Connectivity Test
If the connectivity test is a success, you will receive the following response:
Example Successful Connectivity Test Response
C:ttHKEx> apitstlogin.exe TTO31A23 4cdt3 126.96.36.199 5001
Logging in user.. Success
Getting user info.. Success
Country ID: SG
Getting facility id EP0.. Success
EP0 Facility 720
Logging out user..
Closing API session..
Once your connectivity test is successful, the UserName, Password, Gateway, and Port may be used in the Exchange-Flavorhostinfo.cfg as TTO, PriceServer, or TTF settings.