# Bitflyer: Bitflyer Api Library
bitflyer は [bitflyer](https://bitfyer.jp) の python 製 api ライブラリです.
` > from bitflyer import public > p1 = public.Public() > p1.ticker() {'volume_by_product': 2965.84952775, 'best_ask': 44689.0, 'timestamp': '2016-02-04T05:30:31.763', 'product_code': 'BTC_JPY', 'tick_id': 137706, 'best_ask_size': 0.016, 'volume': 5333.87259331, 'total_bid_depth': 679.52073, 'best_bid_size': 2.4, 'ltp': 44700.0, 'total_ask_depth': 1144.14296596, 'best_bid': 44670.0} `
## Documentation
Documentation for Bitflyer API is available at https://lightning.bitflyer.jp/docs?lang=ja
### Public
#### 板情報
[板情報](https://lightning.bitflyer.jp/docs?lang=ja#板情報) を取得します.
` >> from bitflyer import public >> print(public.Public().getboard()) {'asks':... `
詳細は[こちら](https://lightning.bitflyer.jp/docs?lang=ja#板情報).
#### Ticker
` >> from bitflyer import public >> print(public.Public().getticker()) {'timestamp': '2016-02-04T05:47:26.64', 'best_bid': 44711.0, 'product_code': 'BTC_JPY', 'total_bid_depth': 785.91873, 'best_ask': 44725.0, 'ltp': 44750.0, 'best_bid_size': 1.667, 'total_ask_depth': 735.61096596, 'volume': 5344.37969331, 'volume_by_product': 2975.34662775, 'tick_id': 139547, 'best_ask_size': 0.013} `
[ticker](https://lightning.bitflyer.jp/docs?lang=ja#ticker) を取得します.
詳細は[こちら](https://lightning.bitflyer.jp/docs?lang=ja#ticker).
#### 約定履歴
約定履歴を取得します.
` >> from bitflyer import public >> print(public.Public().getexecutions()) [{'size': 1.618, 'buy_child_order_acceptance_id':... `
詳細は[こちら](https://lightning.bitflyer.jp/docs?lang=ja#約定履歴).
#### 取引所の状態
[取引所の状態](https://lightning.bitflyer.jp/docs?lang=ja#取引所の状態) を取得します.
` >> from bitflyer import public >> print(public.Public().gethealth()) {'status': 'NORMAL'} ` 詳細は[こちら](https://lightning.bitflyer.jp/docs?lang=ja#取引所の状態).
### Private
#### 資産残高を取得
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.getbalance() {'status_code': 200, 'response': ....} `
#### 証拠金の状態を取得
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.getcollateral() {'status_code': 200, 'response': ....} `
#### 新規注文を出す
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.sendchildorder() {'status_code': 200, 'response': ....} `
#### 注文をキャンセルする
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.cancelchildorder() {'status_code': 200, 'response': ....} `
#### 新規の親注文を出す(特殊注文)
未実装
#### 親注文をキャンセルする
未実装
#### すべての注文をキャンセルする
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.cancelallchildorders() {'status_code': 200, 'response': ....} `
#### 注文の一覧を取得
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.getchildorders() {'status_code': 200, 'response': ....} `
#### 親注文の一覧を取得
未テスト
#### 親注文の詳細を取得
未テスト
#### 約定の一覧を取得
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.getexecutions() {'status_code': 200, 'response': ....} `
#### 建玉の一覧を取得
` >> from bitflyer import private >> p = private.Private(access_key='YOUR_ACCESS_KEY',secret_key='YOUR_SECRET_KEY') >> p.getpositions() {'status_code': 200, 'response': ....} `
## TODO
親注文
## 0.0.2 (2019-07-09)
Security Update - CVE-2018-18074
## 0.0.1 (2016-02-04)
Birth!
Metadata
Release files for bitflyer 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| bitflyer-0.0.2.tar.gz | 5.5 kB | Without provenance | Details for bitflyer-0.0.2.tar.gz |
Release files / bitflyer-0.0.2.tar.gz
| Download URL | bitflyer-0.0.2.tar.gz |
|---|---|
| Size | 5.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b7bedc3dff7b175fb1367d092cd5e8c3f1625d71d559e5141c0418c5466c880c
|
|
BLAKE2b-256 checksum How to use checksums |
bf7c45f053c29909dd5870d0015e003928446f0241e884a49ec4859cb1cf1094
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.6.4
|
Security for bitflyer 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.