Built-in Functions
Structures
Built-in Variables and Constants
Conventions
Exchanges
bitFlyer
Spot trading on the Japanese exchange bitFlyer (api.bitflyer.jp). Only spot pairs are served (products whose market_type is Spot), not bitFlyer's FX and futures products; the exchange has no K-line or batch ticker endpoint. Conditional orders use bitFlyer parent orders. Access uses an API Key and Secret Key.
Names and Configuration
exchange.GetName(): BitFlyer (Spot).
| Field | Required |
|---|---|
| Access Key | Yes |
| Secret Key | Yes |
Trading Pairs and Contract Codes
Pair examples: BTC_JPY, ETH_JPY
Trading pairs are written BASE_QUOTE, the same form as the bitFlyer native product_code.
Function Support
Not supported (the call fails with an error and returns null): exchange.GetTickers, exchange.ModifyOrder, exchange.ModifyConditionOrder.
Served through a fallback:
exchange.GetRecords: The exchange has no K-line endpoint; bars are synthesized by the docker from trades. The first call covers only the few bars spanned by recent trades, and more accumulate with later calls.
Notes
- The amount of a spot market buy order is in the base currency, not a quote-currency amount (orders are placed by bitFlyer
size). - Maker-only (
postOnly) orders are not supported; the exchange has no client order ID field, so a custom order ID (clientId) is not supported for regular or conditional orders and fails without sending the order. - The open-order and open-conditional-order endpoints require a trading pair: without the
symbolargument,exchange.GetOrders()andexchange.GetConditionOrders()query the current trading pair only. Withoutlimitboth page through and return all open orders. exchange.GetHistoryOrders()andexchange.GetHistoryConditionOrders()do not support thesinceargument (the exchange only pages by order id) and fail when it is given; without it they return the most recent orders, at most 100 by default.- Conditional orders use bitFlyer parent orders (SIMPLE) and support take-profit and stop-loss (without an order price they execute at market once triggered), not OCO.
exchange.GetMarkets()gives no price/amount precision or order-size limits (the exchange API does not provide them); those fields are 0.- The exchange's ticker endpoint has no 24-hour high, low or open price:
HighandLowinexchange.GetTicker()are filled with the best ask and best bid, andOpenis 0. - The order ID returned on placement is the acceptance ID (starting with
JRF), whileexchange.GetOrders()andexchange.GetHistoryOrders()give the exchange's internal order ID; both IDs can be used to query and cancel, and the same applies to conditional (parent) orders.