Go to file
okxapi 48d29f19c6
Update trade_derivatives_en.ipynb
2023-03-09 17:10:58 +08:00
example Update trade_derivatives_en.ipynb 2023-03-09 17:10:58 +08:00
okx update version 2023-02-16 15:45:02 +08:00
test update README 2023-02-16 15:00:24 +08:00
.DS_Store test 2022-10-31 18:23:57 +08:00
.gitignore add setup.py 2023-02-16 15:47:56 +08:00
README.md modified readme 2023-02-16 14:45:35 +08:00
setup.py add setup.py 2023-02-16 15:47:56 +08:00

README.md

Overview

This is an unofficial Python wrapper for the OKX exchange v5 API

If you came here looking to purchase cryptocurrencies from the OKX exchange, please go here.

Source code

https://github.com/okxapi/python-okx

OKX API Telegram

https://t.me/OKXAPI

API trading tutorials

Make sure you update often and check the Changelog for new features and bug fixes.

Features

  • Implementation of all Rest API endpoints.
  • Private and Public Websocket implementation
  • Testnet support
  • Websocket handling with reconnection and multiplexed connections

Quick start

Prerequisites

python version>=3.9

WebSocketAPI websockets package advise version 6.0

Step 1: register an account on OKX and apply for an API key

Step 2: install python-okx

pip install python-okx

Step 3: Run examples

  • Fill in API credentials in the corresponding examples
api_key = ""
secret_key = ""
passphrase = ""

Note

  • To learn more about OKX API, visit official OKX API documentation

  • If you face any questions when using WebSocketAPI,you can consult the following links

    • asynciowebsockets document/github

      https://docs.python.org/3/library/asyncio-dev.html
      https://websockets.readthedocs.io/en/stable/intro.html
      https://github.com/aaugustin/websockets
      
    • About code=1006

      https://github.com/Rapptz/discord.py/issues/1996
      https://github.com/aaugustin/websockets/issues/587