MLB Game Feed Bot: Difference between revisions

From ChewWiki
Jump to navigation Jump to search
clean up some of the body, migrate refs to template, clean up external links
add new command
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
'''MLB Game Feed Bot''' is a Discord bot developed by [[Chew]] and is used to hook into the Major League Baseball (MLB) API and track live game data, much like the MLB's ''Gameday''. It is written in JDA, a Java Discord library. As of October 2024, it is in over 1,200 servers.
'''MLB Game Feed Bot''' is a Discord bot developed by [[Chew]] and is used to hook into the Major League Baseball (MLB) API and track live game data, much like the MLB's ''Gameday''. It is written in JDA, a Java Discord library. As of March 2025, it is in over 1,300 servers.


== Features ==
== Features ==
Line 7: Line 7:
=== Commands ===
=== Commands ===


The bot communicates solely though slash commands. There are 7 commands, 4 of which manage or monitors games.<ref>[https://help.chew.pro/bots/discord/mlb-game-feed/commands MLB Game Feed Bot command list]</ref>
The bot communicates solely though slash commands. There are 8 commands, 4 of which manage or monitors games.<ref>[https://help.chew.pro/bots/discord/mlb-game-feed/commands MLB Game Feed Bot command list]</ref>


Games can be started with the <code>/startgame</code> or <code>/plangame</code> to plan future games. Once a game is active, <code>/score</code> can be used to view the score, and <code>/stopgame</code> can forcibly stop the game; however, the game will stop automatically when it's over.
Games can be started with the <code>/startgame</code> or <code>/plangame</code> to plan future games. Once a game is active, <code>/score</code> can be used to view the score, and <code>/stopgame</code> can forcibly stop the game; however, the game will stop automatically when it's over.


The bot can be configured per-channel with the <code>/config</code> command. And the <code>/setinfo</code> command can be used to set a voice channel's name to certain stats. Finally, <code>/standings</code> can be used to view standings for a provided division.
The bot can be configured per-channel with the <code>/config</code> command. And the <code>/setinfo</code> command can be used to set a voice channel's name to certain stats.
 
There are two commands that work when the bot is installed to a user. First is <code>/standings</code>, which can be used to view standings for a provided division, and <code>/gameinfo</code>, which shows information for a game. The response of both are ephemeral, meaning only the invoking user will see it.


== History ==
== History ==


The bot started off inspired by the MLB Chat Discord server's own bot. Chew began development on June 16th, 2022,<ref>{{Cite GitHub|url=https://github.com/Chew/MLB-GameFeed-Bot/commit/d87913277ff2ba37ea5c4844985d28a700c10dad|title=Initial gradle|author=Chew|org=Chew|repo=MLB-GameFeed-Bot|type=commit|commit=d879132}}</ref> but the first code was committed the following day on June 17th, 2022.<ref>{{Cite GitHub|url=https://github.com/Chew/MLB-GameFeed-Bot/commit/e0da85726b26ac0d5dbc663f4c24943d5bfddabd|title=Iteration one of game feed|author=Chew|org=Chew|repo=MLB-GameFeed-Bot|type=commit|commit=e0da857}}</ref> Throughout the rest of the month, fixes and improvements were slowly made. The bot was added to a Texas Rangers fan Discord server.
The bot started off inspired by the MLB Chat Discord server's own bot. Chew began development on June 16th, 2022,<ref>{{Cite GitHub commit |title=Initial gradle |author=Chew |org=Chew |repo=MLB-GameFeed-Bot |commit=d879132 |date=June 16, 2022}}</ref> but the first code was committed the following day on June 17th, 2022.<ref>{{Cite GitHub commit |title=Iteration one of game feed |author=Chew |org=Chew |repo=MLB-GameFeed-Bot |commit=e0da857 |date=June 17, 2022}}</ref> Throughout the rest of the month, fixes and improvements were slowly made. The bot was added to a Texas Rangers fan Discord server.


At the start of the 2023 season, the bot was in 79 servers; at the end of the season, it was in nearly 600 servers. By opening day of the 2024 season, the server count had risen to over 900 servers. As of now, it sits at around 1,250 servers.
At the start of the 2023 season, the bot was in 79 servers; at the end of the season, it was in nearly 600 servers. By opening day of the 2024 season, the server count had risen to over 900 servers. As of now, it sits at around 1,250 servers.
Line 27: Line 29:


* [https://help.chew.pro/bots/discord/mlb-game-feed MLB Game Feed] on [[ChewHelp]]
* [https://help.chew.pro/bots/discord/mlb-game-feed MLB Game Feed] on [[ChewHelp]]
* [https://github.com/Chew/MLB-GameFeed-Bot Chew/MLB-GameFeed-Bot] on GitHub
* {{GitHub Repo URL|Chew|MLB-GameFeed-Bot}}

Latest revision as of 16:40, 1 April 2025

MLB Game Feed Bot is a Discord bot developed by Chew and is used to hook into the Major League Baseball (MLB) API and track live game data, much like the MLB's Gameday. It is written in JDA, a Java Discord library. As of March 2025, it is in over 1,300 servers.

Features

The bot allows you to start a live game and have the plays come in when they're posted to the endpoint. By default, in-play events have a 13 second delay, and plays that don't (strikeouts, walks, etc) have a 18 second delay. This can be configured per channel, as desired. These times were chosen as they closely line up with the play happening live on TV, to prevent spoilers. Watching a game in-person, there is a few second delay before the result is posted to the API.

Commands

The bot communicates solely though slash commands. There are 8 commands, 4 of which manage or monitors games.[1]

Games can be started with the /startgame or /plangame to plan future games. Once a game is active, /score can be used to view the score, and /stopgame can forcibly stop the game; however, the game will stop automatically when it's over.

The bot can be configured per-channel with the /config command. And the /setinfo command can be used to set a voice channel's name to certain stats.

There are two commands that work when the bot is installed to a user. First is /standings, which can be used to view standings for a provided division, and /gameinfo, which shows information for a game. The response of both are ephemeral, meaning only the invoking user will see it.

History

The bot started off inspired by the MLB Chat Discord server's own bot. Chew began development on June 16th, 2022,[2] but the first code was committed the following day on June 17th, 2022.[3] Throughout the rest of the month, fixes and improvements were slowly made. The bot was added to a Texas Rangers fan Discord server.

At the start of the 2023 season, the bot was in 79 servers; at the end of the season, it was in nearly 600 servers. By opening day of the 2024 season, the server count had risen to over 900 servers. As of now, it sits at around 1,250 servers.

References

  1. MLB Game Feed Bot command list
  2. "Initial gradle" by Chew in Chew/MLB-GameFeed-Bot @ d879132. Committed on June 16, 2022 – via GitHub.
  3. "Iteration one of game feed" by Chew in Chew/MLB-GameFeed-Bot @ e0da857. Committed on June 17, 2022 – via GitHub.

External links