Skip to content

Full personal order history extraction, portfolio analysis and PnL calculation from Trading 212's API.

License

Notifications You must be signed in to change notification settings

MaiqTheHonest/Trading212-PnL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust program to extract the full order history, backtrace and synthesize the portfolio history from it, and calculate unrealized PnL, APR, average daily return and Sharpe ratio using the buggy Trading212 API.

T212 allows 6x50 requests per minute => time delay for portfolio histories with more than 300 orders.


main => {t212, yahoo, plotter, dividends, stats}


t212

Thank you to loony-bean for textplots (you should add x_tick customisation).

Usage

Place a .txt file with your valid Trading212 API key (no spaces) into the same folder as t212.exe and launch executable (ideally via PowerShell or any other terminal that supports colour and UTF-8).



Alternatively, download the full rust_version, insert api key into the existing .txt file and cargo run.

About

Full personal order history extraction, portfolio analysis and PnL calculation from Trading 212's API.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published