Git Product home page Git Product logo

oilking's Introduction

oilking

GitHub license CircleCI

A trading bot using bitflyer api.

Disclaimer

Please take responsibility at your own risk if you use this program.

We do not take any responsibility even if you suffer a loss.

Get started

Set enviroment variables

Copy an .env.example as a .env and edit it. cp .env.example .env

Build

Build the source code. make docker-compose-build

Run

Run the binary file. make docker-compose-up or make docker-compose-up-d

Exchange marketplaces supported

Support Exchange markeplaces
Bitflyer

API supported

HTTP API

HTTP Public API

Support Method Endpoint
GET /v1/getmarkets
GET /v1/markets
GET /v1/getboard
GET /v1/board
GET /v1/getticker
GET /v1/getexecutions
GET /v1/getchats
GET /v1/gethealth
GET /v1/getboardstate

HTTP Private API

Support Method Endpoint
GET /v1/me/getpermissions
GET /v1/me/getbalance
GET /v1/me/getcollateral
GET /v1/me/getcollateralaccounts
POST /v1/me/sendchildorder
POST /v1/me/sendparentorder
POST /v1/me/cancelchildorder
POST /v1/me/cancelparentorder
POST /v1/me/cancelallchildorders
GET /v1/me/getchildorders
GET /v1/me/getparentorders
GET /v1/me/getparentorder
GET /v1/me/getexecutions
GET /v1/me/getbalancehistory
GET /v1/me/getpositions
GET /v1/me/getcollateralhistory
GET /v1/me/gettradingcommission
GET /v1/me/getaddresses
GET /v1/me/getcoinins
GET /v1/me/getcoinouts
GET /v1/me/getdeposits
GET /v1/me/getwithdrawals
GET /v1/me/getbankaccounts
POST /v1/me/withdraw

Realtime API(JSON-RPC 2.0 over WebSocket)

Public Channels

Support Channel name
lightning_board_snapshot_{product_code}
lightning_board_{product_code}
lightning_ticker_{product_code}
lightning_executions_{product_code}

Private Channels

Support Channel name
lightning_board_snapshot_{product_code}
parent_order_events

Reference

Contributing

We welcome your issue or pull request from everyone.

We'd appreciate if you could contribute our project.

Any request or question is OK.

日本語でも大丈夫です :D

License

This project is licensed under the terms of the MIT license.

Author

bmf - Software engineer.

oilking's People

Contributors

bmf-san avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

oilking's Issues

Dashboard UI

Description

Implement a dashboard UI for visualization of trading

稼働メモ

メモ

  • 急落・急騰すると注文が残る、損切が下手
  • 15分くらい?稼働していたら急にnil pointerで落ちた(原因不明)
  • APIコール間隔の検討(もっと短くできないか)
    呼び出し回数をどこかに保持して調整する必要がありそう。多分メモリに持つで良いと思う。
    →1分間なので時間を考慮する必要がある。ストレージに持つほうが良さそう。
    上限マックスまでコールできる設計・ロジックにするのがベスト。制限を喰らわないための保持。
HTTP API は、以下のとおり呼出回数を制限いたします。
Private API の呼出は 5 分間で 500 回を上限とします。上限に達すると呼出を一定時間ブロックします。また、ブロックの解除後も呼出の上限を一定時間引き下げます。同一 IP アドレスからの API の呼出は 5 分間で 500 回を上限とします。上限に達すると呼出を一定時間ブロックします。また、ブロックの解除後も呼出の上限を一定時間引き下げます。

0.1 以下の数量の注文は、すべての板の合計で 1 分間で 100 回を上限とします。上限に達するとその後 1 時間は 1 分間で 10 回まで注文を制限します。システムに負荷をかける目的で注文を繰り返していると当社が判断した場合は、API の使用を制限することがあります。ご了承ください。
  • 損切対応(stoplimitで対応できないか)
  • チャートの急騰・急落をウォッチするロジックが必要そう

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.