You must run this to migrate from versions < 1.1.0
. After this point, the bot will only
use repository.db
, feel free to delete repository.json
.
quartermaster repository migrate
The bot uses contract title to be able to tell what is in the contract. Make sure your corporation fittings and contract names are identical. It will help alot with managing things.
To add 5000 Herons to be on Corporation Contract at all times:
!require 5000 Corp Heron
To trigger quick report of missing doctrines, use !report
or !qm
.
The bot will call EVE ESI every --check_interval
and will send quick report
to a channel specified by --discord_channel_id
.
Full report contains all doctrine ships that were added using !require
, regardless of the stock.
You can use this to easily see what is required, how many do you have in stock,
how many contract of each were accepted per month and problematic contracts if any.
To add many doctrines at once, you can copy+paste from excel or google sheet.
!parse excel
Heron 5000 Corporation
Tackle Stiletto 3 Corporation
Be aware this will overwrite everything you added by hand using !require
!
The bot can track how much a doctrine is bought for. When hauler brings a doctrine,
they can simply create contract with title starting with *
:
* Tackle Stiletto
The bot will look for these contracts and updates the doctrine buy price. It will also create price history
record for this doctrine for later analysis (you can run quartermaster repository read price_history
).
These tracked prices are then visible when running !report full
command.
Quartermaster bot will also alert
when contract
You can see what you have in stock !stock
- or at least how the bot parses those contracts.
And to list what is required: !require list
.
- Download binary for your architecture in
releases
section.
- Go to EVE developer portal and create a EVE app for the bot
- Grab the
Client ID
andSecret Key
- Set
Callback URL
tohttp://localhost:3000/callback
- Add these scopes to the APP:
publicData, esi-contracts.read_corporation_contracts.v1
- Grab the
- Go to Discord Developer Portal and create new APP.
- Add
Bot
to this APP. - Make the
bot
public
so it can be added to your corp discord. - Grab the
Token
- Add
- Create RANDOM string for SESSION storage (you can use openssl, or just make something by hand)
-
Run this command and fill in the missing variables with what you got in
Part 1
:quartermaster login -s "RANDOM_STRING" --eve_client_id="FILLME" --eve_sso_secret="FILLME"
This will open web browser, and will authorize you with EVE account. When it is successfull, you can close the browser tab, and it will save the authentization information in
auth.bin
file.Docker version:
$ docker volume create eve-quartermaster $ docker run -v eve-quartermaster:/auth/ -p 3000:3000 lunemec/eve-quartermaster:latest login --auth_file=/auth/auth.bin -s "$RANDOM_STRING" --eve_client_id="$CLIENT_ID" --eve_sso_secret="$SSO_SECRET"
-
Copy the discord ChannelID where you want your bot (you have to enable DEV mode)
-
Test-run the bot on some test server so you don't spam everyone:
quartermaster run -s "RANDOM_STRING" --discord_auth_token="FILLME" --discord_channel_id="FILLME" --eve_client_id="FILLME" --eve_sso_secret="FILLME" --corporation_id="FILLME" --alliance_id="FILLME"
Docker version:
$ docker run -v eve-quartermaster:/auth/ lunemec/eve-quartermaster:latest run -s "$RANDOM_STRING" -a "/auth/auth.bin" --eve_client_id="$CLIENT_ID" --eve_sso_secret="$SSO_SECRET" --discord_auth_token="$DISCORD_TOKEN" --discord_channel_id="$DISCORD_CHANNEL_ID"
You can modify these parameters to make the bot trigger a message:
Usage: eve-quartermaster run [flags] Flags: --alliance_id int32 Alliance ID for which to list contracts -a, --auth_file string path to file where to save authentication data (default "auth.bin") --check_interval duration how often to check EVE ESI API (default 30min) (default 30m0s) --corporation_id int32 Corporation ID for which to list contracts --discord_auth_token string Auth token for discord --discord_channel_id string ID of discord channel --eve_client_id string EVE APP client id --eve_sso_secret string EVE APP SSO secret -h, --help help for run --notify_interval duration how often to spam Discord (default 24H) (default 24h0m0s) --repository_file string path to repository json to save require_stock data (default repository.json) (default "repository.json") -s, --session_key string session key, use random string
-
Go to Discord Developer Portal and create new APP.
- Get the invite link for your bot:
OAuth2
section- Click on
Scopes
:bot
Text Permissions
:Send Messages
- Open the
URL
that was generated inScopes
block, and invite your bot to some server.
- Click on
- Get the invite link for your bot:
-
If you managed to trigger a message, you're good to continue to the next part.
I prepared systemd
(under /debian/) unit, but you have to copy it and the binary by hand. If someone wants to create
a .deb
file or some other package, feel free to do so.
If you are successfull, you should see the Bot's icon in the discord users list in the channel.
If you like this bot and use it, consider donating some ISK to Lukas Nemec
. Thanks.