Products

Charts

Resources

Products

Charts

Resources

Back to Blog

by Finage at January 18, 2021 1 MIN READ

Technical Guides

Connect to the Financial Data via WSCAT on Your Terminal

Financial data is more accessible and easy to understand via Finage. In this post, we will talk about how we can use or test the WebSockets on the terminal.

Let's start with installing the WSCAT. You need to NodeJS on your computer to install the WSCAT. You can install NodeJS with the given link below.

https://nodejs.org/en/

After the installation, it's easy to install the WSCAT. Run the command given below and it will install the WSCAT globally. 

npm install -g wscat

That's all, now we have WSCAT on our computer. You can check it with wscat -V command on your terminal. Finage will provide you a VPS for accessing the data with the highest performance possible. You'll get the details via E-Mail and Finage will give you a unique address like 

wss://abc123456.finage.ws:6000/?token=YOUR_SOCKET_KEY

You can connect to your virtual private server with this address. If you want to test your VPS or if you want to get the latest price with minimum effort on your computer via your unique address, open your terminal and run the command given below;

 

wscat -n -c "wss://abc123456.finage.ws:6000/?token=YOUR_SOCKET_KEY"  

You can get more details about the parameters by running the wscat -h command. 

WSCat terminal

After the connection, you will get a message from the server. We are using the Cryptocurrency server in this tutorial so, the server responded as "Connected to the Cryptocurrency Market". It's ready to get the data in Real-Time.

Send the command given below to the server;

{ "action": "subscribe", "symbols": "BTCUSD" }

WSCat response

The data will flow really fast after the command. You can stop it by pressing the CTRL + C keys. In this response, we are getting symbol name, price, quantity, and timestamp. Finage offers you a customizable server. It means you can edit the responses. For example, you can add "ask" and "bid" prices to the response, and more, of course.

 

Contact with the Finage team to get your Real-Time data in minutes. 

You can contact to Finage consultants to get more informaions about Finage

Back to Blog

Request a consultation

Blog

Impact of AI on Forex Trading: Analyzing Advancements & Integration

Forex along with the entire financial market has seen many changes over the years and a lot of emphasis has been placed on the desire for automation. As you probably figure it out, this is something that Artificial Intelligence (AI) can help out with. When you consider just how prominent technolo

Why Crypto & Blockchain Are So Important in 2024?

In the last three years, there has been a small reduction in the buzz around crypto. This was mostly due to several factors including the pandemic, major scandals, and regulation issues in the crypto business, such as exchange hacks, fraudulent initial coin offerings (ICOs) and governmental restri

Read more

Please note that all data provided under Finage and on this website, including the prices displayed on the ticker and charts pages, are not necessarily real-time or accurate. They are strictly intended for informational purposes and should not be relied upon for investing or trading decisions. Redistribution of the information displayed on or provided by Finage is strictly prohibited. Please be aware that the data types offered are not sourced directly or indirectly from any exchanges, but rather from over-the-counter, peer-to-peer, and market makers. Therefore, the prices may not be accurate and could differ from the actual market prices. We want to emphasize that we are not liable for any trading or investing losses that you may incur. By using the data, charts, or any related information, you accept all responsibility for any risks involved. Finage will not accept any liability for losses or damages arising from the use of our data or related services. By accessing our website or using our services, all users/visitors are deemed to have accepted these conditions.

Finage LTD 2024

Copyright