FAQ (Frequently Asked Questions)
BtcTurk Global API Frequently Asked Questions
Answers to common questions about integrating with the BtcTurk Global API.
Why do I receive 401 - Unauthorized error
401 Unauthorized
A 401 response has no body. Check, in this order: the three headers (X-PCK, X-Stamp, X-Signature) are present; X-Stamp is within the accepted window (synchronise your clock with NTP); the signature follows Authentication V1 exactly; the request comes from the IP address registered for the key; and the key has the permission group the endpoint needs.
Why do I receive Invalid nonce error
X-Stamp is a regular integer number — the current Unix timestamp in milliseconds. By default there is a 5 second backward tolerance (extendable via X-Nonce, up to 60 seconds) and a fixed 5 second forward tolerance, but your server's current time must be synced with the API server time, which uses UTC.
Why do I receive 400 - BALANCE_NOT_ENOUGH error
The order was rejected because the free balance does not cover the order plus its commission. The response is 400 Bad Request with "message": "BALANCE_NOT_ENOUGH" and "code": 1055.
For TRY pairs, you need to calculate the commission and deduct from the total amount. For example, if you would like to order 1.00000000 BTC for 50,000TRY, your free balance must be at least 50,090TRY (Maker/Taker commissions are being calculated after your order executed. If your order matches immediately you'll be charged as Taker. Otherwise, you'll be charged as Maker and the commission difference will be added to your balance)
Why do I receive 429 - Too many requests
This means you exceeded the rate limit. Refer to Rate Limits section. Also please check the Retry-After response HTTP header. https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Retry-After It indicates how long the user agent should wait before making a follow-up request.
What is the difference between API versions and which one is suitable for me
There are two versions V1 and V2.
- V1 hosts most authentication-required endpoints (balances, orders, crypto deposit/withdrawal addresses, crypto withdrawals, transactions, volumes) as well as some public reference data (currencies, pairs), all with HMAC authentication where required.
- V2 hosts public market data: ticker, orderbook, trades, exchangeinfo, currency channels and crypto channels.
If you would like to request data related to your user account, you should use the relevant V1 endpoint with HMAC authentication. Public market data is served from V2 (with a couple of public endpoints on V1).
Does BtcTurk Global API have a WebSocket feed?
Yes. Connect to wss://ws.global.btcturk.com for realtime ticker, trade and order book data, and — after authenticating with your API key — for your own order, trade and balance events. See Connection & Message Format for the message protocol.
How are rate limits set?
All requests from the same client, public and private, count towards the same limits: 3 requests per 500 ms and 60 per 10 seconds. See Rate Limits.
What are commission rates?
BtcTurk Global API proxies order execution to BtcTurk's trading engine, so commission rates follow BtcTurk's published fee schedule. Check with your BtcTurk Global API operator for up-to-date rates.
What is the minimum transaction limit?
You can check the minimum transaction limits on our exchangeInfo endpoint. Minimum transaction limits can be displayed with the minExchangeValue parameter. See ExchangeInfo for more information.
What is the meaning of hasFraction field in ExchangeInfo endpoint?
Orders are not validated against hasFraction. A price can have at most denominatorScale decimal places; a price with more returns FAILED_INVALID_PRICE_SCALE (1126). See Pairs Scale (Quantity/Price).
Have more questions
If you have more questions, please reach out — see Contact Us.