Skip to content

brian09088/Yuanta-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Yuanta-API 元大期貨交易API串接與自動化交易

!!! 注意檔案目錄安裝路徑要正確,否則容易出現報錯

程式檔案存放位置(C:/Yuanta/QAPI)

vs-code 終端機預設目錄(C:/Users/User)下方存放wxPython.whl檔案

anaconda 要看自己安裝的位置,去設定python-32bits環境

======

環境設定:

set CONDA_FORCE_32BIT=1 #名稱自定
set #開始建置
conda create -n ENV_32BIT #建立環境
activate ENV_32BIT #啟動新環境,繼續在環境中安裝
conda install python=3.9 #於新環境中設置python3.9,由於api中套件wx,comtypes支援3.9以下版本
conda install -c free comtypes
  • from anaconda launch jupyter or spyder or vs-code, running Yuantaapi.py
  • after install wxpython 32-bits, move whl file to vs-code terminal directory (C:\Users\User)
  • open Yuantaapi.py through anaconda in vs-code and type in vs-code terminal
pip install wxPython-4.1.1-cp39-cp39-win32.whl
  • 執行後跳出登入視窗如下圖所示 image
  • 輸入元大期貨帳戶與交易密碼
  • 右欄註冊區輸入產品代碼元大期貨下單商品代碼規則
  • 成功連線與註冊
  • image
  • 商品註冊成功
  • image

About

元大期貨交易API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages