harambot


Nameharambot JSON
Version 0.3.3 PyPI version JSON
download
home_pagehttp://harambot.io
SummaryA Yahoo Fantasy Sports bot for Discord
upload_time2023-10-12 03:10:20
maintainer
docs_urlNone
authorDMcP89
requires_python>=3.8,<4.0
licenseMIT
keywords yahoo yahoo fantasy sports fantasy football fantasy basketball fantasy baseball fantasy hockey discord bot
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Harambot
_An interactive Yahoo Fantasy sports bot for Discord._

![Python](https://img.shields.io/badge/python-3.8%20%7C%203.9%20%7C%203.10-blue) ![License](https://img.shields.io/badge/License-MIT-green) ![Build](https://img.shields.io/github/actions/workflow/status/DMcP89/harambot/pytest.yml?branch=main) ![Version](https://img.shields.io/badge/version-0.3.3--Beta-red)

![harambot-logo](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot-1.jpg)



[![Discord](https://img.shields.io/badge/Add_Harambot_To_Your_Server-%235865F2.svg?style=for-the-badge&logo=discord&logoColor=white)](http://harambot.io)





## Commands
    /ping                           - Gives the latency of harambot
    /RIP                            - Pay respects
    /standings                      - Returns the current standings of the current league
    /roster "Team name"             - Returns the roster of the given team
    /stats "Player Name"            - Returns the details of the given player
    /trade                          - Create poll for latest trade for league approval
    /matchups                       - Returns the current weeks matchups
    /waiver                         - Returns the waiver wire tranasactions from the previous 24 hours
    /configure                      - Configure the bot for your guild

You can find example output of these commands [here](https://github.com/DMcP89/harambot/wiki#command-examples)


## Roll your own instance

### Prerequisites

In order to properly configure your bot you will need the following:

* [Discord API Token](https://github.com/DMcP89/harambot/wiki/Prerequisites#discord-api-token)
* [Yahoo API Client Id & Secret](https://github.com/DMcP89/harambot/wiki/Prerequisites#yahoo-api-client-id--secret)
* [Yahoo League ID](https://github.com/DMcP89/harambot/wiki/Prerequisites#yahoo-league-id)

_Visit our [wiki](https://github.com/DMcP89/harambot/wiki) for a step by step guide on how to obtain these values._

### Run the bot in the cloud

[![Deploy to Render](https://render.com/images/deploy-to-render-button.svg)](https://render.com/deploy?repo=https://github.com/DMcP89/harambot)

[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)


### Run the bot locally using pip package

1. Install the harambot package using pip

        pip install harambot

2. Export the following environment variables

   ```
   export DISCORD_TOKEN='[YOUR DISCORD TOKEN]'
   export YAHOO_KEY='[YOUR YAHOO API CLIENT ID]'
   export YAHOO_SECRET='[YOUR YAHOO API CLIENT SECRET]'
   export DATABASE_URL='[YOUR DATABASE URL]'
   ```

3. Run the bot

        harambot

### Run the bot locally using docker

1. Pull the latest image from docker hub

        docker pull dmcp89/harambot

2. Export the following environment variables

   ```
   export DISCORD_TOKEN='[YOUR DISCORD TOKEN]'
   export YAHOO_KEY='[YOUR YAHOO API CLIENT ID]'
   export YAHOO_SECRET='[YOUR YAHOO API CLIENT SECRET]'
   export DATABASE_URL='[YOUR DATABASE URL]'
   ```

3. Run the bot

        docker run --name harambot \
        -e DISCORD_TOKEN=$DISCORD_TOKEN \
        -e YAHOO_KEY=$YAHOO_KEY \
        -e YAHOO_SECRET=$YAHOO_SECRET \
        -e DATABASE_URL=$DATABASE_URL \
        --rm dmcp89/harambot


## Setup

### Add the bot to your guild
1. Generate a OAuth url from the discord developer portal using the bot scope and the following permissions:

* Send Messages
* Send Messages in Threads
* Embed Links
* Attach Files
* Read Message History
* Add Reactions
* Use Slash Commands

The permission value should be 277025507392

![discord-oauth](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-generator.png)

2. Set the gateway intents

In order for the bot to work properly it requires the following intents:

* Sever Members Intent
* Message Content Intent

![discord-intents](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-intents.png)

3. Navigate to the generated url in a web browser and authorize the bot for your guild

![discord-oauth-url-1](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-url-authorize-1.png)
![discord-oauth-url-2](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-url-authorize-2.png)

### Configure your guild

* Once your bot is added to your guild you can configure it by using the /configure command:


![discord-config-commnd](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_1.png)

* Use the Login with Yahoo button to authenticate with Yahoo and get your Yahoo token


![discord-config-yahoo](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_4.png)

* Use the Configure Guild button to configure your guild for the bot


![discord-config-guild](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_2.png)


* You can reconfigure your guild by running the configure command and clicking the Configure Guild button.


![discord-config-guild](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_3.png)

            

Raw data

            {
    "_id": null,
    "home_page": "http://harambot.io",
    "name": "harambot",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<4.0",
    "maintainer_email": "",
    "keywords": "yahoo,yahoo fantasy sports,fantasy football,fantasy basketball,fantasy baseball,fantasy hockey,discord,bot",
    "author": "DMcP89",
    "author_email": "davemcpherson@wochstudios.com",
    "download_url": "https://files.pythonhosted.org/packages/18/7b/c6fa41c6d887f2ed13bffa370b1b9ad36e99e7c178d9fafc7d6d311bd7c4/harambot-0.3.3.tar.gz",
    "platform": null,
    "description": "# Harambot\n_An interactive Yahoo Fantasy sports bot for Discord._\n\n![Python](https://img.shields.io/badge/python-3.8%20%7C%203.9%20%7C%203.10-blue) ![License](https://img.shields.io/badge/License-MIT-green) ![Build](https://img.shields.io/github/actions/workflow/status/DMcP89/harambot/pytest.yml?branch=main) ![Version](https://img.shields.io/badge/version-0.3.3--Beta-red)\n\n![harambot-logo](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot-1.jpg)\n\n\n\n[![Discord](https://img.shields.io/badge/Add_Harambot_To_Your_Server-%235865F2.svg?style=for-the-badge&logo=discord&logoColor=white)](http://harambot.io)\n\n\n\n\n\n## Commands\n    /ping                           - Gives the latency of harambot\n    /RIP                            - Pay respects\n    /standings                      - Returns the current standings of the current league\n    /roster \"Team name\"             - Returns the roster of the given team\n    /stats \"Player Name\"            - Returns the details of the given player\n    /trade                          - Create poll for latest trade for league approval\n    /matchups                       - Returns the current weeks matchups\n    /waiver                         - Returns the waiver wire tranasactions from the previous 24 hours\n    /configure                      - Configure the bot for your guild\n\nYou can find example output of these commands [here](https://github.com/DMcP89/harambot/wiki#command-examples)\n\n\n## Roll your own instance\n\n### Prerequisites\n\nIn order to properly configure your bot you will need the following:\n\n* [Discord API Token](https://github.com/DMcP89/harambot/wiki/Prerequisites#discord-api-token)\n* [Yahoo API Client Id & Secret](https://github.com/DMcP89/harambot/wiki/Prerequisites#yahoo-api-client-id--secret)\n* [Yahoo League ID](https://github.com/DMcP89/harambot/wiki/Prerequisites#yahoo-league-id)\n\n_Visit our [wiki](https://github.com/DMcP89/harambot/wiki) for a step by step guide on how to obtain these values._\n\n### Run the bot in the cloud\n\n[![Deploy to Render](https://render.com/images/deploy-to-render-button.svg)](https://render.com/deploy?repo=https://github.com/DMcP89/harambot)\n\n[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)\n\n\n### Run the bot locally using pip package\n\n1. Install the harambot package using pip\n\n        pip install harambot\n\n2. Export the following environment variables\n\n   ```\n   export DISCORD_TOKEN='[YOUR DISCORD TOKEN]'\n   export YAHOO_KEY='[YOUR YAHOO API CLIENT ID]'\n   export YAHOO_SECRET='[YOUR YAHOO API CLIENT SECRET]'\n   export DATABASE_URL='[YOUR DATABASE URL]'\n   ```\n\n3. Run the bot\n\n        harambot\n\n### Run the bot locally using docker\n\n1. Pull the latest image from docker hub\n\n        docker pull dmcp89/harambot\n\n2. Export the following environment variables\n\n   ```\n   export DISCORD_TOKEN='[YOUR DISCORD TOKEN]'\n   export YAHOO_KEY='[YOUR YAHOO API CLIENT ID]'\n   export YAHOO_SECRET='[YOUR YAHOO API CLIENT SECRET]'\n   export DATABASE_URL='[YOUR DATABASE URL]'\n   ```\n\n3. Run the bot\n\n        docker run --name harambot \\\n        -e DISCORD_TOKEN=$DISCORD_TOKEN \\\n        -e YAHOO_KEY=$YAHOO_KEY \\\n        -e YAHOO_SECRET=$YAHOO_SECRET \\\n        -e DATABASE_URL=$DATABASE_URL \\\n        --rm dmcp89/harambot\n\n\n## Setup\n\n### Add the bot to your guild\n1. Generate a OAuth url from the discord developer portal using the bot scope and the following permissions:\n\n* Send Messages\n* Send Messages in Threads\n* Embed Links\n* Attach Files\n* Read Message History\n* Add Reactions\n* Use Slash Commands\n\nThe permission value should be 277025507392\n\n![discord-oauth](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-generator.png)\n\n2. Set the gateway intents\n\nIn order for the bot to work properly it requires the following intents:\n\n* Sever Members Intent\n* Message Content Intent\n\n![discord-intents](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-intents.png)\n\n3. Navigate to the generated url in a web browser and authorize the bot for your guild\n\n![discord-oauth-url-1](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-url-authorize-1.png)\n![discord-oauth-url-2](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/discord-oauth-url-authorize-2.png)\n\n### Configure your guild\n\n* Once your bot is added to your guild you can configure it by using the /configure command:\n\n\n![discord-config-commnd](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_1.png)\n\n* Use the Login with Yahoo button to authenticate with Yahoo and get your Yahoo token\n\n\n![discord-config-yahoo](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_4.png)\n\n* Use the Configure Guild button to configure your guild for the bot\n\n\n![discord-config-guild](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_2.png)\n\n\n* You can reconfigure your guild by running the configure command and clicking the Configure Guild button.\n\n\n![discord-config-guild](https://raw.githubusercontent.com/DMcP89/harambot/main/assests/harambot_configure_3.png)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A Yahoo Fantasy Sports bot for Discord",
    "version": "0.3.3",
    "project_urls": {
        "Homepage": "http://harambot.io",
        "Repository": "https://github.com/DMcP89/harambot"
    },
    "split_keywords": [
        "yahoo",
        "yahoo fantasy sports",
        "fantasy football",
        "fantasy basketball",
        "fantasy baseball",
        "fantasy hockey",
        "discord",
        "bot"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "03e48f176c8b14f19ee6ad6c056fc1627d1a31f1a353c5572300b8c1f3057b6c",
                "md5": "d0fc0cd48ac38813a496e6eeca69b0f0",
                "sha256": "a06fa70e990da430c32b786d3c9918c40e1a2137ce9f04c675d194c8035eb8a3"
            },
            "downloads": -1,
            "filename": "harambot-0.3.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d0fc0cd48ac38813a496e6eeca69b0f0",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<4.0",
            "size": 15701,
            "upload_time": "2023-10-12T03:10:18",
            "upload_time_iso_8601": "2023-10-12T03:10:18.671929Z",
            "url": "https://files.pythonhosted.org/packages/03/e4/8f176c8b14f19ee6ad6c056fc1627d1a31f1a353c5572300b8c1f3057b6c/harambot-0.3.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "187bc6fa41c6d887f2ed13bffa370b1b9ad36e99e7c178d9fafc7d6d311bd7c4",
                "md5": "a1688da93d9d9dbfb8690727070d78e2",
                "sha256": "21b6556d3a89cd0045d140531d54701d7d2347ef97508d7237a53b107365f68a"
            },
            "downloads": -1,
            "filename": "harambot-0.3.3.tar.gz",
            "has_sig": false,
            "md5_digest": "a1688da93d9d9dbfb8690727070d78e2",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<4.0",
            "size": 5871664,
            "upload_time": "2023-10-12T03:10:20",
            "upload_time_iso_8601": "2023-10-12T03:10:20.384828Z",
            "url": "https://files.pythonhosted.org/packages/18/7b/c6fa41c6d887f2ed13bffa370b1b9ad36e99e7c178d9fafc7d6d311bd7c4/harambot-0.3.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-10-12 03:10:20",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "DMcP89",
    "github_project": "harambot",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "harambot"
}
        
Elapsed time: 0.12818s