A discord bot that manages your server's hedge fund

Overview

Can't Hide Money Bot

test-status

A discord bot that manages your server's hedge fund

wu_tang_financial

Installing

Install wkhtmltopdf

sudo apt-get install wkhtmltopdf
OR
brew install wkhtmltopdf
pip install -U git+https://github.com/kelvinabrokwa/cant-hide-money-bot.git

Create an env file like:

DISCORD_TOKEN='XXX'
DEV_GUILD_ID='XXX'

Running

# Server
python -m cant_hide_money_bot.server --mode dev

# One-off report
python -m cant_hide_money_bot.report --mode dev

Testing

make test
make lint

About the app

Currently, we store the portfolio as a big list of trades like:

class Trade:
    symbol: Symbol
    dir_: Dir
    qty: Qty
    time: datetime
    price: float
    trader: Trader
    guild: str

An empty portfolio has 0 USD and no positions. When you do a BUY trade, you get shorter USD and longer the security. When you do a SELL trade, you get longer USD and shorter the security. Note that we capture market prices at execution time in Trade to be able to calculate the value of the portfolio later.

The Bot

On Discord

!help
~if you ain't talkin money i ain't talkin~

โ€‹No Category:
  $                Print portfolios per trader
  $$               Print portfolio for entire fund
  BUY              Buy some shares
  IM-FEELING-LUCKY Buy or sell a random quantity of a random symbol
  SELL             Sell some shares
  T                Print all trades made in this fund
  help             Shows this message

Type !help command for more info on a command.
You can also type !help category for more info on a category.

Useful queries

select symbol, sum(qty * (case when dir == 'BUY' then 1 else -1 end)) from trades where trader = '<trader>' group by symbol;
Owner
Kelvin Abrokwa-Johnson
Kelvin Abrokwa-Johnson
This bot can stream audio or video files and urls in telegram voice chats :)

Voice Chat Streamer This bot can stream audio or video files and urls in telegram voice chats :) ๐ŸŽฏ Follow me and star this repo for more telegram bot

Anjana Madu 63 Dec 25, 2022
Stack Overflow Error Parser

A python tool that executes python files and opens respective Stack Overflow threads in browser for errors encountered.

Raghavendra Khare 3 Jul 24, 2022
SOCMINT tool to get personal infos from an Instagram account via analysis of its followers and/or following

S T E R R A ๐Ÿ”ญ A SOCMINT tool to get infos from an Instagram acc via its Followers / Following Allows you to analyse someone's followers, following, a

aet 316 Dec 28, 2022
A fun hangman style game to guess random movie names with a short summary about the movie.

hang-movie-man Hangman but for movies ๐Ÿ˜‰ This is a fun hangman style game to guess random movie names from the local database and show some summary ab

Ankit Josh 10 Sep 07, 2022
NMux is the version of the NMscript in termux

NMscript-termux-version Termux-Version NMux is the termux version of NMscript which is NMscript? NMscript is a simple script written in Python that he

cabeson sin z 5 Apr 23, 2022
Bot developed in python, 100% open-source, compatible with Windows and Linux.

Bombcrypto Bot [Family JOW] Bot desenvolvido em python, 100% do cรณdigo รฉ aberto, para aqueles que tenham conhecimento validarem que nรฃo existe nenhum

Renato Maia 71 Dec 20, 2022
Telegram bot to clip youtube videos

youtube-clipper-bot Telegram bot to clip youtube videos How to deploy? Create a file called config.env BOT_TOKEN: Provide your bot token generated by

Shivam Jha 11 Dec 10, 2022
Total servers you're in!

Discord-Servercount With this script you can check the amount of servers you are in, along with statistics of how many servers you are owner in and in

Nickyux 1 Feb 12, 2022
Telephus is a connection pooled, low-level client API for Cassandra in Twisted python.

Telephus Son of Heracles who loved Cassandra. He went a little crazy, at one point. One might almost say he was twisted. Description Telephus is a con

Brandon Williams 93 Apr 29, 2021
Super Fast Telegram UserBot Made With Python.

Description Super Fast Telegram UserBot Made With Python. ๏ผฌ๏ผฏ๏ผง๏ผฏ Made With Support of All Userbots Dev's Dark-Venom is a Light-Weight Userbot. It's unde

2 Sep 14, 2021
This is a small Messnger with the cmd as an interface

Messenger This is a small messenger with the cmd as an interface. It started as a project to learn more about Python 3. If you want to run a version o

1 Feb 24, 2022
This Bot Can Upload Video from Link Of Pdisk to Pdisk using its API. @PredatorHackerzZ

๐๐๐ข๐ฌ๐ค ๐‚๐จ๐ง๐ฏ๐ž๐ซ๐ญ๐ž๐ซ ๐๐จ๐ญ Make short link by using ๐๐๐ข๐ฌ๐ค API key Installation ๐“๐ก๐ž ๐„๐š๐ฌ๐ฒ ๐–๐š๐ฒ ๐‘๐ž๐ช๐ฎ๐ข๐ซ๐ž๐ ๐•๐š๐ซ๐ข๐š๐›๐ฅ๐ž

ฯัั”โˆ‚ฮฑั‚ฯƒั 25 Dec 02, 2022
Wonderful Phoenix-Bot

Phoenix Bot Discord Phoenix Bot is inspired by Natewong1313's Bird Bot project yet due to lack of activity by their team. We have decided to revive th

Senior Developer 0 Aug 12, 2021
A VCVideoPlayer Bot for Telegram made with ๐Ÿ’ž By @TeamDeeCoDe

VC Video Player How To Host โœจ Heroku Deploy โœจ The easiest way to deploy this Bot is via Heroku. Credit ๐Ÿ”ฅ |๐Ÿ‡ฎ๐Ÿ‡ณ Louis |๐Ÿ‡ฎ๐Ÿ‡ณ Sammy |๐Ÿ‡ฎ๐Ÿ‡ณ Blaze |๐Ÿ‡ฎ๐Ÿ‡ณ S

TeamDeeCode 6 Feb 28, 2022
News API consisting various sources from Tanzania

Tanzania News API News API consisting various sources from Tanzania. Fork the project Clone the project git clone https://github.com/username/news-a

Innocent Zenda 6 Oct 06, 2022
Trellox Tool is written in Python3 and designed to pull and list Trello boards.

TrelloX Trellox Tool is written in Python3 and designed to list and pull Trello boards. It can be used by penetration testers/bug bounty hunters to de

Ali Fathi Ali Sawehli 1 Dec 05, 2021
A Discord/Xenforo bot!

telathbot A Discord/Xenforo bot! Pre-requisites pyenv (via installer) poetry Docker (with Go version of docker compose enabled) Local development Crea

Telath 4 Mar 09, 2022
A github actions + python code to extract URLs to code repositories to put into standard form, starting with github

A github actions + python code to extract URLs to code repositories to put into standard form, starting with github ---- NOTE: JUS

Justin Gosses 2 Nov 15, 2021
A simple test repo created following docker docs.

docker_sampleRepo A simple test repo created following docker docs. Link to docs: https://docs.docker.com/language/python/develop/ Other links: https:

Suraj Verma 2 Sep 16, 2022