January 12, 2024
Does WhiteBIT have an API?
Yes, WhiteBIT does have an API that provides access to various information such as market info, order depth, trade history, and more. You can find the details in the Official Documentation of WhiteBIT API. However, an alternative to using WhiteBIT's public API is to use Mesh, which has built integration with 300+ other digital asset exchanges and wallets. Check out Mesh Integrations for more information.
About WhiteBIT
WhiteBIT, founded by Vladimir Nosov in 2018, is a cryptocurrency exchange platform based in Vilnius, Lithuania. The platform offers various trading options, including spot, margin, and futures trading, as well as products like WhiteBIT Earn, WBT, and a mobile application. With a focus on providing a wide range of services and products, WhiteBIT aims to cater to the needs of individual crypto traders and larger enterprises alike.
General usage
Key aspects of WhiteBIT's API include:
- Public Endpoints API: Allows access to general market data, order book information, and trading pairs, suitable for users seeking market insights and analysis.
- Private Endpoints API: Requires authentication for personalized functions such as trading, managing orders, and accessing account details, tailored for active traders on WhiteBIT.
- WebSocket API: Offers real-time data streaming, crucial for high-frequency trading and applications needing instant market updates.
- Webhooks API: Enables event-driven actions, facilitating automated responses to specific triggers in the trading environment.
Rate Limits
WhiteBIT API’s rate limits are:
- Market Info, Market Activity, Asset Status List, and Other Similar Endpoints
- Rate Limit: 2000 requests per 10 seconds.
- Orderbook Endpoint
- Rate Limit: 600 requests per 10 seconds.
Authentication
This is how you authenticate your requests to the WhiteBIT API:
- Go to your account on whitebit.com/settings/api and select the appropriate configuration tab for your API keys.
- Generate an API key and enable IP restrictions by specifying up to 5 trusted IPs (optional, recommended).
- Enable Endpoint access restrictions by selecting only those endpoints that you are going to use and click the "Apply" button.
- Include the required headers in your requests: 'Content-type': 'application/json', 'X-TXC-APIKEY': api_key, 'X-TXC-PAYLOAD': payload, and 'X-TXC-SIGNATURE': signature.
- Calculate the timestamp for the 'nonce' field of the body data using the unix timestamp in milliseconds.
- Create the signature using the formula hex(HMAC_SHA512(payload), key=api_secret)).
Errors
Here is the most common API errors for WhiteBIT:
- This action is unauthorized: This error indicates that your request may be invalid. Ensure that you have the correct permissions and that you are sending the correct parameters. If the issue persists, double-check your authentication process.
- Invalid token: This error suggests that the token being used is not valid. Make sure you are using a valid token and that it has not expired. If necessary, request a new token following the guidelines in the OAuth 2.0 API documentation.
An alternative to the WhiteBIT API
While WhiteBIT's API offers various trading and market data, using Mesh's integrations can provide a more streamlined and efficient experience for developers and businesses. Mesh's value add lies in its ease of use, extensive connectivity, and cost benefits. In this section, we'll discuss why using Mesh's integrations is a better option than accessing WhiteBIT's API directly.
Here are some of the standout features of Mesh's API:
- Integrated User Experience: Mesh seamlessly embeds cryptocurrency functionalities into your app, offering a smooth user journey. With features like embedded crypto deposits and comprehensive account aggregation, users can manage their digital assets with ease.
- Broad Connectivity: With a single integration, Mesh connects to over 300 brokerages, exchanges, and wallets, providing extensive flexibility and choice. This allows Mesh's customers to access a wide range of platforms without having to manage multiple APIs.
- Simplified Asset Management: Mesh API eases the process of depositing assets, allowing transfers from various sources directly within the app for enhanced user convenience. It supports 20+ tokens and 10+ networks, providing full visibility into each network's fees.
By choosing Mesh, developers and businesses can benefit from a more streamlined and efficient experience when integrating with WhiteBIT and other digital asset platforms. Start with Mesh today and experience the ease and efficiency of their cutting-edge API in your digital asset endeavors.