OKX demo account

OKX demo account setup

The TSLab development team recommends that you start learning the TSLab program on an OKX demo account. To transfer your OKX account to demo mode, go to the official page of the OKX exchange.

On the OKX website, select the menu item Assets - Demo Trading

To connect the TSLab terminal to the OKX demo server, you need to create an API key. From the My Profile menu, select Demo trading API.

On the API page, click the Create V5 API key for demo trading button.

On the page that opens, you need to fill in the fields:

  1. API Name - the name of the new API key

  2. Passphrase - API key password. Save your password, as if you lose it, you will need to create a new API key.

  3. Permissions - to trade through the TSLab platform, select the items: Read, Trade.

Click on the Confirm button to complete. Enter the two-factor authentication code.

After a new API key has been created, you can view the details of the key in the Account - API section. For detailed information, you need to click on the Information button and then enter Passphrase and the 2FA code.

Issuing a license key for the OLX data provider

Get a free license key for the TSLab program in your account on the company's website:

You can read more about obtaining a license key in the article: Issuing a free license for OKX Data Provider

Configuring the OKX Data Provider Demo

To start working in TSLab, you need to select a data provider. From the Main Menu select Data - Add Online Data Provider

Note. You can also download historical data into the program. You can read more about working with Historical data in the section Historical data section.

Select the OKX data provider from the list and give it a name under which it will be saved in your provider list. Press Next button.

Fill in the required fields in the Data Provider Settings window:

  • API Public - a public API key created in your OKX personal account;

  • API Secret - a secret API key created in your OKX personal account;

  • Pass Phrase - API key passphrase.

Note! If you want to connect to the Demo account of the OKX exchange, you need to check the boxes in the menu item Demo trading.

To trade on a demo server, you need to select points:

  • Demo trading - trading on the OKX Demo Server;

  • Real data for Paper - enable the use of quotes from the real market in Demo trading.

Additional settings (optional):

  • Use local time - use the time in accordance with your computer's regional settings

  • Subscribe to trades with quotes - Includes subscription to trades for instruments that have ever been requested from the View | Quotes

  • Logs for Debug - Enable maximum data provider logging. Turn it on only if you were asked by the TSLab support service.

  • Orders blocking timeout (sec.) - Blocks the submission of orders for a specified time interval after establishing a connection with the data provider.

  • Cache settings - The cache retention period settings allow you to specify how long your executed orders, trades and canceled orders will be stored.

  • Offline orders/Trades visibility - Enables the visibility of your trades in agents when the data provider is turned off.

To confirm the entered data, click the OK button.

In the Data Providers window (Main menu - Data - Data Providers), select the created data provider and click the Key button. Enter the key created in your personal account on the TSLab website (TSLab Personal Account - Contracts), click the OK button.

Note! If you entered the key, but the input field is surrounded by a red frame, then an input error was made. Common causes of errors:

  • The key is copied manually and a space character is added at the beginning of the line, or at the end of the line

  • When creating a data provider in your personal account, a secret key was entered instead of a public API key, or extra characters were entered (for example, a space character)

  • If you have registered several data providers for the same exchange, check that you have copied the key for the corresponding provider from the Contracts section in your account

After the key has been entered, the button to launch the data provider in the Operation column will become available to you. Click the button to establish a connection.

The program will inform you about the connection status in the Data Providers window:

  • red color of the button means an error in establishing connection,

  • yellow color means that the connection is in progress,

  • green color means that connections have been established and you can carry out trading operations.

Last updated